@vite-hub/schedule 0.0.1 → 0.0.3
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.
- package/README.md +73 -8
- package/dist/client-BMFCy0dX.js +233 -0
- package/dist/definition.d.ts +7 -0
- package/dist/definition.js +42 -0
- package/dist/discovery-BZlat3Kc.js +776 -0
- package/dist/due-Bbh4yIxq.js +59 -0
- package/dist/execute-ClFYvmp9.js +211 -0
- package/dist/index.d.ts +28 -23
- package/dist/index.js +7 -152
- package/dist/kv-BJ1I9IlJ.js +6 -0
- package/dist/kv-storage-DWinmLLy.js +30 -0
- package/dist/nuxt.d.ts +19 -0
- package/dist/nuxt.js +25 -0
- package/dist/runtime/driver.d.ts +26 -0
- package/dist/runtime/driver.js +334 -0
- package/dist/runtime/process.d.ts +11 -0
- package/dist/runtime/process.js +285 -0
- package/dist/runtime/state.d.ts +2 -2
- package/dist/runtime/state.js +1 -1
- package/dist/runtime/static.d.ts +27 -3
- package/dist/runtime/static.js +126 -3
- package/dist/runtime.d.ts +4 -3
- package/dist/runtime.js +3 -3
- package/dist/{state-DoONzfij.js → state-By7WU_ks.js} +55 -24
- package/dist/store-t-74rsM_.d.ts +48 -0
- package/dist/{types-DOjXDq0s.d.ts → types-Bcje4dLV.d.ts} +34 -9
- package/dist/vite-BX6_KiRw.js +1218 -0
- package/dist/vite.d.ts +35 -6
- package/dist/vite.js +2 -110
- package/dist/wait-until-CR-JjIOb.js +23 -0
- package/package.json +40 -39
- package/dist/client-BJ33CRLg.js +0 -401
- package/dist/discovery-Di9MD-SN.js +0 -574
- package/dist/module-C_j2ahfg.js +0 -1767
- package/dist/nitro.d.ts +0 -6
- package/dist/nitro.js +0 -2
- package/dist/store-CeeSsInC.d.ts +0 -63
package/dist/nitro.d.ts
DELETED
package/dist/nitro.js
DELETED
package/dist/store-CeeSsInC.d.ts
DELETED
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
import { a as RuntimeScheduleStore, f as ScheduleRunAttemptRecord, g as ScheduleRunRecord, i as RuntimeScheduleRecord, n as RuntimeScheduleCreateInput, o as RuntimeScheduleUpdateInput, v as ScheduleRunStore, y as ScheduleTargetName } from "./types-DOjXDq0s.js";
|
|
2
|
-
import * as _$_vite_hub_schedule0 from "@vite-hub/schedule";
|
|
3
|
-
|
|
4
|
-
//#region src/registry-module.d.ts
|
|
5
|
-
declare module "#vitehub/schedule/registry" {
|
|
6
|
-
const registry: _$_vite_hub_schedule0.ScheduleDefinitionRegistry;
|
|
7
|
-
export default registry;
|
|
8
|
-
}
|
|
9
|
-
declare module "#vitehub/schedule/targets" {
|
|
10
|
-
export const scheduleTargetNames: _$_vite_hub_schedule0.ScheduleTargetName[];
|
|
11
|
-
export type ScheduleTargetName = _$_vite_hub_schedule0.ScheduleTargetName;
|
|
12
|
-
}
|
|
13
|
-
//#endregion
|
|
14
|
-
//#region src/errors.d.ts
|
|
15
|
-
interface ScheduleErrorOptions {
|
|
16
|
-
cause?: unknown;
|
|
17
|
-
code?: string;
|
|
18
|
-
details?: unknown;
|
|
19
|
-
httpStatus?: number;
|
|
20
|
-
}
|
|
21
|
-
declare class ScheduleError extends Error {
|
|
22
|
-
code?: string;
|
|
23
|
-
details?: unknown;
|
|
24
|
-
httpStatus?: number;
|
|
25
|
-
constructor(message: string, options?: ScheduleErrorOptions);
|
|
26
|
-
}
|
|
27
|
-
//#endregion
|
|
28
|
-
//#region src/runtime/client.d.ts
|
|
29
|
-
declare function validateRuntimeScheduleCron(cron: unknown): void;
|
|
30
|
-
declare const schedules: {
|
|
31
|
-
create<TTarget extends ScheduleTargetName>(input: RuntimeScheduleCreateInput<TTarget>): Promise<RuntimeScheduleRecord>;
|
|
32
|
-
delete(id: string): Promise<boolean>;
|
|
33
|
-
disable(id: string): Promise<RuntimeScheduleRecord>;
|
|
34
|
-
enable(id: string): Promise<RuntimeScheduleRecord>;
|
|
35
|
-
get(id: string): Promise<RuntimeScheduleRecord | undefined>;
|
|
36
|
-
getRun(id: string): Promise<ScheduleRunRecord | undefined>;
|
|
37
|
-
list(): Promise<RuntimeScheduleRecord[]>;
|
|
38
|
-
listAttempts(runId: string): Promise<ScheduleRunAttemptRecord[]>;
|
|
39
|
-
listRuns(): Promise<ScheduleRunRecord[]>;
|
|
40
|
-
run(id: string, options?: {
|
|
41
|
-
scheduledAt?: Date;
|
|
42
|
-
}): Promise<ScheduleRunRecord>;
|
|
43
|
-
update<TTarget extends ScheduleTargetName>(id: string, input: RuntimeScheduleUpdateInput<TTarget>): Promise<RuntimeScheduleRecord>;
|
|
44
|
-
};
|
|
45
|
-
//#endregion
|
|
46
|
-
//#region src/runtime/store.d.ts
|
|
47
|
-
interface ScheduleKVStorage {
|
|
48
|
-
del(key: string): boolean | Promise<boolean> | Promise<void> | void;
|
|
49
|
-
get<T = unknown>(key: string): Promise<T | null | undefined> | T | null | undefined;
|
|
50
|
-
has(key: string): boolean | Promise<boolean>;
|
|
51
|
-
keys(base?: string): Promise<string[]> | string[];
|
|
52
|
-
set<T = unknown>(key: string, value: T): Promise<void> | void;
|
|
53
|
-
}
|
|
54
|
-
interface KVScheduleStoreOptions {
|
|
55
|
-
kvStore?: ScheduleKVStorage;
|
|
56
|
-
prefix?: string;
|
|
57
|
-
}
|
|
58
|
-
declare function createMemoryRuntimeScheduleStore(): RuntimeScheduleStore;
|
|
59
|
-
declare function createKVRuntimeScheduleStore(options?: KVScheduleStoreOptions): RuntimeScheduleStore;
|
|
60
|
-
declare function createMemoryScheduleRunStore(): ScheduleRunStore;
|
|
61
|
-
declare function createKVScheduleRunStore(options?: KVScheduleStoreOptions): ScheduleRunStore;
|
|
62
|
-
//#endregion
|
|
63
|
-
export { createMemoryRuntimeScheduleStore as a, validateRuntimeScheduleCron as c, createKVScheduleRunStore as i, ScheduleError as l, ScheduleKVStorage as n, createMemoryScheduleRunStore as o, createKVRuntimeScheduleStore as r, schedules as s, KVScheduleStoreOptions as t };
|