@telorun/kernel 0.13.0 → 0.13.2

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 (104) hide show
  1. package/package.json +2 -2
  2. package/dist/base-definition.d.ts +0 -14
  3. package/dist/base-definition.d.ts.map +0 -1
  4. package/dist/base-definition.js +0 -17
  5. package/dist/base-definition.js.map +0 -1
  6. package/dist/capabilities/capabilities/component.yaml +0 -4
  7. package/dist/capabilities/capabilities/executable.yaml +0 -8
  8. package/dist/capabilities/capabilities/handler.yaml +0 -4
  9. package/dist/capabilities/capabilities/listener.yaml +0 -4
  10. package/dist/capabilities/capabilities/provider.yaml +0 -4
  11. package/dist/capabilities/capabilities/template.yaml +0 -4
  12. package/dist/capabilities/capabilities/type.yaml +0 -4
  13. package/dist/capabilities/component.d.ts +0 -3
  14. package/dist/capabilities/component.d.ts.map +0 -1
  15. package/dist/capabilities/component.js +0 -4
  16. package/dist/capabilities/component.js.map +0 -1
  17. package/dist/capabilities/component.yaml +0 -3
  18. package/dist/capabilities/executable.d.ts +0 -3
  19. package/dist/capabilities/executable.d.ts.map +0 -1
  20. package/dist/capabilities/executable.js +0 -5
  21. package/dist/capabilities/executable.js.map +0 -1
  22. package/dist/capabilities/executable.yaml +0 -7
  23. package/dist/capabilities/handler.d.ts +0 -3
  24. package/dist/capabilities/handler.d.ts.map +0 -1
  25. package/dist/capabilities/handler.js +0 -4
  26. package/dist/capabilities/handler.js.map +0 -1
  27. package/dist/capabilities/handler.yaml +0 -3
  28. package/dist/capabilities/invokable.d.ts +0 -3
  29. package/dist/capabilities/invokable.d.ts.map +0 -1
  30. package/dist/capabilities/invokable.js +0 -5
  31. package/dist/capabilities/invokable.js.map +0 -1
  32. package/dist/capabilities/listener.d.ts +0 -3
  33. package/dist/capabilities/listener.d.ts.map +0 -1
  34. package/dist/capabilities/listener.js +0 -5
  35. package/dist/capabilities/listener.js.map +0 -1
  36. package/dist/capabilities/listener.yaml +0 -3
  37. package/dist/capabilities/mount.d.ts +0 -3
  38. package/dist/capabilities/mount.d.ts.map +0 -1
  39. package/dist/capabilities/mount.js +0 -5
  40. package/dist/capabilities/mount.js.map +0 -1
  41. package/dist/capabilities/provider.d.ts +0 -3
  42. package/dist/capabilities/provider.d.ts.map +0 -1
  43. package/dist/capabilities/provider.js +0 -8
  44. package/dist/capabilities/provider.js.map +0 -1
  45. package/dist/capabilities/provider.yaml +0 -3
  46. package/dist/capabilities/runnable.d.ts +0 -3
  47. package/dist/capabilities/runnable.d.ts.map +0 -1
  48. package/dist/capabilities/runnable.js +0 -5
  49. package/dist/capabilities/runnable.js.map +0 -1
  50. package/dist/capabilities/service.d.ts +0 -3
  51. package/dist/capabilities/service.d.ts.map +0 -1
  52. package/dist/capabilities/service.js +0 -5
  53. package/dist/capabilities/service.js.map +0 -1
  54. package/dist/capabilities/template.d.ts +0 -3
  55. package/dist/capabilities/template.d.ts.map +0 -1
  56. package/dist/capabilities/template.js +0 -5
  57. package/dist/capabilities/template.js.map +0 -1
  58. package/dist/capabilities/template.yaml +0 -3
  59. package/dist/capabilities/type.d.ts +0 -3
  60. package/dist/capabilities/type.d.ts.map +0 -1
  61. package/dist/capabilities/type.js +0 -5
  62. package/dist/capabilities/type.js.map +0 -1
  63. package/dist/capabilities/type.yaml +0 -3
  64. package/dist/controllers/capability/capability-controller.d.ts +0 -32
  65. package/dist/controllers/capability/capability-controller.d.ts.map +0 -1
  66. package/dist/controllers/capability/capability-controller.js +0 -26
  67. package/dist/controllers/capability/capability-controller.js.map +0 -1
  68. package/dist/controllers/module/module.json +0 -48
  69. package/dist/loader.d.ts +0 -18
  70. package/dist/loader.d.ts.map +0 -1
  71. package/dist/loader.js +0 -127
  72. package/dist/loader.js.map +0 -1
  73. package/dist/manifest-adapters/http-adapter.d.ts +0 -8
  74. package/dist/manifest-adapters/http-adapter.d.ts.map +0 -1
  75. package/dist/manifest-adapters/http-adapter.js +0 -31
  76. package/dist/manifest-adapters/http-adapter.js.map +0 -1
  77. package/dist/manifest-adapters/local-file-adapter.d.ts +0 -15
  78. package/dist/manifest-adapters/local-file-adapter.d.ts.map +0 -1
  79. package/dist/manifest-adapters/local-file-adapter.js +0 -95
  80. package/dist/manifest-adapters/local-file-adapter.js.map +0 -1
  81. package/dist/manifest-adapters/manifest-adapter.d.ts +0 -35
  82. package/dist/manifest-adapters/manifest-adapter.d.ts.map +0 -1
  83. package/dist/manifest-adapters/manifest-adapter.js +0 -2
  84. package/dist/manifest-adapters/manifest-adapter.js.map +0 -1
  85. package/dist/manifest-adapters/registry-adapter.d.ts +0 -9
  86. package/dist/manifest-adapters/registry-adapter.d.ts.map +0 -1
  87. package/dist/manifest-adapters/registry-adapter.js +0 -48
  88. package/dist/manifest-adapters/registry-adapter.js.map +0 -1
  89. package/dist/module-context-registry.d.ts +0 -48
  90. package/dist/module-context-registry.d.ts.map +0 -1
  91. package/dist/module-context-registry.js +0 -91
  92. package/dist/module-context-registry.js.map +0 -1
  93. package/dist/schema-valiator.d.ts +0 -15
  94. package/dist/schema-valiator.d.ts.map +0 -1
  95. package/dist/schema-valiator.js +0 -127
  96. package/dist/schema-valiator.js.map +0 -1
  97. package/dist/snapshot-serializer.d.ts +0 -62
  98. package/dist/snapshot-serializer.d.ts.map +0 -1
  99. package/dist/snapshot-serializer.js +0 -164
  100. package/dist/snapshot-serializer.js.map +0 -1
  101. package/dist/types.d.ts +0 -65
  102. package/dist/types.d.ts.map +0 -1
  103. package/dist/types.js +0 -8
  104. package/dist/types.js.map +0 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@telorun/kernel",
