@reventlessdev/online-shop-hybrid-ordering 1.0.0-alpha.238 → 1.0.0-alpha.239

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,20 @@
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
+ # 1.0.0-alpha.239 (2026-09-16)
7
+
8
+ * feat(spec)!: infer the DCB partition key per slice, and drop @partitionTag where inference agrees ([6c10161](https://github.com/ReventlessDev/reventless-core/commit/6c101611d438beea4bc9175ae8ea0ea1f6f7493b))
9
+ ### Features
10
+
11
+ * **spec:** let a slice's chapter break a partition-key tie ([2b9ae77](https://github.com/ReventlessDev/reventless-core/commit/2b9ae77e98eb42177d2bdd4977bc62bb7c7911aa))
12
+
13
+ ### BREAKING CHANGES
14
+
15
+ * DcbTag.derivePartitionTag is removed; a boundary whose
16
+ partition cannot be inferred no longer deploys.
17
+
18
+
19
+
6
20
  # 1.0.0-alpha.238 (2026-09-11)
7
21
 
8
22
  ### Bug Fixes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@reventlessdev/online-shop-hybrid-ordering",
3
- "version": "1.0.0-alpha.238",
3
+ "version": "1.0.0-alpha.239",
4
4
  "description": "Online Shop Hybrid example — Ordering plugin (Customer aggregate + Order/CatalogProduct DCB)",
5
5
  "license": "Apache-2.0",
6
6
  "jest": {
@@ -21,15 +21,15 @@
21
21
  },
22
22
  "dependencies": {
23
23
  "sury": "11.0.0-rc.2",
24
- "@reventlessdev/online-shop-hybrid-catalog-spec": "1.0.0-alpha.131",
25
- "@reventlessdev/rescript-pulumi-pulumi": "2.3.0-alpha.20",
26
- "@reventlessdev/reventless-gwt": "1.0.0-alpha.209",
27
- "@reventlessdev/reventless-infra": "3.0.0-alpha.163",
28
- "@reventlessdev/online-shop-hybrid-ordering-spec": "1.0.0-alpha.131",
29
- "@reventlessdev/reventless-local": "3.0.0-alpha.251",
30
- "@reventlessdev/reventless-spec": "3.0.0-alpha.135",
31
- "@reventlessdev/trait-address-geocoding": "1.0.0-alpha.11",
32
- "@reventlessdev/trait-notification": "1.0.0-alpha.11"
24
+ "@reventlessdev/online-shop-hybrid-ordering-spec": "1.0.0-alpha.132",
25
+ "@reventlessdev/rescript-pulumi-pulumi": "2.3.0-alpha.21",
26
+ "@reventlessdev/reventless-infra": "3.0.0-alpha.164",
27
+ "@reventlessdev/reventless-gwt": "1.0.0-alpha.210",
28
+ "@reventlessdev/online-shop-hybrid-catalog-spec": "1.0.0-alpha.132",
29
+ "@reventlessdev/reventless-local": "3.0.0-alpha.252",
30
+ "@reventlessdev/reventless-spec": "3.0.0-alpha.136",
31
+ "@reventlessdev/trait-notification": "1.0.0-alpha.12",
32
+ "@reventlessdev/trait-address-geocoding": "1.0.0-alpha.12"
33
33
  },
34
34
  "devDependencies": {
35
35
  "rescript": "12.3.0",
@@ -55,7 +55,7 @@ type lineItem = {
55
55
  @schema
56
56
  type command =
57
57
  | PlaceOrder({
58
- @partitionTag orderId: string,
58
+ orderId: string,
59
59
  // customerId is payload, not a query key — @noDcbTag stops it auto-tagging.
60
60
  // It is also the order's owner: the resolver overwrites this with the
61
61
  // authenticated caller's id before the command is published, so what a
@@ -103,7 +103,7 @@ type orderLine = {
103
103
  @schema
104
104
  type event =
105
105
  | OrderPlaced({
106
- @partitionTag orderId: string,
106
+ orderId: string,
107
107
  customerId: string,
108
108
  // Redundant against `lines`, and deliberately so. The extension point
109
109
  // decomposes this into one published `ItemOrdered` per product and
@@ -55,7 +55,7 @@ let lineItemSchema = Sury.$schema(s => ({
55
55
 
56
56
  let commandSchema = Sury.$schema(s => ({
57
57
  TAG: "PlaceOrder",
58
- orderId: s.m(DcbTag$Reventless.partition),
58
+ orderId: s.m(DcbTag$Reventless.string),
59
59
  customerId: s.m(Owner$Reventless.string),
60
60
  lineItems: s.m(Sury.array(lineItemSchema)),
61
61
  shippingMethod: s.m(shippingMethodSchema),
@@ -90,7 +90,7 @@ let orderLineSchema = Sury.$schema(s => ({
90
90
 
91
91
  let eventSchema = Sury.$schema(s => ({
92
92
  TAG: "OrderPlaced",
93
- orderId: s.m(DcbTag$Reventless.partition),
93
+ orderId: s.m(DcbTag$Reventless.string),
94
94
  customerId: s.m(DcbTag$Reventless.string),
95
95
  productIds: s.m(Sury.array(DcbTag$Reventless.stringForKey("productId"))),
96
96
  lines: s.m(Sury.array(orderLineSchema)),
@@ -37,7 +37,7 @@ type error =
37
37
  | OrderAlreadyCancelled
38
38
 
39
39
  @schema
40
- type event = OrderShipped({@partitionTag orderId: string, customerId: string})
40
+ type event = OrderShipped({orderId: string, customerId: string})
41
41
 
42
42
  type lifecycleState = Orders.lifecycle
43
43
 
@@ -26,7 +26,7 @@ let errorSchema = Sury.union([
26
26
 
27
27
  let eventSchema = Sury.$schema(s => ({
28
28
  TAG: "OrderShipped",
29
- orderId: s.m(DcbTag$Reventless.partition),
29
+ orderId: s.m(DcbTag$Reventless.string),
30
30
  customerId: s.m(DcbTag$Reventless.string)
31
31
  }));
32
32
 
package/src/Plugin.res CHANGED
@@ -8,42 +8,49 @@ let dcbSliceSchemas: array<Reventless.DcbTag.sliceSchemas> = [
8
8
  commandSchema: CancelOrder.commandSchema->S.castToUnknown,
9
9
  consumedEventSchema: CancelOrder.consumedEventSchema->S.castToUnknown,
10
10
  eventSchema: CancelOrder.eventSchema->S.castToUnknown,
11
+ moduleUrl: CancelOrder.moduleUrl,
11
12
  },
12
13
  {
13
14
  name: EmailVerificationChallenges.name,
14
15
  commandSchema: EmailVerificationChallenges.commandSchema->S.castToUnknown,
15
16
  consumedEventSchema: EmailVerificationChallenges.consumedEventSchema->S.castToUnknown,
16
17
  eventSchema: EmailVerificationChallenges.eventSchema->S.castToUnknown,
18
+ moduleUrl: EmailVerificationChallenges.moduleUrl,
17
19
  },
18
20
  {
19
21
  name: NotificationPreferences.name,
20
22
  commandSchema: NotificationPreferences.commandSchema->S.castToUnknown,
21
23
  consumedEventSchema: NotificationPreferences.consumedEventSchema->S.castToUnknown,
22
24
  eventSchema: NotificationPreferences.eventSchema->S.castToUnknown,
25
+ moduleUrl: NotificationPreferences.moduleUrl,
23
26
  },
24
27
  {
25
28
  name: NotificationSourceClaims.name,
26
29
  commandSchema: NotificationSourceClaims.commandSchema->S.castToUnknown,
27
30
  consumedEventSchema: NotificationSourceClaims.consumedEventSchema->S.castToUnknown,
28
31
  eventSchema: NotificationSourceClaims.eventSchema->S.castToUnknown,
32
+ moduleUrl: NotificationSourceClaims.moduleUrl,
29
33
  },
30
34
  {
31
35
  name: PlaceOrder.name,
32
36
  commandSchema: PlaceOrder.commandSchema->S.castToUnknown,
33
37
  consumedEventSchema: PlaceOrder.consumedEventSchema->S.castToUnknown,
34
38
  eventSchema: PlaceOrder.eventSchema->S.castToUnknown,
39
+ moduleUrl: PlaceOrder.moduleUrl,
35
40
  },
36
41
  {
37
42
  name: ShipOrder.name,
38
43
  commandSchema: ShipOrder.commandSchema->S.castToUnknown,
39
44
  consumedEventSchema: ShipOrder.consumedEventSchema->S.castToUnknown,
40
45
  eventSchema: ShipOrder.eventSchema->S.castToUnknown,
46
+ moduleUrl: ShipOrder.moduleUrl,
41
47
  },
42
48
  {
43
49
  name: SyncCatalogProduct.name,
44
50
  commandSchema: SyncCatalogProduct.commandSchema->S.castToUnknown,
45
51
  consumedEventSchema: SyncCatalogProduct.consumedEventSchema->S.castToUnknown,
46
52
  eventSchema: SyncCatalogProduct.eventSchema->S.castToUnknown,
53
+ moduleUrl: SyncCatalogProduct.moduleUrl,
47
54
  },
48
55
  ]
49
56
 
@@ -52,43 +52,50 @@ let dcbSliceSchemas = [
52
52
  name: CancelOrder$OrderingPlugin.name,
53
53
  commandSchema: CancelOrder$OrderingPlugin.commandSchema,
54
54
  consumedEventSchema: CancelOrder$OrderingPlugin.consumedEventSchema,
55
- eventSchema: CancelOrder$OrderingPlugin.eventSchema
55
+ eventSchema: CancelOrder$OrderingPlugin.eventSchema,
56
+ moduleUrl: CancelOrder$OrderingPlugin.moduleUrl
56
57
  },
57
58
  {
58
59
  name: EmailVerificationChallenges$OrderingPlugin.name,
59
60
  commandSchema: EmailVerificationChallenges$OrderingPlugin.commandSchema,
60
61
  consumedEventSchema: EmailVerificationChallenges$OrderingPlugin.consumedEventSchema,
61
- eventSchema: EmailVerificationChallenges$OrderingPlugin.eventSchema
62
+ eventSchema: EmailVerificationChallenges$OrderingPlugin.eventSchema,
63
+ moduleUrl: EmailVerificationChallenges$OrderingPlugin.moduleUrl
62
64
  },
63
65
  {
64
66
  name: NotificationPreferences$OrderingPlugin.name,
65
67
  commandSchema: NotificationPreferences$OrderingPlugin.commandSchema,
66
68
  consumedEventSchema: NotificationPreferences$OrderingPlugin.consumedEventSchema,
67
- eventSchema: NotificationPreferences$OrderingPlugin.eventSchema
69
+ eventSchema: NotificationPreferences$OrderingPlugin.eventSchema,
70
+ moduleUrl: NotificationPreferences$OrderingPlugin.moduleUrl
68
71
  },
69
72
  {
70
73
  name: NotificationSourceClaims$OrderingPlugin.name,
71
74
  commandSchema: NotificationSourceClaims$OrderingPlugin.commandSchema,
72
75
  consumedEventSchema: NotificationSourceClaims$OrderingPlugin.consumedEventSchema,
73
- eventSchema: NotificationSourceClaims$OrderingPlugin.eventSchema
76
+ eventSchema: NotificationSourceClaims$OrderingPlugin.eventSchema,
77
+ moduleUrl: NotificationSourceClaims$OrderingPlugin.moduleUrl
74
78
  },
75
79
  {
76
80
  name: PlaceOrder$OrderingPlugin.name,
77
81
  commandSchema: PlaceOrder$OrderingPlugin.commandSchema,
78
82
  consumedEventSchema: PlaceOrder$OrderingPlugin.consumedEventSchema,
79
- eventSchema: PlaceOrder$OrderingPlugin.eventSchema
83
+ eventSchema: PlaceOrder$OrderingPlugin.eventSchema,
84
+ moduleUrl: PlaceOrder$OrderingPlugin.moduleUrl
80
85
  },
81
86
  {
82
87
  name: ShipOrder$OrderingPlugin.name,
83
88
  commandSchema: ShipOrder$OrderingPlugin.commandSchema,
84
89
  consumedEventSchema: ShipOrder$OrderingPlugin.consumedEventSchema,
85
- eventSchema: ShipOrder$OrderingPlugin.eventSchema
90
+ eventSchema: ShipOrder$OrderingPlugin.eventSchema,
91
+ moduleUrl: ShipOrder$OrderingPlugin.moduleUrl
86
92
  },
87
93
  {
88
94
  name: SyncCatalogProduct$OrderingPlugin.name,
89
95
  commandSchema: SyncCatalogProduct$OrderingPlugin.commandSchema,
90
96
  consumedEventSchema: SyncCatalogProduct$OrderingPlugin.consumedEventSchema,
91
- eventSchema: SyncCatalogProduct$OrderingPlugin.eventSchema
97
+ eventSchema: SyncCatalogProduct$OrderingPlugin.eventSchema,
98
+ moduleUrl: SyncCatalogProduct$OrderingPlugin.moduleUrl
92
99
  }
93
100
  ];
94
101