Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/scripts/ci/worker-postgres-evidence.sh
Original file line number Diff line number Diff line change
Expand Up @@ -48,5 +48,5 @@ if [ "$mode" = profile ]; then
bun --no-env-file test --max-concurrency=1 --isolate ./web/src/tests/server/Foundation/worker-postgres-profile.db.test.ts 2>&1 | tee "$reports/profile.log"
else
export RENTNERPROXY_POSTGRES_PROFILE=0
bun --no-env-file test --max-concurrency=1 --isolate ./web/src/tests/server/Foundation/background-database.db.test.ts ./web/src/tests/server/Foundation/worker-lock-order.db.test.ts ./web/src/tests/server/HostMonitoring/host-monitoring.repository.db.test.ts ./web/src/tests/server/Notifications/notification-repository.db.test.ts 2>&1 | tee "$reports/regressions.log"
bun --no-env-file test --max-concurrency=1 --isolate ./web/src/tests/server/Foundation/background-database.db.test.ts ./web/src/tests/server/Foundation/worker-lock-order.db.test.ts ./web/src/tests/server/HostMonitoring/host-monitoring-fence.db.test.ts ./web/src/tests/server/HostMonitoring/host-monitoring-handoff.db.test.ts ./web/src/tests/server/Notifications/notification-repository.db.test.ts 2>&1 | tee "$reports/regressions.log"
fi
2 changes: 1 addition & 1 deletion .github/workflows/arm64-appliance.yml
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ jobs:

- name: Native bounded background worker correctness scenarios
if: env.RUN_CHECK == 'true'
run: 'bun --no-env-file --no-orphans scripts/runtime-scale/background-run.ts --policies 100 --duration-seconds 120 --image "rentnerproxy-smoke-${RENTNERPROXY_SMOKE_RUN}:appliance" --report "$RUNNER_TEMP/background-workers.json"'
run: 'bun --no-env-file --no-orphans scripts/runtime-scale/background-run.ts --duration-seconds 120 --image "rentnerproxy-smoke-${RENTNERPROXY_SMOKE_RUN}:appliance" --report "$RUNNER_TEMP/background-workers.json"'

- name: Store bounded ARM64 background report
if: ${{ env.RUN_CHECK == 'true' && always() }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/production-smokes.yml
Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,7 @@ jobs:
run: 'bun --no-env-file --no-orphans scripts/runtime-reliability/run.ts --profile short --image "rentnerproxy-smoke-${RENTNERPROXY_SMOKE_RUN}:appliance" --capture-resources true --report "$RUNNER_TEMP/runtime-reliability-report/report.json"'
- name: Run bounded background worker correctness scenarios
if: needs.changes.outputs.runtime == 'true'
run: 'bun --no-env-file --no-orphans scripts/runtime-scale/background-run.ts --policies 100 --duration-seconds 120 --image "rentnerproxy-smoke-${RENTNERPROXY_SMOKE_RUN}:appliance" --report "$RUNNER_TEMP/runtime-reliability-report/background.json"'
run: 'bun --no-env-file --no-orphans scripts/runtime-scale/background-run.ts --duration-seconds 120 --image "rentnerproxy-smoke-${RENTNERPROXY_SMOKE_RUN}:appliance" --report "$RUNNER_TEMP/runtime-reliability-report/background.json"'
- name: "Remove this run's private Docker resources"
if: "always() && steps.bun.outcome == 'success'"
run: bun --no-env-file .github/scripts/ci/production-smoke-ci.ts cleanup
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/runtime-reliability.yml
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ jobs:
env:
SEED: ${{ inputs.seed }}
run: |
args=(--policies 100 --duration-seconds 120 --extended-recovery true --image "rentnerproxy-reliability-${RENTNERPROXY_SMOKE_RUN}:current" --report "$RUNNER_TEMP/runtime-reliability-report/report.json")
args=(--duration-seconds 120 --extended-recovery true --image "rentnerproxy-reliability-${RENTNERPROXY_SMOKE_RUN}:current" --report "$RUNNER_TEMP/runtime-reliability-report/report.json")
if [ -n "$SEED" ]; then args+=(--seed "$SEED"); fi
bun --no-env-file --no-orphans scripts/runtime-scale/background-run.ts "${args[@]}"

Expand Down
2 changes: 1 addition & 1 deletion scripts/runtime-scale/Types/background-evidence.types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ export type BackgroundRecoveryEvidence = {
runId: string
reportSha256: string
elapsedMs: number
schedulerAdmissions: number
deferredDeliveries: number
deferredIdentities: number
faults: readonly string[]
capacity: 'insufficient'
Expand Down
17 changes: 0 additions & 17 deletions scripts/runtime-scale/Types/background.types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,35 +3,18 @@ import type { backgroundSnapshotSchema } from '../background.validation.ts'
import type { ResourceSample } from '../../runtime-reliability/Types/control.types.ts'

export type BackgroundOptions = {
policies: 100 | 500 | 1000
seed: number
pattern: 'simultaneous' | 'staggered'
profile: 'mixed' | 'healthy' | 'slow' | 'timeout'
durationSeconds: number
image?: string
reportPath?: string
extendedRecovery?: true
contention?: true
}

export type BackgroundPolicy = {
id: string
index: number
latency: 'healthy' | 'slow' | 'timeout' | 'failure'
offsetMs: number
}

export type BackgroundSnapshot = z.output<typeof backgroundSnapshotSchema>
export type BackgroundResourceSample = {
kind: 'continuous' | 'recovered'
generation: string
warmup: boolean
sample: Omit<ResourceSample, 'phase'> & { phase: 'continuous' | 'recovered' }
}

export type BackgroundReceipt = {
index: number
startedAt: number
finishedAt: number | null
latency: BackgroundPolicy['latency']
}
16 changes: 0 additions & 16 deletions scripts/runtime-scale/Types/monitoring.types.ts

This file was deleted.

59 changes: 0 additions & 59 deletions scripts/runtime-scale/background-capture-read.ts

This file was deleted.

97 changes: 0 additions & 97 deletions scripts/runtime-scale/background-capture-settlement.ts

This file was deleted.

115 changes: 0 additions & 115 deletions scripts/runtime-scale/background-capture.ts

This file was deleted.

3 changes: 1 addition & 2 deletions scripts/runtime-scale/background-contention-fixture.ts
Original file line number Diff line number Diff line change
Expand Up @@ -244,9 +244,8 @@ export async function backgroundContentionFixture(context: FixtureContext) {
active: number
lockWaiters: number
idleTransactions: number
monitoringLeases: number
}>(
sql`select count(*)::int as connections, count(*) filter (where state = 'active' and pid <> pg_backend_pid())::int as active, count(*) filter (where wait_event_type = 'Lock')::int as "lockWaiters", count(*) filter (where state = 'idle in transaction')::int as "idleTransactions", (select count(*)::int from rentnerproxy.host_check_policies where lease_expires_at > clock_timestamp()) as "monitoringLeases" from pg_stat_activity where datname = current_database()`,
sql`select count(*)::int as connections, count(*) filter (where state = 'active' and pid <> pg_backend_pid())::int as active, count(*) filter (where wait_event_type = 'Lock')::int as "lockWaiters", count(*) filter (where state = 'idle in transaction')::int as "idleTransactions" from pg_stat_activity where datname = current_database()`,
),
])
const { runtime, configuration, observedAt } = notificationSnapshot
Expand Down
Loading