Skip to content

Make Sally scheduler cadences and webhook timing configurable - #66

Merged
kentbull merged 3 commits into
GLEIF-IT:mainfrom
kentbull:perf/configurable-tocks
Oct 30, 2026
Merged

kentbull merged 3 commits into
GLEIF-IT:mainfrom
kentbull:perf/configurable-tocks

Conversation

@kentbull

@kentbull kentbull commented Oct 30, 2026 •

Copy link
Copy Markdown
Collaborator

Independent processing cadences

Successful credential presentations previously inherited multi-second waits from webhook retry delays. Configure Sally’s coroutine cadences under tocks.verifier so processing can continue independently of failed-attempt backoff. Child cadences default to the next parent scheduler turn; both root schedulers remain positive at 31.25ms by default.

Separate retry and timeout configuration

Keep retry delays and deadlines in the root-level verifier object, with their own resolver in core.configing. Scheduling uses KERIpy’s tock resolver and handles only coroutine cadences. Bootstrap and service setup receive the two resolved domains separately.

VerifierConfiger lets Sally share a config file with KERIpy 1.2.18, whose strict validator rejects tocks.verifier. It hides that subsection from KERIpy’s read view while preserving Sally’s complete config and the file on disk.

Consistent units and bounded webhook requests

All intervals use seconds, including --escrow-timeout and the Python timeout argument. The escrow lifetime defaults to 600 seconds, preserving the effective ten-minute default. Retry delays remain 10 seconds for the server CLI and 3 seconds for the Python setup API.

An optional monotonic webhook request deadline releases silent clients and applies retry backoff or escrow expiry. Zero disables the deadline. Retry deadlines are held in memory and do not survive restart.

Readable configuration and behavioral tests

Update CLI help, align README tables, and express the performance example’s intervals in seconds. Separate retry/timeout configuration tests from scheduler tests.

Use real signing habitats, ACDCs, LMDB stores, and HTTP handling. Reusable single-signature GEDA/QVI fixtures anchor delegation approval and issue a verified QVI credential; the Sally webhook regression checks the GEDA issuer and QVI recipient in the delivered payload. Shared verification-context and agent fixtures manage construction and cleanup across seven tests while keeping schemas, handlers, credential loading, and assertions visible. Export/import retains independent source and destination contexts.

Consolidate real Habery creation/reopening, configuration isolation, and actual server-default checks. Cover two-second webhook escrow expiry in the request-deadline matrix, with a live-escrow opt-out case. Keep cadence resolution, root scheduling, child/parent cadence independence, service wiring, and real failed-webhook backoff coverage. Remove duplicate compatibility/lifecycle smoke tests and repeated dependency-validation cases. Brief flow comments distinguish escrow age, HTTP deadlines, and retry/drop decisions.

@kentbull
kentbull force-pushed the perf/configurable-tocks branch 5 times, most recently from 73b7d9c to 77f2bda Compare October 30, 2026 17:12
Resolve coroutine cadences under tocks.verifier through KERIpy scheduling, and resolve retry delays and deadlines separately under verifier. Default child cadences to the next scheduler turn so successful processing is independent of webhook failure backoff.

Use seconds throughout, preserving the effective 600-second escrow lifetime and distinct CLI and Python retry defaults. Bound silent webhook attempts when configured, clean up their clients, and apply retry or expiry. Keep VerifierConfiger as the adapter for KERIpy strict validation without rewriting shared config files.

Pass the resolved domains separately through bootstrap and service setup. Document the settings, defaults, and performance example with aligned configuration tables.
@kentbull
kentbull force-pushed the perf/configurable-tocks branch 5 times, most recently from 29c6416 to 97a5546 Compare October 30, 2026 18:46
Cover cadence and verifier configuration separately, including precedence, malformed values, independent resolution, zero semantics, and seconds-based expiry. Use real temporary Habery creation and reopening to verify strict KERIpy validation and unchanged shared configuration files.

Use real ACDCs, LMDB escrows, signing habitats, processors, and local HTTP handling. Reusable single-signature GEDA/QVI fixtures anchor delegation approval and issue a verified QVI credential through a real registry. An independent Sally Habery accepts the QVI only after receiving the approval anchor.

Share component construction and cleanup through a verification context and an agent wrapper across seven tests. Keep schemas, handlers, credential loading, escrow processing, and behavioral assertions visible. Export and import retain separate source and destination contexts.

Test OOBI and authentication completion through the public runner lifecycle. Keep bootstrap cadence checks at the resolver level and communicator cadence checks in a parameterized generator test. Preserve root scheduling, real webhook backoff, cleanup, and expiry coverage. Concise comments and a request-clock name clarify elapsed HTTP deadlines versus calendar-based escrow age. All 70 Sally tests, the three updated deadline cases, strict lint, focused style, and diff checks pass.
@kentbull
kentbull force-pushed the perf/configurable-tocks branch from 97a5546 to 7904d71 Compare October 30, 2026 18:55
Remove duplicate config-reopening coverage, canonical-config and bootstrap smoke tests, and the fixture-only KERIpy delegation regression. Preserve real GEDA/QVI fixtures and check issuer/recipient roles in the delivered Sally webhook payload.

Merge configuration isolation and unchanged-file checks into real startup/reopening coverage for both filename choices. Verify the actual server retry and escrow defaults there, rather than supplying the expected retry default directly to the resolver. Keep the explicit CLI seconds check and verify the Python escrow default in an existing communicator test.

Fold the two-second webhook escrow regression into request-deadline cases, remove the unserviced HTTP listener, and use a live escrow for deadline opt-out. Trim repeated validation cases while retaining malformed-config rejection, both positive roots, bootstrap zero rejection, cadence independence, cleanup, expiry, and backoff coverage.

The cleanup removes 173 net test lines and reduces the suite from 70 to 59 cases. All 59 tests, strict lint, focused style, dependency consistency, and diff checks pass. Production code and the shared real-object fixtures are unchanged.
@kentbull
kentbull merged commit 7682a5a into GLEIF-IT:main Oct 30, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant