@adobe/spacecat-shared-data-access 2.20.0 → 2.21.0
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
|
@@ -1,3 +1,17 @@
|
|
|
1
|
+
# [@adobe/spacecat-shared-data-access-v2.21.0](https://github.com/adobe/spacecat-shared/compare/@adobe/spacecat-shared-data-access-v2.20.1...@adobe/spacecat-shared-data-access-v2.21.0) (2025-05-26)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Features
|
|
5
|
+
|
|
6
|
+
* add updatedBy attribute to entities and ims api to resolve profile ([#758](https://github.com/adobe/spacecat-shared/issues/758)) ([47f73ff](https://github.com/adobe/spacecat-shared/commit/47f73ff18609f0b97576c391caad7409f0d24349))
|
|
7
|
+
|
|
8
|
+
# [@adobe/spacecat-shared-data-access-v2.20.1](https://github.com/adobe/spacecat-shared/compare/@adobe/spacecat-shared-data-access-v2.20.0...@adobe/spacecat-shared-data-access-v2.20.1) (2025-05-24)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Bug Fixes
|
|
12
|
+
|
|
13
|
+
* **deps:** update external fixes ([#762](https://github.com/adobe/spacecat-shared/issues/762)) ([2eb5a22](https://github.com/adobe/spacecat-shared/commit/2eb5a22935a7293ef293157e0b0fe6506d5b4c94))
|
|
14
|
+
|
|
1
15
|
# [@adobe/spacecat-shared-data-access-v2.20.0](https://github.com/adobe/spacecat-shared/compare/@adobe/spacecat-shared-data-access-v2.19.4...@adobe/spacecat-shared-data-access-v2.20.0) (2025-05-23)
|
|
2
16
|
|
|
3
17
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@adobe/spacecat-shared-data-access",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.21.0",
|
|
4
4
|
"description": "Shared modules of the Spacecat Services - Data Access",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"engines": {
|
|
@@ -13,6 +13,7 @@
|
|
|
13
13
|
"test:it": "mocha --require ./test/it/fixtures.js --spec \"test/it/**/*.test.js\"",
|
|
14
14
|
"test": "c8 mocha --spec \"test/unit/**/*.test.js\"",
|
|
15
15
|
"lint": "eslint .",
|
|
16
|
+
"lint:fix": "eslint --fix .",
|
|
16
17
|
"clean": "rm -rf package-lock.json node_modules"
|
|
17
18
|
},
|
|
18
19
|
"mocha": {
|
|
@@ -35,8 +36,8 @@
|
|
|
35
36
|
},
|
|
36
37
|
"dependencies": {
|
|
37
38
|
"@adobe/spacecat-shared-utils": "1.38.0",
|
|
38
|
-
"@aws-sdk/client-dynamodb": "3.
|
|
39
|
-
"@aws-sdk/lib-dynamodb": "3.
|
|
39
|
+
"@aws-sdk/client-dynamodb": "3.817.0",
|
|
40
|
+
"@aws-sdk/lib-dynamodb": "3.817.0",
|
|
40
41
|
"@types/joi": "17.2.3",
|
|
41
42
|
"aws-xray-sdk": "3.10.3",
|
|
42
43
|
"electrodb": "3.4.1",
|
|
@@ -72,6 +72,14 @@ const UPDATED_AT_ATTRIBUTE_DATA = {
|
|
|
72
72
|
set: () => new Date().toISOString(),
|
|
73
73
|
};
|
|
74
74
|
|
|
75
|
+
const UPDATED_BY_ATTRIBUTE_DATA = {
|
|
76
|
+
type: 'string',
|
|
77
|
+
required: false,
|
|
78
|
+
readOnly: false,
|
|
79
|
+
watch: '*',
|
|
80
|
+
default: () => 'system',
|
|
81
|
+
};
|
|
82
|
+
|
|
75
83
|
/**
|
|
76
84
|
* The SchemaBuilder class allows for constructing a schema definition
|
|
77
85
|
* including attributes, indexes, and references to other entities.
|
|
@@ -136,6 +144,7 @@ class SchemaBuilder {
|
|
|
136
144
|
this.addAttribute(this.idName, ID_ATTRIBUTE_DATA);
|
|
137
145
|
this.addAttribute('createdAt', CREATED_AT_ATTRIBUTE_DATA);
|
|
138
146
|
this.addAttribute('updatedAt', UPDATED_AT_ATTRIBUTE_DATA);
|
|
147
|
+
this.addAttribute('updatedBy', UPDATED_BY_ATTRIBUTE_DATA);
|
|
139
148
|
// todo: add createdBy, updatedBy and auto-set from auth context
|
|
140
149
|
|
|
141
150
|
// set up the primary index directly
|