@reventlessdev/reventless-infra 3.0.0-alpha.103 → 3.0.0-alpha.105

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/CHANGELOG.md CHANGED
@@ -3,6 +3,35 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # 3.0.0-alpha.105 (2026-07-26)
7
+
8
+ ### Bug Fixes
9
+
10
+ * **graphql:** give InboundTranslationSlice mutations a resolvable result type ([381b545](https://github.com/ReventlessDev/reventless-core/commit/381b5458c16797404cb8ed95fa853fb1e1ca4199))
11
+ ### Features
12
+
13
+ * **auto-ui:** declare command target state via [@target](https://github.com/target)State ([5fc0374](https://github.com/ReventlessDev/reventless-core/commit/5fc03741a8816c57085b86a4ad7d595e3b690193)), closes [#5](https://github.com/ReventlessDev/reventless-core/issues/5)
14
+ * **auto-ui:** write ui-hints.json from the host-ui AWS deploy ([cbb334c](https://github.com/ReventlessDev/reventless-core/commit/cbb334c5bc574d7be56746100bae93457a8831ce)), closes [#1](https://github.com/ReventlessDev/reventless-core/issues/1)
15
+ * **aws:** geocoder + upload presign Lambda Function URL services ([be43179](https://github.com/ReventlessDev/reventless-core/commit/be4317972e781dbe3c378f21a28975d1ac8b9add))
16
+ * **platform:** serve a private bucket to the UI under a same-origin prefix ([793c8b2](https://github.com/ReventlessDev/reventless-core/commit/793c8b25e13969b42ce331c698bad473be4c0c88))
17
+
18
+
19
+ # 3.0.0-alpha.104 (2026-07-22)
20
+
21
+ * refactor!: retire the stale "core" vocabulary for platform things ([34e7480](https://github.com/ReventlessDev/reventless-core/commit/34e7480992bd58906a250b0a1ce6ff2c5ba45260))
22
+
23
+ ### BREAKING CHANGES
24
+
25
+ * the built-in extension point is renamed Core.Plugin ->
26
+ Platform.Plugin. This replaces the CorePluginExtPointCmdTopic SQS queue
27
+ with PlatformPluginExtPointCmdTopic (a replacement, not an update) and
28
+ breaks every already-deployed plugin's connection until redeployed.
29
+ Wipe the alpha stack and redeploy fresh rather than migrating.
30
+
31
+ Build clean; 1349 tests green (interop 50, core 518, local 501, aws 280).
32
+
33
+
34
+
6
35
  # 3.0.0-alpha.103 (2026-07-22)
7
36
 
8
37
  **Note:** Version bump only for package @reventlessdev/reventless-infra
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@reventlessdev/reventless-infra",
3
- "version": "3.0.0-alpha.103",
3
+ "version": "3.0.0-alpha.105",
4
4
  "description": "Infrastructure types for Reventless framework",
5
5
  "license": "Apache-2.0",
6
6
  "jest": {
@@ -16,10 +16,10 @@
16
16
  "sury": "11.0.0-alpha.4",
17
17
  "sury-ppx": "11.0.0-alpha.2",
18
18
  "uuid": "^13.0.0",
19
- "@reventlessdev/rescript-effect": "0.1.0-alpha.30",
19
+ "@reventlessdev/rescript-uuid": "1.1.0-alpha.17",
20
+ "@reventlessdev/rescript-effect": "0.1.0-alpha.31",
20
21
  "@reventlessdev/rescript-pulumi-pulumi": "2.3.0-alpha.17",
21
- "@reventlessdev/reventless-spec": "3.0.0-alpha.80",
22
- "@reventlessdev/rescript-uuid": "1.1.0-alpha.17"
22
+ "@reventlessdev/reventless-spec": "3.0.0-alpha.81"
23
23
  },
24
24
  "devDependencies": {
25
25
  "rescript": "12.3.0",
@@ -12,6 +12,11 @@ let noApiVariantsId: S.Metadata.Id.t<Set.t<string>> =
12
12
  let allowedStatesId: S.Metadata.Id.t<dict<array<string>>> =
13
13
  S.Metadata.Id.make(~namespace="api", ~name="allowedStates")
14
14
 
15
+ /** Internal sury metadata ID storing per-variant target-state values for AutoUI board
16
+ transitions. Maps variant name → the single status the command's handler writes. */
17
+ let targetStateId: S.Metadata.Id.t<dict<string>> =
18
+ S.Metadata.Id.make(~namespace="api", ~name="targetState")
19
+
15
20
  /** PPX helper: attaches the noApi flag to a command schema. Called by generated code. */
16
21
  let markNoApi = (schema: S.t<'a>): S.t<'a> =>
17
22
  schema->S.Metadata.set(~id=noApiId, true)
@@ -27,6 +32,13 @@ let markAllowedStates = (
27
32
  entries: array<(string, array<string>)>,
28
33
  ): S.t<'a> => schema->S.Metadata.set(~id=allowedStatesId, Dict.fromArray(entries))
29
34
 
35
+ /** PPX helper: attaches per-variant targetState to a command schema. Called by generated code
36
+ emitted from the @targetState("…") attribute. Each entry is (variantName, targetStateName). */
37
+ let markTargetState = (
38
+ schema: S.t<'a>,
39
+ entries: array<(string, string)>,
40
+ ): S.t<'a> => schema->S.Metadata.set(~id=targetStateId, Dict.fromArray(entries))
41
+
30
42
  /** Type alias for schema fragments (re-exports Plugin.apiSchemaFragment). */
31
43
  type schemaFragment = Reventless.Plugin.apiSchemaFragment
32
44
 
@@ -8,6 +8,8 @@ let noApiVariantsId = S.Metadata.Id.make("api", "noApiVariants");
8
8
 
9
9
  let allowedStatesId = S.Metadata.Id.make("api", "allowedStates");
10
10
 
11
+ let targetStateId = S.Metadata.Id.make("api", "targetState");
12
+
11
13
  function markNoApi(schema) {
12
14
  return S.Metadata.set(schema, noApiId, true);
13
15
  }
@@ -20,12 +22,18 @@ function markAllowedStates(schema, entries) {
20
22
  return S.Metadata.set(schema, allowedStatesId, Object.fromEntries(entries));
21
23
  }
22
24
 
25
+ function markTargetState(schema, entries) {
26
+ return S.Metadata.set(schema, targetStateId, Object.fromEntries(entries));
27
+ }
28
+
23
29
  export {
24
30
  noApiId,
25
31
  noApiVariantsId,
26
32
  allowedStatesId,
33
+ targetStateId,
27
34
  markNoApi,
28
35
  markNoApiVariants,
29
36
  markAllowedStates,
37
+ markTargetState,
30
38
  }
31
39
  /* noApiId Not a pure module */
@@ -9,13 +9,46 @@ type outputs = {
9
9
  queryDb: QueryDb.outputs,
10
10
  }
11
11
 
12
+ /**
13
+ A translation that ran to completion.
14
+
15
+ - `requestId` -- the key the audit row is stored under
16
+ - `targetIds` -- the entities the produced commands address; empty when the
17
+ translation legitimately produced no command
18
+ - `commandCount` -- how many commands were published
19
+ */
20
+ type acceptedResult = {
21
+ requestId: string,
22
+ targetIds: array<string>,
23
+ commandCount: int,
24
+ }
25
+
26
+ /**
27
+ A translation that was rejected -- by input parsing, by `translate`, by command
28
+ encoding or by the publish itself.
29
+
30
+ - `requestId` -- the key the audit row is stored under
31
+ - `error` -- the rejection message
32
+ */
33
+ type rejectedResult = {
34
+ requestId: string,
35
+ error: string,
36
+ }
37
+
38
+ /**
39
+ Outcome of `receive`. Both arms carry `requestId` so a caller can correlate the
40
+ response with the slice's audit row, and so the GraphQL resolver can report a
41
+ `msgId` on either arm.
42
+ */
43
+ type receiveResult = result<acceptedResult, rejectedResult>
44
+
12
45
  /**
13
46
  Runtime operations exposed by an `InboundTranslationSlice` component.
14
47
 
15
48
  - `receive` -- accept external input, translate it, and publish a command
16
49
  */
17
50
  type operations = {
18
- receive: JSON.t => promise<result<array<string>, string>>,
51
+ receive: JSON.t => promise<receiveResult>,
19
52
  }
20
53
 
21
54
  /**
@@ -49,6 +49,20 @@ module App = CatalogPlugin.Make(Platform)
49
49
  // where `module Plugin: Plugin.T` shadows the package-level Plugin module.
50
50
  type pluginOutputs = Plugin.outputs
51
51
 
52
+ // A storage bucket a deployment declares to be served read-only to the UI under
53
+ // a path prefix on the UI's own public origin, while the bucket stays private
54
+ // (CDN-only read). These four fields are the minimal handle any CDN front needs;
55
+ // the app owns the bucket's lifecycle and creation. Defined at file scope so it
56
+ // is a single shared nominal type across the concrete Platform implementations
57
+ // (AWS fronts it via CloudFront; in-memory ignores it). See
58
+ // [docs/plans/done/ui-served-buckets.md].
59
+ type servedBucket = {
60
+ prefix: string,
61
+ bucketId: Pulumi.Input.t<string>,
62
+ bucketArn: Pulumi.Input.t<string>,
63
+ bucketRegionalDomainName: Pulumi.Input.t<string>,
64
+ }
65
+
52
66
  // Module type alias so StateViewSliceStream can reference the component T
53
67
  // without being confused by the `module StateViewSlice` declaration inside T.
54
68
  module type StateViewSliceComponentT = StateViewSlice.T
@@ -235,6 +249,27 @@ module type T = {
235
249
  type hostUiBundleConfig = {
236
250
  assetsDir: string,
237
251
  bundleVersion: string,
252
+ // Optional path to a static AutoUI `ui-hints.json`, read and written
253
+ // verbatim as a BucketObject beside `config.json` at deploy time. Unset ⇒
254
+ // no file written; the shell treats the 404 as "no hints" and boots
255
+ // unchanged. In-memory platforms ignore this.
256
+ uiHintsFile?: string,
257
+ // Optional AWS Location place-index name. When set, the deploy provisions a
258
+ // public geocoder Lambda Function URL and threads its URL into config.json
259
+ // as `geocoderEndpoint`. Unset ⇒ no service, field omitted. In-memory
260
+ // platforms ignore this.
261
+ geocoderPlaceIndex?: Pulumi.Input.t<string>,
262
+ // Opt into the direct-to-S3 upload presign service. Requires
263
+ // `uploadBucketName`; the deploy then provisions a public presign Lambda
264
+ // Function URL and threads its URL into config.json as `uploadEndpoint`.
265
+ enableUploads?: bool,
266
+ // S3 bucket the upload presign service issues PUT URLs against. Required
267
+ // when `enableUploads` is true.
268
+ uploadBucketName?: Pulumi.Input.t<string>,
269
+ // Buckets served read-only to the UI under a path prefix on the UI's own
270
+ // origin (same-origin, private, CDN-fronted). Each entry adds a `{prefix}/*`
271
+ // read path on the host-shell distribution. In-memory platforms ignore this.
272
+ servedBuckets?: array<servedBucket>,
238
273
  }
239
274
 
240
275
  /** Deploy a complete platform: creates the scheduler, builds each plugin,
@@ -1,4 +1,4 @@
1
- let name = "Core.Plugin"
1
+ let name = "Platform.Plugin"
2
2
 
3
3
  include Reventless.Plugin
4
4
 
@@ -91,7 +91,7 @@ let directiveSchema = S.union([
91
91
 
92
92
  let moduleUrl = import.meta.url;
93
93
 
94
- let name = "Core.Plugin";
94
+ let name = "Platform.Plugin";
95
95
 
96
96
  let nameSchema = Plugin$Reventless.nameSchema;
97
97