@reventlessdev/reventless-aws 3.0.0-alpha.381 → 3.0.0-alpha.382
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 +7 -0
- package/package.json +6 -6
- package/src/adapter/AWS_Tags.res +8 -0
- package/src/adapter/AWS_Tags.res.mjs +5 -0
- package/src/adapter/ScheduledPublisher/ScheduledPublisher_EventBridgeScheduler.res +9 -1
- package/src/adapter/ScheduledPublisher/ScheduledPublisher_EventBridgeScheduler.res.mjs +1 -1
- package/tests/ScheduledPublisher_EventBridgeSchedulerTest.res +5 -0
- package/tests/ScheduledPublisher_EventBridgeSchedulerTest.res.mjs +17 -0
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,13 @@
|
|
|
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.382 (2026-10-16)
|
|
7
|
+
|
|
8
|
+
### Bug Fixes
|
|
9
|
+
|
|
10
|
+
* **aws:** a schedule group carries no empty tag value ([f7c5074](https://github.com/ReventlessDev/reventless-core/commit/f7c507474ee5a31555e2af7fb8c87d58fb75ed54))
|
|
11
|
+
|
|
12
|
+
|
|
6
13
|
# 3.0.0-alpha.381 (2026-10-15)
|
|
7
14
|
|
|
8
15
|
* feat!: schedules take a Schedule.time, run on EventBridge Scheduler on AWS ([2d74557](https://github.com/ReventlessDev/reventless-core/commit/2d74557a6304917ded8f2b9f4107af9298c91ac0))
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@reventlessdev/reventless-aws",
|
|
3
|
-
"version": "3.0.0-alpha.
|
|
3
|
+
"version": "3.0.0-alpha.382",
|
|
4
4
|
"description": "AWS adapters for Reventless",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"bin": {
|
|
@@ -23,18 +23,18 @@
|
|
|
23
23
|
"uuid": "^13.0.0",
|
|
24
24
|
"yaml": "^2.8.3",
|
|
25
25
|
"@reventlessdev/rescript-aws-sdk": "3.0.0-alpha.31",
|
|
26
|
-
"@reventlessdev/rescript-effect": "1.0.0-alpha.0",
|
|
27
|
-
"@reventlessdev/rescript-node": "2.0.0-alpha.22",
|
|
28
26
|
"@reventlessdev/rescript-jest": "1.0.0-alpha.12",
|
|
29
27
|
"@reventlessdev/rescript-pulumi-aws": "3.0.0-alpha.28",
|
|
28
|
+
"@reventlessdev/rescript-node": "2.0.0-alpha.22",
|
|
29
|
+
"@reventlessdev/rescript-effect": "1.0.0-alpha.0",
|
|
30
30
|
"@reventlessdev/rescript-pulumi-pulumi": "2.3.0-alpha.23",
|
|
31
|
-
"@reventlessdev/rescript-uuid": "2.0.0-alpha.1",
|
|
32
|
-
"@reventlessdev/reventless-interop": "3.0.0-alpha.40",
|
|
33
31
|
"@reventlessdev/rescript-web": "1.0.0-alpha.7",
|
|
32
|
+
"@reventlessdev/reventless-core": "3.0.0-alpha.295",
|
|
33
|
+
"@reventlessdev/rescript-uuid": "2.0.0-alpha.1",
|
|
34
34
|
"@reventlessdev/reventless-infra": "3.0.0-alpha.192",
|
|
35
35
|
"@reventlessdev/reventless-postgres": "3.0.0-alpha.159",
|
|
36
36
|
"@reventlessdev/reventless-spec": "3.0.0-alpha.164",
|
|
37
|
-
"@reventlessdev/reventless-
|
|
37
|
+
"@reventlessdev/reventless-interop": "3.0.0-alpha.40"
|
|
38
38
|
},
|
|
39
39
|
"devDependencies": {
|
|
40
40
|
"rescript": "12.3.1",
|
package/src/adapter/AWS_Tags.res
CHANGED
|
@@ -103,6 +103,14 @@ let makeDict = (
|
|
|
103
103
|
]->Dict.fromArray
|
|
104
104
|
}
|
|
105
105
|
|
|
106
|
+
/**
|
|
107
|
+
`tags` without the empty values, for the resource types that refuse a tag whose
|
|
108
|
+
value is empty: an EventBridge Scheduler schedule group fails to create with one
|
|
109
|
+
(`reventless:plugin` and `reventless:component` are empty at platform scope).
|
|
110
|
+
*/
|
|
111
|
+
let withoutEmpty = (tags: dict<string>) =>
|
|
112
|
+
tags->Dict.toArray->Array.filter(((_, value)) => value != "")->Dict.fromArray
|
|
113
|
+
|
|
106
114
|
/***
|
|
107
115
|
Framework-created AWS resource types that carry NO attribution tags, and why.
|
|
108
116
|
Keep this list here rather than in a plan: it is what tells a coverage audit
|
|
@@ -74,6 +74,10 @@ function makeDict(name, kind, role, scopeOpt, component, owner, plugin, platform
|
|
|
74
74
|
]);
|
|
75
75
|
}
|
|
76
76
|
|
|
77
|
+
function withoutEmpty(tags) {
|
|
78
|
+
return Object.fromEntries(Object.entries(tags).filter(param => param[1] !== ""));
|
|
79
|
+
}
|
|
80
|
+
|
|
77
81
|
function make(name, kind, role, scopeOpt, component, owner, plugin, platform) {
|
|
78
82
|
let scope = scopeOpt !== undefined ? scopeOpt : "Component";
|
|
79
83
|
return makeDict(name, kind, role, scope, component, owner, plugin, platform);
|
|
@@ -84,6 +88,7 @@ let Attribution;
|
|
|
84
88
|
export {
|
|
85
89
|
Attribution,
|
|
86
90
|
makeDict,
|
|
91
|
+
withoutEmpty,
|
|
87
92
|
make,
|
|
88
93
|
}
|
|
89
94
|
/* @pulumi/pulumi Not a pure module */
|
|
@@ -42,7 +42,15 @@ let make: ReventlessCore.Scheduler_Adapter.scheduledPublisherMaker = (~name, ~op
|
|
|
42
42
|
~name=name ++ "ScheduleGroup",
|
|
43
43
|
~args={
|
|
44
44
|
name: role.name->Pulumi.Output.asInput,
|
|
45
|
-
|
|
45
|
+
// A schedule group refuses the empty values platform-scoped tags carry.
|
|
46
|
+
tags: AWS.Tags.makeDict(
|
|
47
|
+
~name=name ++ "ScheduleGroup",
|
|
48
|
+
~kind=ReventlessCore.ComponentType.Platform,
|
|
49
|
+
~role=Identity,
|
|
50
|
+
~scope=Platform,
|
|
51
|
+
)
|
|
52
|
+
->AWS.Tags.withoutEmpty
|
|
53
|
+
->Pulumi.Input.make,
|
|
46
54
|
},
|
|
47
55
|
~opts,
|
|
48
56
|
)
|
|
@@ -23,7 +23,7 @@ function make(name, opts) {
|
|
|
23
23
|
}, opts);
|
|
24
24
|
new (Aws.scheduler.ScheduleGroup)(name + "ScheduleGroup", {
|
|
25
25
|
name: role.name,
|
|
26
|
-
tags:
|
|
26
|
+
tags: AWS_Tags$ReventlessAws.withoutEmpty(AWS_Tags$ReventlessAws.makeDict(name + "ScheduleGroup", "Platform", "Identity", "Platform", undefined, undefined, undefined, undefined))
|
|
27
27
|
}, opts);
|
|
28
28
|
return {
|
|
29
29
|
resource: Adapter$ReventlessInfra.make(role.name, role.id, role.arn, Pulumi.output("EventBridgeScheduler"), undefined, undefined, undefined, Pulumi.output("aws:scheduler:ScheduleGroup"), undefined, undefined),
|
|
@@ -57,4 +57,9 @@ describe("ScheduledPublisher_EventBridgeScheduler_Runtime", () => {
|
|
|
57
57
|
"arn:aws:scheduler:*:123456789012:schedule/SchedulerRole-*/*",
|
|
58
58
|
)
|
|
59
59
|
})
|
|
60
|
+
|
|
61
|
+
testSync("a schedule group's tags carry no empty value, which AWS refuses", () => {
|
|
62
|
+
let tags = Dict.fromArray([("Name", "SchedulerScheduleGroup"), ("reventless:plugin", "")])
|
|
63
|
+
expect(tags->AWS.Tags.withoutEmpty->Dict.toArray)->toEqual([("Name", "SchedulerScheduleGroup")])
|
|
64
|
+
})
|
|
60
65
|
})
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
// Generated by ReScript, PLEASE EDIT WITH CARE
|
|
2
2
|
|
|
3
3
|
import * as Stdlib_Option from "@rescript/runtime/lib/es6/Stdlib_Option.js";
|
|
4
|
+
import * as AWS_Tags$ReventlessAws from "../src/adapter/AWS_Tags.res.mjs";
|
|
4
5
|
import * as ScheduledPublisher_EventBridgeScheduler_Runtime$ReventlessAws from "../src/adapter/ScheduledPublisher/ScheduledPublisher_EventBridgeScheduler_Runtime.res.mjs";
|
|
5
6
|
|
|
6
7
|
let roleArn = "arn:aws:iam::123456789012:role/SchedulerRole-1a2b3c4";
|
|
@@ -83,6 +84,22 @@ globalThis.describe("ScheduledPublisher_EventBridgeScheduler_Runtime", () => {
|
|
|
83
84
|
globalThis.expect(ScheduledPublisher_EventBridgeScheduler_Runtime$ReventlessAws.schedulesOfRoleArn(roleArn)).toBe("arn:aws:scheduler:*:123456789012:schedule/SchedulerRole-1a2b3c4/*");
|
|
84
85
|
globalThis.expect(ScheduledPublisher_EventBridgeScheduler_Runtime$ReventlessAws.schedulesOfAccount("123456789012")).toBe("arn:aws:scheduler:*:123456789012:schedule/SchedulerRole-*/*");
|
|
85
86
|
});
|
|
87
|
+
globalThis.test("a schedule group's tags carry no empty value, which AWS refuses", () => {
|
|
88
|
+
let tags = Object.fromEntries([
|
|
89
|
+
[
|
|
90
|
+
"Name",
|
|
91
|
+
"SchedulerScheduleGroup"
|
|
92
|
+
],
|
|
93
|
+
[
|
|
94
|
+
"reventless:plugin",
|
|
95
|
+
""
|
|
96
|
+
]
|
|
97
|
+
]);
|
|
98
|
+
globalThis.expect(Object.entries(AWS_Tags$ReventlessAws.withoutEmpty(tags))).toEqual([[
|
|
99
|
+
"Name",
|
|
100
|
+
"SchedulerScheduleGroup"
|
|
101
|
+
]]);
|
|
102
|
+
});
|
|
86
103
|
});
|
|
87
104
|
|
|
88
105
|
let Runtime;
|