@izara_project/izara-market-library-service-schemas 1.0.63 → 1.0.64
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/package.json
CHANGED
|
@@ -58,7 +58,7 @@ function resourceNames(resourceClass, resourceName) {
|
|
|
58
58
|
[RESOURCE_CLASSES.dynamoDbTable]: "arn:aws:dynamodb:${self:custom.iz_region}:${self:custom.iz_accountId}:table/${self:custom.iz_resourcePrefix}" + resourceName,
|
|
59
59
|
[RESOURCE_CLASSES.sns]: "arn:aws:sns:${self:custom.iz_region}:${self:custom.iz_accountId}:${self:custom.iz_serviceTag}_${self:custom.iz_stage}_" + resourceName,
|
|
60
60
|
[RESOURCE_CLASSES.lambda]: "arn:aws:lambda:${self:custom.iz_region}:${self:custom.iz_accountId}:function:${self:custom.iz_resourcePrefix}" + resourceName,
|
|
61
|
-
[RESOURCE_CLASSES.webSocket]: "arn:aws:execute-api:${self:custom.iz_region}:${self:custom.iz_accountId}:${self:custom.iz_webSocketHostId}/
|
|
61
|
+
[RESOURCE_CLASSES.webSocket]: "arn:aws:execute-api:${self:custom.iz_region}:${self:custom.iz_accountId}:${self:custom.iz_webSocketHostId}/${self:custom.iz_stage}/POST/@connections/{connectionId}"
|
|
62
62
|
}[resourceClass];
|
|
63
63
|
}
|
|
64
64
|
|
|
@@ -126,6 +126,11 @@ module.exports.createMain = async (
|
|
|
126
126
|
);
|
|
127
127
|
_izContext.logger.debug("objectSchemas", objectSchemas);
|
|
128
128
|
|
|
129
|
+
let parentObject
|
|
130
|
+
if (objectSchemas.hasOwnProperty("extendObjType")) {
|
|
131
|
+
parentObject = await getObjectSchema.getObjSchemaS3WithHierarchy(_izContext, objectSchema.extendObjType)
|
|
132
|
+
}
|
|
133
|
+
|
|
129
134
|
let userAgent = _izContext.correlationIds.get(middlewareConsts.USER_AGENT)
|
|
130
135
|
_izContext.logger.debug("userAgent::", userAgent);
|
|
131
136
|
|
|
@@ -304,6 +309,13 @@ module.exports.createMain = async (
|
|
|
304
309
|
//(</beforeCreateRecordDynamo>)
|
|
305
310
|
_izContext.logger.debug("::::::DynamoDB::::::", { storageTag, objInstanceFull });
|
|
306
311
|
|
|
312
|
+
if (parentObject) {
|
|
313
|
+
if (createDataDetail.tableName.includes(firstLetterUpperCase(`${parentObject.objectType}Records`))) {
|
|
314
|
+
Object.assign(
|
|
315
|
+
objInstanceFullForDynamoDb.fields,
|
|
316
|
+
{ [`${parentObject.objectType}HandlerServiceTag`]: process.env.iz_serviceTag })
|
|
317
|
+
}
|
|
318
|
+
}
|
|
307
319
|
|
|
308
320
|
Object.assign(objInstanceFullForDynamoDb.fields, createObjInstanceFullFieldsByStorageTag(_izContext, storageTag, createDataDetail))
|
|
309
321
|
_izContext.logger.debug("objInstanceFull before create item in dynamoDB", objInstanceFullForDynamoDb)
|
|
@@ -36,12 +36,14 @@ module.exports.main = middleware.wrap(async (event, context, callback) => {
|
|
|
36
36
|
event._izContext.logger.debug('Event:', event);
|
|
37
37
|
|
|
38
38
|
try {
|
|
39
|
-
|
|
40
39
|
if (event.requestContext) {
|
|
41
40
|
const route = event.requestContext.routeKey;
|
|
42
41
|
const connectionId = event.requestContext.connectionId;
|
|
43
42
|
let correlationId = event._izContext.correlationIds.get(consts.X_CORRELATION_ID)
|
|
44
43
|
|
|
44
|
+
//(<createIdentifiersFlow>)
|
|
45
|
+
let identifiers
|
|
46
|
+
//(</createIdentifiersFlow>)
|
|
45
47
|
|
|
46
48
|
switch (route) {
|
|
47
49
|
|