@stonyx/cron 0.2.1-alpha.63 → 0.2.1-alpha.64

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +18 -0
  2. package/package.json +2 -2
package/README.md CHANGED
@@ -47,6 +47,24 @@ When a job is executed, its next trigger time is updated, and it is re-inserted
47
47
 
48
48
  > `MinHeap` is also exported as a public subpath (`@stonyx/cron/min-heap`) and can be imported directly for advanced usage.
49
49
 
50
+ ## Exports
51
+
52
+ | Import path | What it exports |
53
+ | :--- | :--- |
54
+ | `@stonyx/cron` | `Cron` (default), the interval registry above |
55
+ | `@stonyx/cron/service` | `CronService` (default), see [CronService](#cronservice) |
56
+ | `@stonyx/cron/schedule` | `computeNextRunAtMs`, `validateSchedule`, and the `Schedule` types |
57
+ | `@stonyx/cron/cron-parser` | `parseCronExpression`, `parseField`, `nextOccurrence`, `validateCronExpression` |
58
+ | `@stonyx/cron/job` | `createJob`, `updateJob`, `applyResult`, `isDue`, `markRunning`, `errorBackoffMs`, and the `Job` types |
59
+ | `@stonyx/cron/normalize` | `normalizeJobInput`, `normalizeSchedule`, `normalizePayload`, `recoverFlatParams` |
60
+ | `@stonyx/cron/run-log` | `RunLog` (default) |
61
+ | `@stonyx/cron/locked` | `locked`, `resetLock` |
62
+ | `@stonyx/cron/min-heap` | `MinHeap` (default) |
63
+
64
+ ## Samples
65
+
66
+ [`test/sample/`](https://github.com/abofs/stonyx-cron/tree/dev/test/sample) is the canonical usage reference for job definitions: legacy `Cron` intervals and every `CronService` schedule kind. It is not included in the npm package.
67
+
50
68
  ## CronService
51
69
 
52
70
  The default export above is `Cron`: a fire-and-forget interval registry. `@stonyx/cron/service` is a separate, heavier class for jobs that need CRUD, persistence, a run log and error backoff. It is not a drop-in replacement and the two do not share a scheduler.
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "keywords": [
4
4
  "stonyx-module"
5
5
  ],
6
- "version": "0.2.1-alpha.63",
6
+ "version": "0.2.1-alpha.64",
7
7
  "description": "Cron/job scheduler for Stonyx framework",
8
8
  "main": "dist/main.js",
9
9
  "types": "dist/main.d.ts",
@@ -79,7 +79,7 @@
79
79
  "typescript": "^5.8.3"
80
80
  },
81
81
  "dependencies": {
82
- "stonyx": "0.2.3-beta.93"
82
+ "stonyx": "0.2.3-beta.98"
83
83
  },
84
84
  "scripts": {
85
85
  "build": "tsc",