@elaraai/e3-types 0.0.2-beta.5 → 0.0.2-beta.50

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 (59) hide show
  1. package/README.md +7 -4
  2. package/dist/src/api.d.ts +1111 -0
  3. package/dist/src/api.d.ts.map +1 -0
  4. package/dist/src/api.js +650 -0
  5. package/dist/src/api.js.map +1 -0
  6. package/dist/src/constants.d.ts +12 -0
  7. package/dist/src/constants.d.ts.map +1 -0
  8. package/dist/src/constants.js +12 -0
  9. package/dist/src/constants.js.map +1 -0
  10. package/dist/src/dataflow.d.ts +574 -0
  11. package/dist/src/dataflow.d.ts.map +1 -0
  12. package/dist/src/dataflow.js +366 -0
  13. package/dist/src/dataflow.js.map +1 -0
  14. package/dist/src/dataset-ref.d.ts +86 -0
  15. package/dist/src/dataset-ref.d.ts.map +1 -0
  16. package/dist/src/dataset-ref.js +82 -0
  17. package/dist/src/dataset-ref.js.map +1 -0
  18. package/dist/src/dataset.d.ts +4 -4
  19. package/dist/src/execution.d.ts +29 -21
  20. package/dist/src/execution.d.ts.map +1 -1
  21. package/dist/src/execution.js +8 -0
  22. package/dist/src/execution.js.map +1 -1
  23. package/dist/src/index.d.ts +7 -1
  24. package/dist/src/index.d.ts.map +1 -1
  25. package/dist/src/index.js +39 -1
  26. package/dist/src/index.js.map +1 -1
  27. package/dist/src/lock.d.ts +85 -0
  28. package/dist/src/lock.d.ts.map +1 -0
  29. package/dist/src/lock.js +71 -0
  30. package/dist/src/lock.js.map +1 -0
  31. package/dist/src/package.d.ts +235 -134
  32. package/dist/src/package.d.ts.map +1 -1
  33. package/dist/src/package.js +53 -23
  34. package/dist/src/package.js.map +1 -1
  35. package/dist/src/structure.d.ts +87 -73
  36. package/dist/src/structure.d.ts.map +1 -1
  37. package/dist/src/structure.js +8 -3
  38. package/dist/src/structure.js.map +1 -1
  39. package/dist/src/task.d.ts +5 -5
  40. package/dist/src/transfer.d.ts +52 -0
  41. package/dist/src/transfer.d.ts.map +1 -0
  42. package/dist/src/transfer.js +49 -0
  43. package/dist/src/transfer.js.map +1 -0
  44. package/dist/src/workspace.d.ts +7 -9
  45. package/dist/src/workspace.d.ts.map +1 -1
  46. package/dist/src/workspace.js +3 -5
  47. package/dist/src/workspace.js.map +1 -1
  48. package/package.json +2 -2
  49. package/src/api.ts +760 -0
  50. package/src/constants.ts +12 -0
  51. package/src/dataflow.ts +427 -0
  52. package/src/dataset-ref.ts +91 -0
  53. package/src/execution.ts +8 -0
  54. package/src/index.ts +183 -0
  55. package/src/lock.ts +90 -0
  56. package/src/package.ts +72 -23
  57. package/src/structure.ts +8 -3
  58. package/src/transfer.ts +56 -0
  59. package/src/workspace.ts +3 -5