3
- "version": "0.13.0",
3
+ "version": "0.13.2",
4
4
  "description": "Telo Runtime - A lightweight, polyglot execution host.",
5
5
  "keywords": [
6
6
  "telo",
@@ -47,7 +47,7 @@
47
47
  "dependencies": {
48
48
  "@marcbachmann/cel-js": "^7.5.3",
49
49
  "@sinclair/typebox": "^0.34.48",
50
- "@telorun/analyzer": "0.12.0",
50
+ "@telorun/analyzer": "0.12.1",
51
51
  "@telorun/templating": "0.3.0",
52
52
  "ajv": "^8.17.1",
53
53
  "ajv-formats": "^3.0.1",
@@ -1,14 +0,0 @@
1
- import type { ModuleContext, ResourceContext, ResourceDefinition, ResourceInstance, ResourceManifest } from "@telorun/sdk";
2
- export interface BaseDefinition {
3
- name: string;
4
- expand?: {
5
- compile?: string[];
6
- runtime?: string[];
7
- };
8
- onDefinition?(definition: ResourceDefinition, ctx: ResourceContext): void | Promise<void>;
9
- onManifest?(manifest: ResourceManifest, ctx: ModuleContext): ResourceManifest | Promise<ResourceManifest>;
10
- onInit?(instance: ResourceInstance, ctx: ResourceContext): Promise<void>;
11
- onInvoke?(instance: ResourceInstance, inputs: any, ctx: ResourceContext): Promise<any>;
12
- }
13
- export declare function createBaseDefinition(def: BaseDefinition): BaseDefinition;
14
- //# sourceMappingURL=base-definition.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"base-definition.d.ts","sourceRoot":"","sources":["../src/base-definition.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,aAAa,EACb,eAAe,EACf,kBAAkB,EAClB,gBAAgB,EAChB,gBAAgB,EACjB,MAAM,cAAc,CAAC;AAEtB,MAAM,WAAW,cAAc;IAC7B,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,CAAC,EAAE;QACP,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;QACnB,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;KACpB,CAAC;IACF,YAAY,CAAC,CAAC,UAAU,EAAE,kBAAkB,EAAE,GAAG,EAAE,eAAe,GAAG,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAC1F,UAAU,CAAC,CACT,QAAQ,EAAE,gBAAgB,EAC1B,GAAG,EAAE,aAAa,GACjB,gBAAgB,GAAG,OAAO,CAAC,gBAAgB,CAAC,CAAC;IAChD,MAAM,CAAC,CAAC,QAAQ,EAAE,gBAAgB,EAAE,GAAG,EAAE,eAAe,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACzE,QAAQ,CAAC,CAAC,QAAQ,EAAE,gBAAgB,EAAE,MAAM,EAAE,GAAG,EAAE,GAAG,EAAE,eAAe,GAAG,OAAO,CAAC,GAAG,CAAC,CAAC;CACxF;AAED,wBAAgB,oBAAoB,CAAC,GAAG,EAAE,cAAc,GAAG,cAAc,CAoBxE"}
@@ -1,17 +0,0 @@
1
- export function createBaseDefinition(def) {
2
- const compile = def.expand?.compile ?? [];
3
- const runtime = def.expand?.runtime ?? [];
4
- return {
5
- ...def,
6
- onManifest: compile.length
7
- ? (manifest, ctx) => ctx.expandPaths(manifest, compile, runtime)
8
- : def.onManifest,
9
- onInvoke: runtime.length
10
- ? async (instance, inputs, _ctx) => {
11
- const expanded = _ctx.moduleContext.expandPaths(inputs, runtime);
12
- return instance.invoke(expanded);
13
- }
14
- : def.onInvoke,
15
- };
16
- }
17
- //# sourceMappingURL=base-definition.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"base-definition.js","sourceRoot":"","sources":["../src/base-definition.ts"],"names":[],"mappings":"AAuBA,MAAM,UAAU,oBAAoB,CAAC,GAAmB;IACtD,MAAM,OAAO,GAAG,GAAG,CAAC,MAAM,EAAE,OAAO,IAAI,EAAE,CAAC;IAC1C,MAAM,OAAO,GAAG,GAAG,CAAC,MAAM,EAAE,OAAO,IAAI,EAAE,CAAC;IAE1C,OAAO;QACL,GAAG,GAAG;QACN,UAAU,EAAE,OAAO,CAAC,MAAM;YACxB,CAAC,CAAC,CAAC,QAAQ,EAAE,GAAG,EAAE,EAAE,CAChB,GAAG,CAAC,WAAW,CAAC,QAAmC,EAAE,OAAO,EAAE,OAAO,CAAqB;YAC9F,CAAC,CAAC,GAAG,CAAC,UAAU;QAClB,QAAQ,EAAE,OAAO,CAAC,MAAM;YACtB,CAAC,CAAC,KAAK,EAAE,QAAQ,EAAE,MAAM,EAAE,IAAI,EAAE,EAAE;gBAC/B,MAAM,QAAQ,GAAG,IAAI,CAAC,aAAa,CAAC,WAAW,CAC7C,MAAiC,EACjC,OAAO,CACR,CAAC;gBACF,OAAO,QAAQ,CAAC,MAAO,CAAC,QAAQ,CAAC,CAAC;YACpC,CAAC;YACH,CAAC,CAAC,GAAG,CAAC,QAAQ;KACjB,CAAC;AACJ,CAAC"}
@@ -1,4 +0,0 @@
1
- kind: Kernel.Capability
2
- metadata:
3
- module: Kernel
4
- name: component
@@ -1,8 +0,0 @@
1
- kind: Kernel.Capability
2
- metadata:
3
- module: Kernel
4
- name: executable
5
- schema:
6
- type: object
7
- properties:
8
- foo: { type: string }
@@ -1,4 +0,0 @@
1
- kind: Kernel.Capability
2
- metadata:
3
- module: Kernel
4
- name: handler
@@ -1,4 +0,0 @@
1
- kind: Kernel.Capability
2
- metadata:
3
- module: Kernel
4
- name: listener
@@ -1,4 +0,0 @@
1
- kind: Kernel.Capability
2
- metadata:
3
- module: Kernel
4
- name: provider
@@ -1,4 +0,0 @@
1
- kind: Kernel.Capability
2
- metadata:
3
- module: Kernel
4
- name: template
@@ -1,4 +0,0 @@
1
- kind: Kernel.Capability
2
- metadata:
3
- module: Kernel
4
- name: type
@@ -1,3 +0,0 @@
1
- import type { BaseDefinition } from "../base-definition.js";
2
- export declare const component: BaseDefinition;
3
- //# sourceMappingURL=component.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"component.d.ts","sourceRoot":"","sources":["../../src/capabilities/component.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAE5D,eAAO,MAAM,SAAS,EAAE,cAEvB,CAAC"}
@@ -1,4 +0,0 @@
1
- export const component = {
2
- name: "component",
3
- };
4
- //# sourceMappingURL=component.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"component.js","sourceRoot":"","sources":["../../src/capabilities/component.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,SAAS,GAAmB;IACvC,IAAI,EAAE,WAAW;CAClB,CAAC"}
@@ -1,3 +0,0 @@
1
- kind: Kernel.Capability
2
- metadata:
3
- name: component
@@ -1,3 +0,0 @@
1
- import type { ResourceDefinition } from "@telorun/sdk";
2
- export declare const runnable: ResourceDefinition;
3
- //# sourceMappingURL=executable.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"executable.d.ts","sourceRoot":"","sources":["../../src/capabilities/executable.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAEvD,eAAO,MAAM,QAAQ,EAAE,kBAGtB,CAAC"}
@@ -1,5 +0,0 @@
1
- export const runnable = {
2
- kind: "Kernel.Abstract",
3
- metadata: { name: "Runnable", module: "Kernel" },
4
- };
5
- //# sourceMappingURL=executable.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"executable.js","sourceRoot":"","sources":["../../src/capabilities/executable.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,QAAQ,GAAuB;IAC1C,IAAI,EAAE,iBAAiB;IACvB,QAAQ,EAAE,EAAE,IAAI,EAAE,UAAU,EAAE,MAAM,EAAE,QAAQ,EAAE;CACjD,CAAC"}
@@ -1,7 +0,0 @@
1
- kind: Kernel.Capability
2
- metadata:
3
- name: executable
4
- schema:
5
- type: object
6
- properties:
7
- foo: { type: string }
@@ -1,3 +0,0 @@
1
- import type { BaseDefinition } from "../base-definition.js";
2
- export declare const handler: BaseDefinition;
3
- //# sourceMappingURL=handler.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"handler.d.ts","sourceRoot":"","sources":["../../src/capabilities/handler.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAE5D,eAAO,MAAM,OAAO,EAAE,cAErB,CAAC"}
@@ -1,4 +0,0 @@
1
- export const handler = {
2
- name: "handler",
3
- };
4
- //# sourceMappingURL=handler.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"handler.js","sourceRoot":"","sources":["../../src/capabilities/handler.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,OAAO,GAAmB;IACrC,IAAI,EAAE,SAAS;CAChB,CAAC"}
@@ -1,3 +0,0 @@
1
- kind: Kernel.Capability
2
- metadata:
3
- name: handler
@@ -1,3 +0,0 @@
1
- import type { ResourceDefinition } from "@telorun/sdk";
2
- export declare const invocable: ResourceDefinition;
3
- //# sourceMappingURL=invokable.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"invokable.d.ts","sourceRoot":"","sources":["../../src/capabilities/invokable.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAEvD,eAAO,MAAM,SAAS,EAAE,kBAGvB,CAAC"}
@@ -1,5 +0,0 @@
1
- export const invocable = {
2
- kind: "Kernel.Abstract",
3
- metadata: { name: "Invocable", module: "Kernel" },
4
- };
5
- //# sourceMappingURL=invokable.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"invokable.js","sourceRoot":"","sources":["../../src/capabilities/invokable.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,SAAS,GAAuB;IAC3C,IAAI,EAAE,iBAAiB;IACvB,QAAQ,EAAE,EAAE,IAAI,EAAE,WAAW,EAAE,MAAM,EAAE,QAAQ,EAAE;CAClD,CAAC"}
@@ -1,3 +0,0 @@
1
- import type { ResourceDefinition } from "@telorun/sdk";
2
- export declare const service: ResourceDefinition;
3
- //# sourceMappingURL=listener.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"listener.d.ts","sourceRoot":"","sources":["../../src/capabilities/listener.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAEvD,eAAO,MAAM,OAAO,EAAE,kBAGrB,CAAC"}
@@ -1,5 +0,0 @@
1
- export const service = {
2
- kind: "Kernel.Abstract",
3
- metadata: { name: "Service", module: "Kernel" },
4
- };
5
- //# sourceMappingURL=listener.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"listener.js","sourceRoot":"","sources":["../../src/capabilities/listener.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,OAAO,GAAuB;IACzC,IAAI,EAAE,iBAAiB;IACvB,QAAQ,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE,MAAM,EAAE,QAAQ,EAAE;CAChD,CAAC"}
@@ -1,3 +0,0 @@
1
- kind: Kernel.Capability
2
- metadata:
3
- name: listener
@@ -1,3 +0,0 @@
1
- import type { ResourceDefinition } from "@telorun/sdk";
2
- export declare const mount: ResourceDefinition;
3
- //# sourceMappingURL=mount.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"mount.d.ts","sourceRoot":"","sources":["../../src/capabilities/mount.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAEvD,eAAO,MAAM,KAAK,EAAE,kBAGnB,CAAC"}
@@ -1,5 +0,0 @@
1
- export const mount = {
2
- kind: "Kernel.Abstract",
3
- metadata: { name: "Mount", module: "Kernel" },
4
- };
5
- //# sourceMappingURL=mount.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"mount.js","sourceRoot":"","sources":["../../src/capabilities/mount.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,KAAK,GAAuB;IACvC,IAAI,EAAE,iBAAiB;IACvB,QAAQ,EAAE,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE;CAC9C,CAAC"}
@@ -1,3 +0,0 @@
1
- import type { ResourceDefinition } from "@telorun/sdk";
2
- export declare const provider: ResourceDefinition;
3
- //# sourceMappingURL=provider.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"provider.d.ts","sourceRoot":"","sources":["../../src/capabilities/provider.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAEvD,eAAO,MAAM,QAAQ,EAAE,kBAMtB,CAAC"}
@@ -1,8 +0,0 @@
1
- export const provider = {
2
- kind: "Kernel.Abstract",
3
- metadata: { name: "Provider", module: "Kernel" },
4
- expand: {
5
- compile: ["**"],
6
- },
7
- };
8
- //# sourceMappingURL=provider.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"provider.js","sourceRoot":"","sources":["../../src/capabilities/provider.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,QAAQ,GAAuB;IAC1C,IAAI,EAAE,iBAAiB;IACvB,QAAQ,EAAE,EAAE,IAAI,EAAE,UAAU,EAAE,MAAM,EAAE,QAAQ,EAAE;IAChD,MAAM,EAAE;QACN,OAAO,EAAE,CAAC,IAAI,CAAC;KAChB;CACF,CAAC"}
@@ -1,3 +0,0 @@
1
- kind: Kernel.Capability
2
- metadata:
3
- name: provider
@@ -1,3 +0,0 @@
1
- import type { ResourceDefinition } from "@telorun/sdk";
2
- export declare const runnable: ResourceDefinition;
3
- //# sourceMappingURL=runnable.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"runnable.d.ts","sourceRoot":"","sources":["../../src/capabilities/runnable.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAEvD,eAAO,MAAM,QAAQ,EAAE,kBAGtB,CAAC"}
@@ -1,5 +0,0 @@
1
- export const runnable = {
2
- kind: "Kernel.Abstract",
3
- metadata: { name: "Runnable", module: "Kernel" },
4
- };
5
- //# sourceMappingURL=runnable.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"runnable.js","sourceRoot":"","sources":["../../src/capabilities/runnable.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,QAAQ,GAAuB;IAC1C,IAAI,EAAE,iBAAiB;IACvB,QAAQ,EAAE,EAAE,IAAI,EAAE,UAAU,EAAE,MAAM,EAAE,QAAQ,EAAE;CACjD,CAAC"}
@@ -1,3 +0,0 @@
1
- import type { ResourceDefinition } from "@telorun/sdk";
2
- export declare const service: ResourceDefinition;
3
- //# sourceMappingURL=service.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"service.d.ts","sourceRoot":"","sources":["../../src/capabilities/service.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAEvD,eAAO,MAAM,OAAO,EAAE,kBAGrB,CAAC"}
@@ -1,5 +0,0 @@
1
- export const service = {
2
- kind: "Kernel.Abstract",
3
- metadata: { name: "Service", module: "Kernel" },
4
- };
5
- //# sourceMappingURL=service.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"service.js","sourceRoot":"","sources":["../../src/capabilities/service.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,OAAO,GAAuB;IACzC,IAAI,EAAE,iBAAiB;IACvB,QAAQ,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE,MAAM,EAAE,QAAQ,EAAE;CAChD,CAAC"}
@@ -1,3 +0,0 @@
1
- import type { ResourceDefinition } from "@telorun/sdk";
2
- export declare const template: ResourceDefinition;
3
- //# sourceMappingURL=template.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"template.d.ts","sourceRoot":"","sources":["../../src/capabilities/template.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAEvD,eAAO,MAAM,QAAQ,EAAE,kBAGtB,CAAC"}
@@ -1,5 +0,0 @@
1
- export const template = {
2
- kind: "Kernel.Abstract",
3
- metadata: { name: "Template", module: "Kernel" },
4
- };
5
- //# sourceMappingURL=template.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"template.js","sourceRoot":"","sources":["../../src/capabilities/template.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,QAAQ,GAAuB;IAC1C,IAAI,EAAE,iBAAiB;IACvB,QAAQ,EAAE,EAAE,IAAI,EAAE,UAAU,EAAE,MAAM,EAAE,QAAQ,EAAE;CACjD,CAAC"}
@@ -1,3 +0,0 @@
1
- kind: Kernel.Capability
2
- metadata:
3
- name: template
@@ -1,3 +0,0 @@
1
- import type { ResourceDefinition } from "@telorun/sdk";
2
- export declare const typeCapability: ResourceDefinition;
3
- //# sourceMappingURL=type.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"type.d.ts","sourceRoot":"","sources":["../../src/capabilities/type.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAEvD,eAAO,MAAM,cAAc,EAAE,kBAG5B,CAAC"}
@@ -1,5 +0,0 @@
1
- export const typeCapability = {
2
- kind: "Kernel.Abstract",
3
- metadata: { name: "Type", module: "Kernel" },
4
- };
5
- //# sourceMappingURL=type.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"type.js","sourceRoot":"","sources":["../../src/capabilities/type.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,cAAc,GAAuB;IAChD,IAAI,EAAE,iBAAiB;IACvB,QAAQ,EAAE,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,QAAQ,EAAE;CAC7C,CAAC"}
@@ -1,3 +0,0 @@
1
- kind: Kernel.Capability
2
- metadata:
3
- name: type
@@ -1,32 +0,0 @@
1
- import type { ResourceContext, ResourceInstance } from "@telorun/sdk";
2
- type CapabilityResource = {
3
- kind: string;
4
- metadata: {
5
- name: string;
6
- [key: string]: any;
7
- };
8
- };
9
- declare class Capability implements ResourceInstance {
10
- private readonly resource;
11
- constructor(resource: CapabilityResource);
12
- init(ctx: ResourceContext): Promise<void>;
13
- }
14
- export declare function create(resource: any, _ctx: ResourceContext): Promise<Capability>;
15
- export declare const schema: {
16
- type: string;
17
- properties: {
18
- metadata: {
19
- type: string;
20
- properties: {
21
- name: {
22
- type: string;
23
- };
24
- };
25
- required: string[];
26
- };
27
- };
28
- required: string[];
29
- additionalProperties: boolean;
30
- };
31
- export {};
32
- //# sourceMappingURL=capability-controller.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"capability-controller.d.ts","sourceRoot":"","sources":["../../../src/controllers/capability/capability-controller.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAC;AAEtE,KAAK,kBAAkB,GAAG;IACxB,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE;QACR,IAAI,EAAE,MAAM,CAAC;QACb,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAC;KACpB,CAAC;CACH,CAAC;AAEF,cAAM,UAAW,YAAW,gBAAgB;IAC9B,OAAO,CAAC,QAAQ,CAAC,QAAQ;gBAAR,QAAQ,EAAE,kBAAkB;IAEnD,IAAI,CAAC,GAAG,EAAE,eAAe;CAGhC;AAED,wBAAsB,MAAM,CAAC,QAAQ,EAAE,GAAG,EAAE,IAAI,EAAE,eAAe,GAAG,OAAO,CAAC,UAAU,CAAC,CAEtF;AAED,eAAO,MAAM,MAAM;;;;;;;;;;;;;;;CAalB,CAAC"}
@@ -1,26 +0,0 @@
1
- class Capability {
2
- constructor(resource) {
3
- this.resource = resource;
4
- }
5
- async init(ctx) {
6
- ctx.registerCapability(this.resource.metadata.name);
7
- }
8
- }
9
- export async function create(resource, _ctx) {
10
- return new Capability(resource);
11
- }
12
- export const schema = {
13
- type: "object",
14
- properties: {
15
- metadata: {
16
- type: "object",
17
- properties: {
18
- name: { type: "string" },
19
- },
20
- required: ["name"],
21
- },
22
- },
23
- required: ["metadata"],
24
- additionalProperties: true,
25
- };
26
- //# sourceMappingURL=capability-controller.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"capability-controller.js","sourceRoot":"","sources":["../../../src/controllers/capability/capability-controller.ts"],"names":[],"mappings":"AAUA,MAAM,UAAU;IACd,YAA6B,QAA4B;QAA5B,aAAQ,GAAR,QAAQ,CAAoB;IAAG,CAAC;IAE7D,KAAK,CAAC,IAAI,CAAC,GAAoB;QAC7B,GAAG,CAAC,kBAAkB,CAAC,IAAI,CAAC,QAAQ,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;IACtD,CAAC;CACF;AAED,MAAM,CAAC,KAAK,UAAU,MAAM,CAAC,QAAa,EAAE,IAAqB;IAC/D,OAAO,IAAI,UAAU,CAAC,QAA8B,CAAC,CAAC;AACxD,CAAC;AAED,MAAM,CAAC,MAAM,MAAM,GAAG;IACpB,IAAI,EAAE,QAAQ;IACd,UAAU,EAAE;QACV,QAAQ,EAAE;YACR,IAAI,EAAE,QAAQ;YACd,UAAU,EAAE;gBACV,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;aACzB;YACD,QAAQ,EAAE,CAAC,MAAM,CAAC;SACnB;KACF;IACD,QAAQ,EAAE,CAAC,UAAU,CAAC;IACtB,oBAAoB,EAAE,IAAI;CAC3B,CAAC"}
@@ -1,48 +0,0 @@
1
- {
2
- "type": "object",
3
- "properties": {
4
- "metadata": {
5
- "type": "object",
6
- "properties": {
7
- "name": {
8
- "type": "string"
9
- }
10
- },
11
- "required": ["name"]
12
- },
13
- "imports": {
14
- "type": "array",
15
- "items": {
16
- "type": "string"
17
- },
18
- "description": "Paths to other modules to import"
19
- },
20
- "definitions": {
21
- "type": "array",
22
- "items": {
23
- "type": "string"
24
- },
25
- "description": "Paths to ResourceDefinition files"
26
- },
27
- "resources": {
28
- "type": "array",
29
- "items": {
30
- "oneOf": [
31
- {
32
- "type": "string"
33
- },
34
- {
35
- "type": "object",
36
- "properties": {
37
- "path": {
38
- "type": "string"
39
- }
40
- }
41
- }
42
- ]
43
- },
44
- "description": "Paths to resource instance files to load"
45
- }
46
- },
47
- "required": ["metadata"]
48
- }
package/dist/loader.d.ts DELETED
@@ -1,18 +0,0 @@
1
- import { Loader as BaseLoader } from "@telorun/analyzer";
2
- import { ResourceManifest } from "@telorun/sdk";
3
- export declare class Loader extends BaseLoader {
4
- private static projectRoot;
5
- private readonly localAdapter;
6
- constructor();
7
- private static ensureProjectRoot;
8
- resolvePath(base: string, relative: string): string;
9
- /**
10
- * Resolve a path-or-URL to its canonical file source URL.
11
- * If the path refers to a directory, returns the URL of module.yaml inside it.
12
- */
13
- resolveEntryPoint(pathOrUrl: string): Promise<string>;
14
- loadDirectory(pathOrUrl: string): Promise<ResourceManifest[]>;
15
- loadManifest(pathOrUrl: string, baseUrl: string, compileContext?: Record<string, unknown>): Promise<ResourceManifest[]>;
16
- private orderResourcesByKindDependencies;
17
- }
18
- //# sourceMappingURL=loader.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"loader.d.ts","sourceRoot":"","sources":["../src/loader.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,IAAI,UAAU,EAAE,MAAM,mBAAmB,CAAC;AACzD,OAAO,EAAE,gBAAgB,EAAmB,MAAM,cAAc,CAAC;AAKjE,qBAAa,MAAO,SAAQ,UAAU;IACpC,OAAO,CAAC,MAAM,CAAC,WAAW,CAAuB;IACjD,OAAO,CAAC,QAAQ,CAAC,YAAY,CAAmB;;IAQhD,OAAO,CAAC,MAAM,CAAC,iBAAiB;IAMhC,WAAW,CAAC,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,GAAG,MAAM;IAInD;;;OAGG;IACG,iBAAiB,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IAKrD,aAAa,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,gBAAgB,EAAE,CAAC;IAyB7D,YAAY,CAChB,SAAS,EAAE,MAAM,EACjB,OAAO,EAAE,MAAM,EACf,cAAc,GAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAM,GAC3C,OAAO,CAAC,gBAAgB,EAAE,CAAC;IAW9B,OAAO,CAAC,gCAAgC;CA0DzC"}