stem 0.2.1
stem: ^0.2.1 copied to clipboard
Stem is a Dart-native background job platform with Redis Streams, retries, scheduling, observability, and security tooling.
Changelog #
0.2.1 #
- Guarded worker and example process signal registration so Windows only
installs supported shutdown watchers, avoiding unsupported
SIGTERM/SIGQUITsubscriptions during graceful shutdown setup.
0.2.0 #
- Added
StemClient.fromStack(...)andStemStack.createClient(...)so adapter-resolved broker/backend stacks have the same direct bootstrap path as the higher-level app helpers. - Narrowed the public task and workflow invocation APIs around direct
enqueue(...)/enqueueAndWait(...)andstart(...)/startAndWait(...)calls, with explicit transport objects left as the advanced low-level path. - Removed duplicate transport helpers and wrapper builder entrypoints such as
.call(...),prepareStart(...),prepareEnqueue(...), builder dispatch methods, andcopyWith(...)on transport objects. - Added shared execution-context interfaces for workflows and tasks so manual handlers and checkpoints can use one typed context surface instead of several partially overlapping ones.
- Added expression-style suspension and event APIs for workflows, plus direct typed event emit/wait helpers on workflow event refs.
- Added module-first bootstrap improvements including module merge/combine, inferred worker subscriptions, queue/subscription inspection helpers, and shared app/client workflow bootstrap helpers.
- Expanded manual serialization support with
json(...),versionedJson(...),versionedMap(...), registry-backed versioned factories, and codec-backed low-level publish/start/emit helpers for tasks, workflows, and queue events. - Added broad typed decode helpers across runtime, inspection, signal, queue, status, and context surfaces so DTO reads no longer require raw map casts in the common path.
- Refreshed examples and docs to use the narrowed happy-path APIs and to treat transport objects as explicit advanced APIs rather than peer entrypoints.
0.1.0 #
- Added workflow run leasing APIs (
claimRun,renewRunLease,releaseRun,listRunnableRuns) and runtime ownership tracking to safely spread workflows across workers. - Added TaskRetryPolicy and TaskEnqueueOptions for per-enqueue overrides (timing, retries, callbacks), plus TaskContext/TaskInvocationContext enqueue, spawn, and retry helpers including isolate entrypoint support and a fluent TaskEnqueueBuilder.
- Added inline FunctionTaskHandler execution (runInIsolate toggle) to simplify choosing between inline vs. isolate task execution.
- Added workflow/task annotations and a registry builder to streamline declarative workflow setup with existing Flow/WorkflowScript APIs.
- Added StemClient as a single entrypoint for configuring workers and workflow apps with shared broker/backend registries.
- Added TaskContext demos and refreshed docs/snippets for enqueue options and SQLite guidance.
- Added typed workflow, task, and canvas result APIs with customizable encoders (TaskResultEncoder and payload encoders).
- Added new example suites (progress heartbeat, worker control lab, and the feature-complete set) plus refreshed docs/Taskfiles for running them.
- Added signals registry/configuration for worker, task, scheduler, and workflow lifecycle events.
- Improved worker runtime (isolate pool, config, heartbeats/autoscaling) plus scheduler behavior (timezone alias handling, in-memory schedule store).
- Exposed lock ownership in interfaces and migrated IDs to UUID v7.
- Removed sqlite migrations from core and updated dependencies (collection, contextual, crypto, cryptography, timezone, uuid).
- Expanded internal docs and example suites, plus broader unit/property and workflow store contract coverage.
0.1.0-alpha.4 #
- Introduced Durable Workflows end-to-end: auto-versioned steps, iteration- aware contexts, and durable event watchers so long-running flows replay safely and resume with persisted payloads.
- Added a
WorkflowClockabstraction (withFakeWorkflowClock) so runtimes and stores can record deterministic timestamps during testing. - Refined sleep/await behaviour: persisted wake timestamps now prevent
re-suspending once a delay has elapsed, and
saveSteprefreshes run heartbeats so active workers retain ownership. - Updated all workflow stores to consume injected clock metadata, ensuring
suspension payloads include
resumeAt/deadlinevalues without relying onDateTime.now(). - Wired
TaskOptions.uniqueinto the runtime via the newUniqueTaskCoordinator, allowing clusters to deduplicate submissions using sharedLockStores and surface duplicate metadata when a clash occurs. - Workers now coordinate chord callbacks through
ResultBackend.claimChord, persisting callback ids and dispatch timestamps so fan-in callbacks run exactly once even after crashes or retry storms.
0.1.0-alpha.3 #
- Split Redis/Postgres adapters and CLI into dedicated packages (
stem_redis,stem_postgres,stem_cli) so the core package only exposes platform-agnostic runtime APIs. - Updated examples, docs, and integration guides to reference the new packages.
0.1.0-alpha.2 #
- Replace the legacy
opentelemetrydependency withdartastic_opentelemetryand update tracing/metrics integrations. - Add
_init_test_envhelper to start dockerised dependencies and export integration env vars. - Refresh project docs to mention the new telemetry stack and test environment workflow.
- Bump direct dependencies (dartastic_opentelemetry 0.9.2, postgres 3.5.9, timezone 0.10.1) and align transitive packages.
0.1.0-alpha #
- Initial version.