@@ -31,6 +31,8 @@ import { VariantType, StructType, ArrayType, StringType, IntegerType, DateTimeTy
31
31
  export const ExecutionStatusType = VariantType({
32
32
  /** Task has been launched but not yet completed */
33
33
  running: StructType({
34
+ /** Unique execution ID (UUIDv7) */
35
+ executionId: StringType,
34
36
  /** Input dataset hashes */
35
37
  inputHashes: ArrayType(StringType),
36
38
  /** When execution started */
@@ -44,6 +46,8 @@ export const ExecutionStatusType = VariantType({
44
46
  }),
45
47
  /** Task ran and returned exit code 0 */
46
48
  success: StructType({
49
+ /** Unique execution ID (UUIDv7) */
50
+ executionId: StringType,
47
51
  /** Input dataset hashes */
48
52
  inputHashes: ArrayType(StringType),
49
53
  /** Hash of the output dataset */
@@ -55,6 +59,8 @@ export const ExecutionStatusType = VariantType({
55
59
  }),
56
60
  /** Task ran and returned non-zero exit code */
57
61
  failed: StructType({
62
+ /** Unique execution ID (UUIDv7) */
63
+ executionId: StringType,
58
64
  /** Input dataset hashes */
59
65
  inputHashes: ArrayType(StringType),
60
66
  /** When execution started */
@@ -66,6 +72,8 @@ export const ExecutionStatusType = VariantType({
66
72
  }),
67
73
  /** e3 execution engine had an internal error */
68
74
  error: StructType({
75
+ /** Unique execution ID (UUIDv7) */
76
+ executionId: StringType,
69
77
  /** Input dataset hashes */
70
78
  inputHashes: ArrayType(StringType),
71
79
  /** When execution started */
@@ -1 +1 @@
1
- {"version":3,"file":"execution.js","sourceRoot":"","sources":["../../src/execution.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;;;;;;;;;GAWG;AAEH,OAAO,EACL,WAAW,EACX,UAAU,EACV,SAAS,EACT,UAAU,EACV,WAAW,EACX,YAAY,GAEb,MAAM,eAAe,CAAC;AAEvB;;;;;;;;;;;;GAYG;AACH,MAAM,CAAC,MAAM,mBAAmB,GAAG,WAAW,CAAC;IAC7C,mDAAmD;IACnD,OAAO,EAAE,UAAU,CAAC;QAClB,2BAA2B;QAC3B,WAAW,EAAE,SAAS,CAAC,UAAU,CAAC;QAClC,6BAA6B;QAC7B,SAAS,EAAE,YAAY;QACvB,+BAA+B;QAC/B,GAAG,EAAE,WAAW;QAChB,gFAAgF;QAChF,YAAY,EAAE,WAAW;QACzB,4DAA4D;QAC5D,MAAM,EAAE,UAAU;KACnB,CAAC;IACF,wCAAwC;IACxC,OAAO,EAAE,UAAU,CAAC;QAClB,2BAA2B;QAC3B,WAAW,EAAE,SAAS,CAAC,UAAU,CAAC;QAClC,iCAAiC;QACjC,UAAU,EAAE,UAAU;QACtB,6BAA6B;QAC7B,SAAS,EAAE,YAAY;QACvB,+BAA+B;QAC/B,WAAW,EAAE,YAAY;KAC1B,CAAC;IACF,+CAA+C;IAC/C,MAAM,EAAE,UAAU,CAAC;QACjB,2BAA2B;QAC3B,WAAW,EAAE,SAAS,CAAC,UAAU,CAAC;QAClC,6BAA6B;QAC7B,SAAS,EAAE,YAAY;QACvB,+BAA+B;QAC/B,WAAW,EAAE,YAAY;QACzB,wBAAwB;QACxB,QAAQ,EAAE,WAAW;KACtB,CAAC;IACF,gDAAgD;IAChD,KAAK,EAAE,UAAU,CAAC;QAChB,2BAA2B;QAC3B,WAAW,EAAE,SAAS,CAAC,UAAU,CAAC;QAClC,6BAA6B;QAC7B,SAAS,EAAE,YAAY;Q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KACtB,CAAC;IACF,gDAAgD;IAChD,KAAK,EAAE,UAAU,CAAC;QAChB,mCAAmC;QACnC,WAAW,EAAE,UAAU;QACvB,2BAA2B;QAC3B,WAAW,EAAE,SAAS,CAAC,UAAU,CAAC;QAClC,6BAA6B;QAC7B,SAAS,EAAE,YAAY;QACvB,+BAA+B;QAC/B,WAAW,EAAE,YAAY;QACzB,+CAA+C;QAC/C,OAAO,EAAE,UAAU;KACpB,CAAC;CACH,CAAC,CAAC"}
@@ -21,9 +21,15 @@
21
21
  * - **Path**: An address in the data tree
22
22
  */
23
23
  export { DataRefType, type DataRef, unassignedRef, nullRef, DataTreeType, } from './dataset.js';
24
+ export { VersionVectorType, type VersionVector, DatasetRefType, type DatasetRef, } from './dataset-ref.js';
24
25
  export { TaskObjectType, type TaskObject, } from './task.js';
25
26
  export { StructureType, type Structure, PathSegmentType, type PathSegment, TreePathType, type TreePath, type ParsePathResult, type ParseDatasetPathResult, type ParsePackageRefResult, treePath, pathToString, parsePath, parseDatasetPath, parsePackageRef, urlPathToTreePath, DatasetSchemaType, type DatasetSchema, } from './structure.js';
26
- export { PackageDataType, type PackageData, PackageObjectType, type PackageObject, PackageDatasetsType, type PackageDatasets, } from './package.js';
27
+ export { PackageDataType, type PackageData, PackageObjectType, type PackageObject, PackageDatasetsType, type PackageDatasets, PackageTransferInitRequestType, type PackageTransferInitRequest, PackageTransferInitResponseType, type PackageTransferInitResponse, PackageJobResponseType, type PackageJobResponse, PackageImportResultType, type PackageImportResult, PackageExportResultType, type PackageExportResult, PackageImportProgressType, type PackageImportProgress, PackageImportStatusType, type PackageImportStatus, PackageExportProgressType, type PackageExportProgress, PackageExportStatusType, type PackageExportStatus, } from './package.js';
27
28
  export { WorkspaceStateType, type WorkspaceState, } from './workspace.js';
28
29
  export { ExecutionStatusType, type ExecutionStatus, } from './execution.js';
30
+ export { LockOperationType, type LockOperation, ProcessHolderType, type ProcessHolder, LockStateType, type LockState, } from './lock.js';
31
+ export { TransferUploadRequestType, type TransferUploadRequest, TransferUploadResponseType, type TransferUploadResponse, TransferDoneResponseType, type TransferDoneResponse, } from './transfer.js';
32
+ export { BEAST2_CONTENT_TYPE } from './constants.js';
33
+ export { WorkspaceNotFoundErrorType, WorkspaceNotDeployedErrorType, WorkspaceExistsErrorType, LockHolderType, WorkspaceLockedErrorType, PackageNotFoundErrorType, PackageExistsErrorType, PackageInvalidErrorType, DatasetNotFoundErrorType, TaskNotFoundErrorType, ExecutionNotFoundErrorType, ObjectNotFoundErrorType, DataflowErrorType, PermissionDeniedErrorType, InternalErrorType, RepositoryNotFoundErrorType, ErrorType, ResponseType, RepositoryStatusType, GcRequestType, GcResultType, AsyncOperationStatusType, GcStartResultType, GcStatusResultType, PackageListItemType, PackageInfoType, PackageDetailsType, WorkspaceCreateRequestType, WorkspaceInfoType, WorkspaceDeployRequestType, WorkspaceExportRequestType, DatasetStatusType, TaskStatusUpToDateType, TaskStatusWaitingType, TaskStatusInProgressType, TaskStatusFailedType, TaskStatusErrorType, TaskStatusStaleRunningType, TaskStatusType, DatasetStatusInfoType, TaskStatusInfoType, WorkspaceStatusSummaryType, WorkspaceStatusResultType, TaskListItemType, TaskDetailsType, DataflowRequestType, LogChunkType, TaskExecutionResultType, DataflowResultType, DataflowEventType, ApiExecutionStatusType, DataflowExecutionSummaryType, ApiDataflowExecutionStateType, ExecutionHistoryStatusType, ExecutionListItemType, TreeKindType, ListEntryType, DatasetStatusDetailType, type Error, type RepositoryStatus, type GcRequest, type GcResult, type AsyncOperationStatus, type GcStartResult, type GcStatusResult, type PackageListItem, type PackageInfo, type PackageDetails, type WorkspaceInfo, type WorkspaceCreateRequest, type WorkspaceDeployRequest, type DatasetStatus, type TaskStatus as ApiTaskStatus, type DatasetStatusInfo, type TaskStatusInfo, type WorkspaceStatusSummary, type WorkspaceStatusResult, type TaskListItem, type TaskDetails, type DataflowRequest, type LogChunk, type TaskExecutionResult, type DataflowResult, type DataflowEvent, type ApiExecutionStatus, type DataflowExecutionSummary, type ApiDataflowExecutionState, type ExecutionHistoryStatus, type ExecutionListItem, type TreeKind, type ListEntry, type DatasetStatusDetail, } from './api.js';
34
+ export { type DataflowExecutionStatus, type TaskStatus, TaskStateType, type TaskState, DataflowGraphTaskType, type DataflowGraphTask, DataflowGraphType, type DataflowGraph, ExecutionEventType, type ExecutionEvent, DataflowExecutionStateType, type DataflowExecutionState, DataflowRunStatusType, type DataflowRunStatus, TaskExecutionRecordType, type TaskExecutionRecord, DataflowRunSummaryType, type DataflowRunSummary, DataflowRunType, type DataflowRun, } from './dataflow.js';
29
35
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;;;;;;;;;;;;;;;GAiBG;AAGH,OAAO,EACL,WAAW,EACX,KAAK,OAAO,EACZ,aAAa,EACb,OAAO,EACP,YAAY,GACb,MAAM,cAAc,CAAC;AAGtB,OAAO,EACL,cAAc,EACd,KAAK,UAAU,GAChB,MAAM,WAAW,CAAC;AAGnB,OAAO,EACL,aAAa,EACb,KAAK,SAAS,EACd,eAAe,EACf,KAAK,WAAW,EAChB,YAAY,EACZ,KAAK,QAAQ,EACb,KAAK,eAAe,EACpB,KAAK,sBAAsB,EAC3B,KAAK,qBAAqB,EAC1B,QAAQ,EACR,YAAY,EACZ,SAAS,EACT,gBAAgB,EAChB,eAAe,EACf,iBAAiB,EAEjB,iBAAiB,EACjB,KAAK,aAAa,GACnB,MAAM,gBAAgB,CAAC;AAGxB,OAAO,EACL,eAAe,EACf,KAAK,WAAW,EAChB,iBAAiB,EACjB,KAAK,aAAa,EAElB,mBAAmB,EACnB,KAAK,eAAe,GACrB,MAAM,cAAc,CAAC;AAGtB,OAAO,EACL,kBAAkB,EAClB,KAAK,cAAc,GACpB,MAAM,gBAAgB,CAAC;AAGxB,OAAO,EACL,mBAAmB,EACnB,KAAK,eAAe,GACrB,MAAM,gBAAgB,CAAC"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B,EACrB,KAAK,SAAS,EACd,KAAK,QAAQ,EACb,KAAK,oBAAoB,EACzB,KAAK,aAAa,EAClB,KAAK,cAAc,EACnB,KAAK,eAAe,EACpB,KAAK,WAAW,EAChB,KAAK,cAAc,EACnB,KAAK,aAAa,EAClB,KAAK,sBAAsB,EAC3B,KAAK,sBAAsB,EAC3B,KAAK,aAAa,EAClB,KAAK,UAAU,IAAI,aAAa,EAChC,KAAK,iBAAiB,EACtB,KAAK,cAAc,EACnB,KAAK,sBAAsB,EAC3B,KAAK,qBAAqB,EAC1B,KAAK,YAAY,EACjB,KAAK,WAAW,EAChB,KAAK,eAAe,EACpB,KAAK,QAAQ,EACb,KAAK,mBAAmB,EACxB,KAAK,cAAc,EACnB,KAAK,aAAa,EAClB,KAAK,kBAAkB,EACvB,KAAK,wBAAwB,EAC7B,KAAK,yBAAyB,EAC9B,KAAK,sBAAsB,EAC3B,KAAK,iBAAiB,EACtB,KAAK,QAAQ,EACb,KAAK,SAAS,EACd,KAAK,mBAAmB,GACzB,MAAM,UAAU,CAAC;AAGlB,OAAO,EACL,KAAK,uBAAuB,EAC5B,KAAK,UAAU,EACf,aAAa,EACb,KAAK,SAAS,EACd,qBAAqB,EACrB,KAAK,iBAAiB,EACtB,iBAAiB,EACjB,KAAK,aAAa,EAClB,kBAAkB,EAClB,KAAK,cAAc,EACnB,0BAA0B,EAC1B,KAAK,sBAAsB,EAE3B,qBAAqB,EACrB,KAAK,iBAAiB,EACtB,uBAAuB,EACvB,KAAK,mBAAmB,EACxB,sBAAsB,EACtB,KAAK,kBAAkB,EACvB,eAAe,EACf,KAAK,WAAW,GACjB,MAAM,eAAe,CAAC"}
package/dist/src/index.js CHANGED
@@ -22,6 +22,8 @@
22
22
  */
23
23
  // Data references and trees
24
24
  export { DataRefType, unassignedRef, nullRef, DataTreeType, } from './dataset.js';
25
+ // Per-dataset refs and version vectors (reactive dataflow)
26
+ export { VersionVectorType, DatasetRefType, } from './dataset-ref.js';
25
27
  // Task definitions
26
28
  export { TaskObjectType, } from './task.js';
27
29
  // Data structure and paths
@@ -31,9 +33,45 @@ DatasetSchemaType, } from './structure.js';
31
33
  // Package objects
32
34
  export { PackageDataType, PackageObjectType,
33
35
  // Backwards compatibility
34
- PackageDatasetsType, } from './package.js';
36
+ PackageDatasetsType,
37
+ // Package transfer types
38
+ PackageTransferInitRequestType, PackageTransferInitResponseType, PackageJobResponseType, PackageImportResultType, PackageExportResultType, PackageImportProgressType, PackageImportStatusType, PackageExportProgressType, PackageExportStatusType, } from './package.js';
35
39
  // Workspace state
36
40
  export { WorkspaceStateType, } from './workspace.js';
37
41
  // Execution status
38
42
  export { ExecutionStatusType, } from './execution.js';
43
+ // Lock state
44
+ export { LockOperationType, ProcessHolderType, LockStateType, } from './lock.js';
45
+ // Dataset transfer types
46
+ export { TransferUploadRequestType, TransferUploadResponseType, TransferDoneResponseType, } from './transfer.js';
47
+ // Wire format constants
48
+ export { BEAST2_CONTENT_TYPE } from './constants.js';
49
+ // API wire types (shared between e3-api-client and e3-api-server)
50
+ export {
51
+ // Error types
52
+ WorkspaceNotFoundErrorType, WorkspaceNotDeployedErrorType, WorkspaceExistsErrorType, LockHolderType, WorkspaceLockedErrorType, PackageNotFoundErrorType, PackageExistsErrorType, PackageInvalidErrorType, DatasetNotFoundErrorType, TaskNotFoundErrorType, ExecutionNotFoundErrorType, ObjectNotFoundErrorType, DataflowErrorType, PermissionDeniedErrorType, InternalErrorType, RepositoryNotFoundErrorType, ErrorType, ResponseType,
53
+ // Repository
54
+ RepositoryStatusType, GcRequestType, GcResultType, AsyncOperationStatusType, GcStartResultType, GcStatusResultType,
55
+ // Packages
56
+ PackageListItemType, PackageInfoType, PackageDetailsType,
57
+ // Workspaces
58
+ WorkspaceCreateRequestType, WorkspaceInfoType, WorkspaceDeployRequestType, WorkspaceExportRequestType,
59
+ // Workspace Status
60
+ DatasetStatusType, TaskStatusUpToDateType, TaskStatusWaitingType, TaskStatusInProgressType, TaskStatusFailedType, TaskStatusErrorType, TaskStatusStaleRunningType, TaskStatusType, DatasetStatusInfoType, TaskStatusInfoType, WorkspaceStatusSummaryType, WorkspaceStatusResultType,
61
+ // Tasks
62
+ TaskListItemType, TaskDetailsType,
63
+ // Execution
64
+ DataflowRequestType, LogChunkType, TaskExecutionResultType, DataflowResultType,
65
+ // Dataflow API polling
66
+ DataflowEventType, ApiExecutionStatusType, DataflowExecutionSummaryType, ApiDataflowExecutionStateType,
67
+ // Task Execution History
68
+ ExecutionHistoryStatusType, ExecutionListItemType,
69
+ // Dataset List
70
+ TreeKindType, ListEntryType,
71
+ // Dataset Status Detail
72
+ DatasetStatusDetailType, } from './api.js';
73
+ // Dataflow execution state
74
+ export { TaskStateType, DataflowGraphTaskType, DataflowGraphType, ExecutionEventType, DataflowExecutionStateType,
75
+ // Dataflow run history
76
+ DataflowRunStatusType, TaskExecutionRecordType, DataflowRunSummaryType, DataflowRunType, } from './dataflow.js';
39
77
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;;;;;;;;;;;;;;;GAiBG;AAEH,4BAA4B;AAC5B,OAAO,EACL,WAAW,EAEX,aAAa,EACb,OAAO,EACP,YAAY,GACb,MAAM,cAAc,CAAC;AAEtB,mBAAmB;AACnB,OAAO,EACL,cAAc,GAEf,MAAM,WAAW,CAAC;AAEnB,2BAA2B;AAC3B,OAAO,EACL,aAAa,EAEb,eAAe,EAEf,YAAY,EAKZ,QAAQ,EACR,YAAY,EACZ,SAAS,EACT,gBAAgB,EAChB,eAAe,EACf,iBAAiB;AACjB,0BAA0B;AAC1B,iBAAiB,GAElB,MAAM,gBAAgB,CAAC;AAExB,kBAAkB;AAClB,OAAO,EACL,eAAe,EAEf,iBAAiB;AAEjB,0BAA0B;AAC1B,mBAAmB,GAEpB,MAAM,cAAc,CAAC;AAEtB,kBAAkB;AAClB,OAAO,EACL,kBAAkB,GAEnB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e,GAEhB,MAAM,eAAe,CAAC"}
@@ -0,0 +1,85 @@
1
+ /**
2
+ * Copyright (c) 2025 Elara AI Pty Ltd
3
+ * Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details.
4
+ */
5
+ /**
6
+ * Lock state type definitions.
7
+ *
8
+ * A lock provides exclusive access to a workspace. The state tracks:
9
+ * - What operation acquired the lock (dataflow, deployment, etc.)
10
+ * - Who holds the lock (East text-encoded string)
11
+ * - When it was acquired
12
+ * - Optional expiry (for cloud TTL-based locks)
13
+ *
14
+ * Lock file location: workspaces/<name>.lock
15
+ *
16
+ * The holder field is an East text-encoded string, allowing different backends
17
+ * to encode their own holder identification. Common patterns:
18
+ * - Local: `.process (pid=1234, bootId="abc-123", startTime=98765, command="e3 start")`
19
+ * - Cloud: `.lambda (requestId="req-123", functionName="e3-api")`
20
+ */
21
+ import { VariantType, StructType, StringType, IntegerType, DateTimeType, OptionType, NullType, ValueTypeOf } from '@elaraai/east';
22
+ /**
23
+ * Lock operation - what acquired the lock.
24
+ */
25
+ export declare const LockOperationType: VariantType<{
26
+ /** Running a dataflow */
27
+ readonly dataflow: NullType;
28
+ /** Deploying a package to the workspace */
29
+ readonly deployment: NullType;
30
+ /** Removing the workspace */
31
+ readonly removal: NullType;
32
+ /** Writing to a dataset */
33
+ readonly dataset_write: NullType;
34
+ /** Exporting a workspace */
35
+ readonly export: NullType;
36
+ }>;
37
+ export type LockOperation = ValueTypeOf<typeof LockOperationType>;
38
+ /**
39
+ * Process holder schema - for local filesystem backends.
40
+ * Used to encode/decode the holder string.
41
+ */
42
+ export declare const ProcessHolderType: StructType<{
43
+ /** Process ID */
44
+ readonly pid: IntegerType;
45
+ /** System boot ID (from /proc/sys/kernel/random/boot_id) */
46
+ readonly bootId: StringType;
47
+ /** Process start time in jiffies since boot */
48
+ readonly startTime: IntegerType;
49
+ /** Command that acquired the lock (for debugging) */
50
+ readonly command: StringType;
51
+ }>;
52
+ export type ProcessHolder = ValueTypeOf<typeof ProcessHolderType>;
53
+ /**
54
+ * Lock state stored in workspaces/<name>.lock
55
+ *
56
+ * Represents an advisory lock on a workspace. The actual locking mechanism
57
+ * is platform-specific (flock on Linux, DynamoDB conditional writes in cloud),
58
+ * but the lock content follows this schema.
59
+ *
60
+ * The holder field is an East text-encoded string representing a variant value.
61
+ * Use `printFor`/`parseInferred` from @elaraai/east to encode/decode.
62
+ */
63
+ export declare const LockStateType: StructType<{
64
+ /** What operation acquired the lock */
65
+ readonly operation: VariantType<{
66
+ /** Running a dataflow */
67
+ readonly dataflow: NullType;
68
+ /** Deploying a package to the workspace */
69
+ readonly deployment: NullType;
70
+ /** Removing the workspace */
71
+ readonly removal: NullType;
72
+ /** Writing to a dataset */
73
+ readonly dataset_write: NullType;
74
+ /** Exporting a workspace */
75
+ readonly export: NullType;
76
+ }>;
77
+ /** Who holds the lock - East text-encoded variant (e.g., `.process (...)`) */
78
+ readonly holder: StringType;
79
+ /** When the lock was acquired */
80
+ readonly acquiredAt: DateTimeType;
81
+ /** When the lock expires (for cloud TTL-based locks) */
82
+ readonly expiresAt: OptionType<DateTimeType>;
83
+ }>;
84
+ export type LockState = ValueTypeOf<typeof LockStateType>;
85
+ //# sourceMappingURL=lock.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"lock.d.ts","sourceRoot":"","sources":["../../src/lock.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,EACL,WAAW,EACX,UAAU,EACV,UAAU,EACV,WAAW,EACX,YAAY,EACZ,UAAU,EACV,QAAQ,EACR,WAAW,EACZ,MAAM,eAAe,CAAC;AAEvB;;GAEG;AACH,eAAO,MAAM,iBAAiB;IAC5B,yBAAyB;;IAEzB,2CAA2C;;IAE3C,6BAA6B;;IAE7B,2BAA2B;;IAE3B,4BAA4B;;EAE5B,CAAC;AAEH,MAAM,MAAM,aAAa,GAAG,WAAW,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAElE;;;GAGG;AACH,eAAO,MAAM,iBAAiB;IAC5B,iBAAiB;;IAEjB,4DAA4D;;IAE5D,+CAA+C;;IAE/C,qDAAqD;;EAErD,CAAC;AAEH,MAAM,MAAM,aAAa,GAAG,WAAW,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAElE;;;;;;;;;GASG;AACH,eAAO,MAAM,aAAa;IACxB,uCAAuC;;QA1CvC,yBAAyB;;QAEzB,2CAA2C;;QAE3C,6BAA6B;;QAE7B,2BAA2B;;QAE3B,4BAA4B;;;IAoC5B,8EAA8E;;IAE9E,iCAAiC;;IAEjC,wDAAwD;;EAExD,CAAC;AAEH,MAAM,MAAM,SAAS,GAAG,WAAW,CAAC,OAAO,aAAa,CAAC,CAAC"}
@@ -0,0 +1,71 @@
1
+ /**
2
+ * Copyright (c) 2025 Elara AI Pty Ltd
3
+ * Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details.
4
+ */
5
+ /**
6
+ * Lock state type definitions.
7
+ *
8
+ * A lock provides exclusive access to a workspace. The state tracks:
9
+ * - What operation acquired the lock (dataflow, deployment, etc.)
10
+ * - Who holds the lock (East text-encoded string)
11
+ * - When it was acquired
12
+ * - Optional expiry (for cloud TTL-based locks)
13
+ *
14
+ * Lock file location: workspaces/<name>.lock
15
+ *
16
+ * The holder field is an East text-encoded string, allowing different backends
17
+ * to encode their own holder identification. Common patterns:
18
+ * - Local: `.process (pid=1234, bootId="abc-123", startTime=98765, command="e3 start")`
19
+ * - Cloud: `.lambda (requestId="req-123", functionName="e3-api")`
20
+ */
21
+ import { VariantType, StructType, StringType, IntegerType, DateTimeType, OptionType, NullType, } from '@elaraai/east';
22
+ /**
23
+ * Lock operation - what acquired the lock.
24
+ */
25
+ export const LockOperationType = VariantType({
26
+ /** Running a dataflow */
27
+ dataflow: NullType,
28
+ /** Deploying a package to the workspace */
29
+ deployment: NullType,
30
+ /** Removing the workspace */
31
+ removal: NullType,
32
+ /** Writing to a dataset */
33
+ dataset_write: NullType,
34
+ /** Exporting a workspace */
35
+ export: NullType,
36
+ });
37
+ /**
38
+ * Process holder schema - for local filesystem backends.
39
+ * Used to encode/decode the holder string.
40
+ */
41
+ export const ProcessHolderType = StructType({
42
+ /** Process ID */
43
+ pid: IntegerType,
44
+ /** System boot ID (from /proc/sys/kernel/random/boot_id) */
45
+ bootId: StringType,
46
+ /** Process start time in jiffies since boot */
47
+ startTime: IntegerType,
48
+ /** Command that acquired the lock (for debugging) */
49
+ command: StringType,
50
+ });
51
+ /**
52
+ * Lock state stored in workspaces/<name>.lock
53
+ *
54
+ * Represents an advisory lock on a workspace. The actual locking mechanism
55
+ * is platform-specific (flock on Linux, DynamoDB conditional writes in cloud),
56
+ * but the lock content follows this schema.
57
+ *
58
+ * The holder field is an East text-encoded string representing a variant value.
59
+ * Use `printFor`/`parseInferred` from @elaraai/east to encode/decode.
60
+ */
61
+ export const LockStateType = StructType({
62
+ /** What operation acquired the lock */
63
+ operation: LockOperationType,
64
+ /** Who holds the lock - East text-encoded variant (e.g., `.process (...)`) */
65
+ holder: StringType,
66
+ /** When the lock was acquired */
67
+ acquiredAt: DateTimeType,
68
+ /** When the lock expires (for cloud TTL-based locks) */
69
+ expiresAt: OptionType(DateTimeType),
70
+ });
71
+ //# sourceMappingURL=lock.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"lock.js","sourceRoot":"","sources":["../../src/lock.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,EACL,WAAW,EACX,UAAU,EACV,UAAU,EACV,WAAW,EACX,YAAY,EACZ,UAAU,EACV,QAAQ,GAET,MAAM,eAAe,CAAC;AAEvB;;GAEG;AACH,MAAM,CAAC,MAAM,iBAAiB,GAAG,WAAW,CAAC;IAC3C,yBAAyB;IACzB,QAAQ,EAAE,QAAQ;IAClB,2CAA2C;IAC3C,UAAU,EAAE,QAAQ;IACpB,6BAA6B;IAC7B,OAAO,EAAE,QAAQ;IACjB,2BAA2B;IAC3B,aAAa,EAAE,QAAQ;IACvB,4BAA4B;IAC5B,MAAM,EAAE,QAAQ;CACjB,CAAC,CAAC;AAIH;;;GAGG;AACH,MAAM,CAAC,MAAM,iBAAiB,GAAG,UAAU,CAAC;IAC1C,iBAAiB;IACjB,GAAG,EAAE,WAAW;IAChB,4DAA4D;IAC5D,MAAM,EAAE,UAAU;IAClB,+CAA+C;IAC/C,SAAS,EAAE,WAAW;IACtB,qDAAqD;IACrD,OAAO,EAAE,UAAU;CACpB,CAAC,CAAC;AAIH;;;;;;;;;GASG;AACH,MAAM,CAAC,MAAM,aAAa,GAAG,UAAU,CAAC;IACtC,uCAAuC;IACvC,SAAS,EAAE,iBAAiB;IAC5B,8EAA8E;IAC9E,MAAM,EAAE,UAAU;IAClB,iCAAiC;IACjC,UAAU,EAAE,YAAY;IACxB,wDAAwD;IACxD,SAAS,EAAE,UAAU,CAAC,YAAY,CAAC;CACpC,CAAC,CAAC"}