@izara_project/izara-core-generate-service-code 1.0.43 → 1.0.45

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.
Files changed (46) hide show
  1. package/package.json +3 -3
  2. package/src/generateCode/generateFlowStepWithPlugIn/firstFlowStep/mainFunction/template.ejs +1 -1
  3. package/src/generateCode/generateFlowStepWithPlugIn/firstFlowStep/queueNtopic/sqsTemplate.ejs +8 -8
  4. package/src/generateCode/generateFlowStepWithPlugIn/firstFlowStep/yaml/template.ejs +13 -1
  5. package/src/generateCode/generateInitialSetup/externalServiceComponent/lambdaRole/data.js +12 -12
  6. package/src/generateCode/generateInitialSetup/externalServiceComponent/lambdaRole/template.ejs +1 -0
  7. package/src/generateCode/generateSchema/actionEndpointComponent/mainFunction/get/template.ejs +1 -1
  8. package/src/generateCode/generateSchema/findDataComponent/GetByStorage/getByGraph.ejs +1 -1
  9. package/src/generateCode/generateSchema/relationshipPerActionComponent/changeRelationship/action/functionYaml/data.js +37 -18
  10. package/src/generateCode/generateSchema/relationshipPerActionComponent/changeRelationship/action/functionYaml/template.ejs +33 -9
  11. package/src/generateCode/generateSchema/relationshipPerActionComponent/create/action/functionYaml/data.js +26 -11
  12. package/src/generateCode/generateSchema/relationshipPerActionComponent/create/action/functionYaml/template.ejs +33 -9
  13. package/src/generateCode/generateSchema/relationshipPerActionComponent/delete/action/functionYaml/data.js +28 -11
  14. package/src/generateCode/generateSchema/relationshipPerActionComponent/delete/action/functionYaml/template.ejs +33 -9
  15. package/src/generateCode/generateSchema/relationshipPerActionComponent/get/action/functionYaml/data.js +26 -13
  16. package/src/generateCode/generateSchema/relationshipPerActionComponent/get/action/functionYaml/template.ejs +27 -9
  17. package/src/generateCode/generateSchema/relationshipPerActionComponent/index.js +3 -2
  18. package/src/generateCode/generateSchema/relationshipPerActionComponent/moveRelationship/action/functionYaml/data.js +27 -11
  19. package/src/generateCode/generateSchema/relationshipPerActionComponent/moveRelationship/action/functionYaml/template.ejs +33 -9
  20. package/src/generateCode/generateSchema/relationshipPerActionComponent/update/action/functionYaml/data.js +27 -6
  21. package/src/generateCode/generateSchema/relationshipPerActionComponent/update/action/functionYaml/template.ejs +33 -9
  22. package/src/libs/Libs.js +13 -12
  23. package/src/generateCode/generateSchema/relationshipPerActionComponent/changeRelationship/action/functionYaml/templateByHandler/apiTemplate.ejs +0 -20
  24. package/src/generateCode/generateSchema/relationshipPerActionComponent/changeRelationship/action/functionYaml/templateByHandler/dsqTemplate.ejs +0 -17
  25. package/src/generateCode/generateSchema/relationshipPerActionComponent/changeRelationship/action/functionYaml/templateByHandler/invTemplate.ejs +0 -13
  26. package/src/generateCode/generateSchema/relationshipPerActionComponent/changeRelationship/action/functionYaml/templateByHandler/sqsTemplate.ejs +0 -18
  27. package/src/generateCode/generateSchema/relationshipPerActionComponent/create/action/functionYaml/templateByHandler/apiTemplate.ejs +0 -21
  28. package/src/generateCode/generateSchema/relationshipPerActionComponent/create/action/functionYaml/templateByHandler/dsqTemplate.ejs +0 -17
  29. package/src/generateCode/generateSchema/relationshipPerActionComponent/create/action/functionYaml/templateByHandler/invTemplate.ejs +0 -13
  30. package/src/generateCode/generateSchema/relationshipPerActionComponent/create/action/functionYaml/templateByHandler/sqsTemplate.ejs +0 -17
  31. package/src/generateCode/generateSchema/relationshipPerActionComponent/delete/action/functionYaml/templateByHandler/apiTemplate.ejs +0 -21
  32. package/src/generateCode/generateSchema/relationshipPerActionComponent/delete/action/functionYaml/templateByHandler/dsqTemplate.ejs +0 -17
  33. package/src/generateCode/generateSchema/relationshipPerActionComponent/delete/action/functionYaml/templateByHandler/invTemplate.ejs +0 -13
  34. package/src/generateCode/generateSchema/relationshipPerActionComponent/delete/action/functionYaml/templateByHandler/sqsTemplate.ejs +0 -18
  35. package/src/generateCode/generateSchema/relationshipPerActionComponent/get/action/functionYaml/templateByHandler/apiTemplate.ejs +0 -21
  36. package/src/generateCode/generateSchema/relationshipPerActionComponent/get/action/functionYaml/templateByHandler/dsqTemplate.ejs +0 -17
  37. package/src/generateCode/generateSchema/relationshipPerActionComponent/get/action/functionYaml/templateByHandler/invTemplate.ejs +0 -13
  38. package/src/generateCode/generateSchema/relationshipPerActionComponent/get/action/functionYaml/templateByHandler/sqsTemplate.ejs +0 -18
  39. package/src/generateCode/generateSchema/relationshipPerActionComponent/moveRelationship/action/functionYaml/templateByHandler/apiTemplate.ejs +0 -20
  40. package/src/generateCode/generateSchema/relationshipPerActionComponent/moveRelationship/action/functionYaml/templateByHandler/dsqTemplate.ejs +0 -17
  41. package/src/generateCode/generateSchema/relationshipPerActionComponent/moveRelationship/action/functionYaml/templateByHandler/invTemplate.ejs +0 -13
  42. package/src/generateCode/generateSchema/relationshipPerActionComponent/moveRelationship/action/functionYaml/templateByHandler/sqsTemplate.ejs +0 -17
  43. package/src/generateCode/generateSchema/relationshipPerActionComponent/update/action/functionYaml/templateByHandler/apiTemplate.ejs +0 -20
  44. package/src/generateCode/generateSchema/relationshipPerActionComponent/update/action/functionYaml/templateByHandler/dsqTemplate.ejs +0 -18
  45. package/src/generateCode/generateSchema/relationshipPerActionComponent/update/action/functionYaml/templateByHandler/invTemplate.ejs +0 -13
  46. package/src/generateCode/generateSchema/relationshipPerActionComponent/update/action/functionYaml/templateByHandler/sqsTemplate.ejs +0 -17
@@ -112,7 +112,6 @@ const baseComponents = [
112
112
  changeRelActionMainFunction,
113
113
  changeRelActionHandler,
114
114
  changeRelActionSnsInSqs,
115
- changeRelActionFunctionYaml,
116
115
  changeRelCompleteMainFunction,
117
116
  changeRelCompleteFunctionYaml,
118
117
  changeRelCompleteHandler,
@@ -134,7 +133,9 @@ const schemaComponents = [
134
133
  createActionFunctionYaml,
135
134
  deleteActionFunctionYaml,
136
135
  getActionFunctionYaml,
137
- moveRelActionFunctionYaml
136
+ moveRelActionFunctionYaml,
137
+ changeRelActionFunctionYaml,
138
+
138
139
  ];
139
140
 
140
141
  async function relationshipPerActionComponent(
@@ -35,7 +35,10 @@ const {
35
35
  HANDLER
36
36
  } = consts;
37
37
 
38
- const { firstLetterUpperCase: upperCase, getLocalConfig } = utils;
38
+ const { firstLetterUpperCase: upperCase,
39
+ firstLetterLowerCase: lowerCase,
40
+ getLocalConfig
41
+ } = utils;
39
42
 
40
43
  const {
41
44
  createIamRole,
@@ -46,11 +49,6 @@ const {
46
49
  } = libs;
47
50
  const templatePath = path.join(__dirname, 'template.ejs');
48
51
 
49
- const apiTemplate = path.join(__dirname, 'templateByHandler/apiTemplate.ejs');
50
- const dsqTemplate = path.join(__dirname, 'templateByHandler/dsqTemplate.ejs');
51
- const invTemplate = path.join(__dirname, 'templateByHandler/invTemplate.ejs');
52
- const sqsTemplate = path.join(__dirname, 'templateByHandler/sqsTemplate.ejs');
53
-
54
52
  /**
55
53
  * receive objectSchema
56
54
  * create data for updateRelationshipSchema
@@ -140,6 +138,21 @@ function createParamForCreateSource(
140
138
  );
141
139
  }
142
140
 
141
+ const serviceTag = getLocalConfig('iz_serviceTag');
142
+
143
+ const resourcesApi = [];
144
+ if (handlerType === HANDLER.hdrApi) {
145
+ allObjectRelationships.map(relationshipSchema => (
146
+ resourcesApi.push({
147
+ event: lowerCase(Object.keys(relationshipSchema)[0]),
148
+ method: 'post',
149
+ action: 'move'
150
+ }))
151
+ )
152
+ }
153
+
154
+ const event = resourceNames(RESOURCE_CLASSES.sqs, upperCase(functionName) + upperCase(handlerType));
155
+
143
156
  return {
144
157
  templatePath: templatePath,
145
158
  templateData: {
@@ -151,11 +164,14 @@ function createParamForCreateSource(
151
164
  upperCase(SHORT_FUNCTION_NAME(FUNCTION_NAME.moveRel)) +
152
165
  upperCase(shortNameHandler(handlerType)),
153
166
  roleName: SOURCE_GENERATE_IAM_ROLE.RelationshipRole,
154
- serviceTag: getLocalConfig('iz_serviceTag'),
155
- apiTemplate,
156
- dsqTemplate,
157
- invTemplate,
158
- sqsTemplate
167
+ resourceApis: resourcesApi.map(api => ({
168
+ path: `/${serviceTag}/${api.event}/${api.action}`,
169
+ pathWithUser: `/${serviceTag}/${api.event}/${api.action}/{targetUserId}`,
170
+ method: api.method,
171
+ hookTagApp: `${upperCase(api.event)}AppLevelAuthorizer`,
172
+ hookTagUser: `${upperCase(api.event)}UserLevelAuthorizer`
173
+ })),
174
+ event
159
175
  },
160
176
  setting: {
161
177
  savePath: path.join(srcPath, SOURCE_PATH.appYaml),
@@ -1,9 +1,33 @@
1
- <% if (handlerType === "hdrApi") { %>
2
- <%- include(apiTemplate),{ functionName, handlerType, additionalResourcePermission, resourceLocation, functionNameConfig, roleName, serviceTag } %>
3
- <% } else if (handlerType === "hdrDsq") { %>
4
- <%- include(dsqTemplate), { functionName, handlerType, additionalResourcePermission, resourceLocation, functionNameConfig, roleName } %>
5
- <% } else if (handlerType === "hdrInv") { %>
6
- <%- include(invTemplate), { functionName, handlerType, additionalResourcePermission, resourceLocation, functionNameConfig, roleName } %>
7
- <% } else if (handlerType === "hdrSqs") { %>
8
- <%- include(sqsTemplate),{ functionName, handlerType, additionalResourcePermission, resourceLocation, functionNameConfig, roleName } %>
9
- <% } %>
1
+ <%_ const join = require('path').join; _%>
2
+ <%- firstLetterUpperCase(functionNameConfig) %>:
3
+ handler: <%- join(resourceLocation, `${firstLetterUpperCase(functionName)}_${firstLetterUpperCase(handlerType)}.main`)%>
4
+ name: ${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
5
+ role: <%- roleName %>Role
6
+ #<#<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
7
+ #<#/<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
8
+ <%_ if (handlerType === 'hdrDsq' || handlerType === 'hdrSqs') { _%>
9
+ events:
10
+ - sqs:
11
+ arn: <%- event %>
12
+ batchSize: 10
13
+ <%_ } else if (handlerType === 'hdrApi' && resourceApis.length > 0) { _%>
14
+ events:
15
+ <%_ resourceApis.forEach(api => { _%>
16
+ - httpApi:
17
+ path: <%- api.path %>
18
+ method: <%- api.method %>
19
+ #<#<%- api.hookTagApp %>#>
20
+ # authorizer: authorizerServiceSchema
21
+ #<#/<%- api.hookTagApp %>#>
22
+ - httpApi:
23
+ path: <%- api.pathWithUser %>
24
+ method: <%- api.method %>
25
+ #<#<%- api.hookTagUser %>#>
26
+ # authorizer: authorizerIdentifiers
27
+ #<#/<%- api.hookTagUser %>#>
28
+ <%_ }) _%>
29
+ <%_ } _%>
30
+
31
+ <%_ function firstLetterUpperCase(text) {
32
+ return text.charAt(0).toUpperCase() + text.slice(1)
33
+ } _%>
@@ -37,7 +37,10 @@ const {
37
37
  HANDLER
38
38
  } = consts;
39
39
 
40
- const { firstLetterUpperCase: upperCase, getLocalConfig } = utils;
40
+ const { firstLetterUpperCase: upperCase,
41
+ firstLetterLowerCase: lowerCase,
42
+ getLocalConfig
43
+ } = utils;
41
44
 
42
45
  const {
43
46
  createIamRole,
@@ -165,6 +168,21 @@ function createParamForCreateSource(
165
168
  }
166
169
  }
167
170
 
171
+ const serviceTag = getLocalConfig('iz_serviceTag');
172
+
173
+ const resourcesApi = [];
174
+ if (handlerType === HANDLER.hdrApi) {
175
+ allObjectRelationships.map(relationshipSchema => (
176
+ resourcesApi.push({
177
+ event: lowerCase(Object.keys(relationshipSchema)[0]),
178
+ method: 'post',
179
+ action: 'update'
180
+ }))
181
+ )
182
+ }
183
+
184
+ const event = resourceNames(RESOURCE_CLASSES.sqs, upperCase(functionName) + upperCase(handlerType));
185
+
168
186
  return {
169
187
  templatePath: templatePath,
170
188
  templateData: {
@@ -176,11 +194,14 @@ function createParamForCreateSource(
176
194
  upperCase(SHORT_FUNCTION_NAME(FUNCTION_NAME.updateRel)) +
177
195
  upperCase(shortNameHandler(handlerType)),
178
196
  roleName: SOURCE_GENERATE_IAM_ROLE.RelationshipRole,
179
- serviceTag: getLocalConfig('iz_serviceTag'),
180
- apiTemplate,
181
- dsqTemplate,
182
- invTemplate,
183
- sqsTemplate
197
+ resourceApis: resourcesApi.map(api => ({
198
+ path: `/${serviceTag}/${api.event}/${api.action}`,
199
+ pathWithUser: `/${serviceTag}/${api.event}/${api.action}/{targetUserId}`,
200
+ method: api.method,
201
+ hookTagApp: `${upperCase(api.event)}AppLevelAuthorizer`,
202
+ hookTagUser: `${upperCase(api.event)}UserLevelAuthorizer`
203
+ })),
204
+ event
184
205
  },
185
206
  setting: {
186
207
  savePath: path.join(srcPath, SOURCE_PATH.appYaml),
@@ -1,9 +1,33 @@
1
- <% if (handlerType === "hdrApi") { %>
2
- <%- include(apiTemplate),{ functionName, handlerType, additionalResourcePermission, resourceLocation, functionNameConfig, roleName, serviceTag } %>
3
- <% } else if (handlerType === "hdrDsq") { %>
4
- <%- include(dsqTemplate), { functionName, handlerType, additionalResourcePermission, resourceLocation, functionNameConfig, roleName } %>
5
- <% } else if (handlerType === "hdrInv") { %>
6
- <%- include(invTemplate), { functionName, handlerType, additionalResourcePermission, resourceLocation, functionNameConfig, roleName } %>
7
- <% } else if (handlerType === "hdrSqs") { %>
8
- <%- include(sqsTemplate),{ functionName, handlerType, additionalResourcePermission, resourceLocation, functionNameConfig, roleName } %>
9
- <% } %>
1
+ <%_ const join = require('path').join; _%>
2
+ <%- firstLetterUpperCase(functionNameConfig) %>:
3
+ handler: <%- join(resourceLocation, `${firstLetterUpperCase(functionName)}_${firstLetterUpperCase(handlerType)}.main`)%>
4
+ name: ${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
5
+ role: <%- roleName %>Role
6
+ #<#<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
7
+ #<#/<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
8
+ <%_ if (handlerType === 'hdrDsq' || handlerType === 'hdrSqs') { _%>
9
+ events:
10
+ - sqs:
11
+ arn: <%- event %>
12
+ batchSize: 10
13
+ <%_ } else if (handlerType === 'hdrApi' && resourceApis.length > 0) { _%>
14
+ events:
15
+ <%_ resourceApis.forEach(api => { _%>
16
+ - httpApi:
17
+ path: <%- api.path %>
18
+ method: <%- api.method %>
19
+ #<#<%- api.hookTagApp %>#>
20
+ # authorizer: authorizerServiceSchema
21
+ #<#/<%- api.hookTagApp %>#>
22
+ - httpApi:
23
+ path: <%- api.pathWithUser %>
24
+ method: <%- api.method %>
25
+ #<#<%- api.hookTagUser %>#>
26
+ # authorizer: authorizerIdentifiers
27
+ #<#/<%- api.hookTagUser %>#>
28
+ <%_ }) _%>
29
+ <%_ } _%>
30
+
31
+ <%_ function firstLetterUpperCase(text) {
32
+ return text.charAt(0).toUpperCase() + text.slice(1)
33
+ } _%>
package/src/libs/Libs.js CHANGED
@@ -120,29 +120,30 @@ function externalResourceName(resourceClass, resourceName, serviceTag) {
120
120
  }
121
121
 
122
122
  function externalResourceYaml(resourceClass, resourceName, serviceTag) {
123
-
124
123
  return {
125
124
  [RESOURCE_CLASSES.dynamoDbTable]:
126
125
  'arn:aws:dynamodb:${self:custom.iz_region}:${self:custom.iz_accountId}:table/' +
127
- serviceTag ?
128
- '${self:custom.iz_resourcePrefix}' + resourceName :
129
- serviceTag + '${self:custom.iz_stage}' + resourceName,
126
+ (serviceTag ?
127
+ serviceTag + '${self:custom.iz_stage}' + resourceName :
128
+ '${self:custom.iz_resourcePrefix}' + resourceName),
130
129
  // `${ serviceTag } ` +
131
130
  // `${ resourceName } `,
132
131
  [RESOURCE_CLASSES.lambda]:
133
132
  'arn:aws:lambda:${self: custom.iz_region}:${self:custom.iz_accountId}:function:' +
134
- serviceTag ?
135
- '${self:custom.iz_resourcePrefix}' + resourceName :
136
- serviceTag + '${self:custom.iz_stage}' + resourceName,
133
+ (serviceTag ?
134
+ serviceTag + '${self:custom.iz_stage}' + resourceName :
135
+ '${self:custom.iz_resourcePrefix}' + resourceName),
136
+
137
137
  [RESOURCE_CLASSES.sns]:
138
138
  'arn:aws:sns:${self:custom.iz_region}:${self:custom.iz_accountId}:' +
139
- serviceTag ? '${self:custom.iz_serviceTag}_${self:custom.iz_stage}_' + resourceName :
140
- serviceTag + '_${self:custom.iz_stage}_' + resourceName,
139
+ (serviceTag ? serviceTag + '_${self:custom.iz_stage}_' + resourceName :
140
+ '${self:custom.iz_serviceTag}_${self:custom.iz_stage}_' + resourceName),
141
+
141
142
  [RESOURCE_CLASSES.sqs]:
142
143
  'arn:aws:sqs:${self:custom.iz_region}:${self:custom.iz_accountId}:' +
143
- serviceTag ?
144
- '${self:custom.iz_resourcePrefix}' + resourceName :
145
- serviceTag + '${self:custom.iz_stage}' + resourceName,
144
+ (serviceTag ?
145
+ serviceTag + '${self:custom.iz_stage}' + resourceName :
146
+ '${self:custom.iz_resourcePrefix}' + resourceName),
146
147
  }[resourceClass];
147
148
  }
148
149
 
@@ -1,20 +0,0 @@
1
- <%_ const join = require('path').join; _%>
2
- <%- firstLetterUpperCase(functionNameConfig) %>:
3
- handler: <%- join(resourceLocation, `${firstLetterUpperCase(functionName)}_${firstLetterUpperCase(handlerType)}.main`)%>
4
- name: ${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
5
- role: <%- roleName %>Role
6
- #<#<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
7
- #<#/<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
8
- events:
9
- - http:
10
- path: /<%- serviceTag %>/<%- firstLetterLowerCase(functionName) %>/<%- functionName %>/
11
- method: put
12
- cors: true
13
- #<#Authorizer#>
14
- #<#/Authorizer#>
15
- <%_ function firstLetterUpperCase(text){
16
- return text.charAt(0).toUpperCase() + text.slice(1)
17
- } _%>
18
- <%_ function firstLetterLowerCase(str) {
19
- return str.charAt(0).toLowerCase() + str.slice(1)
20
- } _%>
@@ -1,17 +0,0 @@
1
- <%_ const join = require('path').join; _%>
2
- <%- firstLetterUpperCase(functionNameConfig) %>:
3
- handler: <%- join(resourceLocation, `${firstLetterUpperCase(functionName)}_${firstLetterUpperCase(handlerType)}.main`)%>
4
- name: ${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
5
- role: <%- roleName %>Role
6
- #<#<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
7
- #<#/<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
8
- events:
9
- - sqs:
10
- arn: arn:aws:sqs:${self:custom.iz_region}:${self:custom.iz_accountId}:${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
11
- batchSize: 10
12
- <%_ function firstLetterUpperCase(text){
13
- return text.charAt(0).toUpperCase() + text.slice(1)
14
- } _%>
15
- <%_ function firstLetterLowerCase(str) {
16
- return str.charAt(0).toLowerCase() + str.slice(1)
17
- } _%>
@@ -1,13 +0,0 @@
1
- <%_ const join = require('path').join; _%>
2
- <%- firstLetterUpperCase(functionNameConfig) %>:
3
- handler: <%- join(resourceLocation, `${firstLetterUpperCase(functionName)}_${firstLetterUpperCase(handlerType)}.main`)%>
4
- name: ${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
5
- role: <%- roleName %>Role
6
- #<#<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
7
- #<#/<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
8
- <%_ function firstLetterUpperCase(text){
9
- return text.charAt(0).toUpperCase() + text.slice(1)
10
- } _%>
11
- <%_ function firstLetterLowerCase(str) {
12
- return str.charAt(0).toLowerCase() + str.slice(1)
13
- } _%>
@@ -1,18 +0,0 @@
1
- <%_ const join = require('path').join; _%>
2
- <%- firstLetterUpperCase(functionNameConfig) %>:
3
- handler: <%- join(resourceLocation, `${firstLetterUpperCase(functionName)}_${firstLetterUpperCase(handlerType)}.main`)%>
4
- name: ${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
5
- role: <%- roleName %>Role
6
- #<#<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
7
- #<#/<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
8
- events:
9
- - sqs:
10
- arn: arn:aws:sqs:${self:custom.iz_region}:${self:custom.iz_accountId}:${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
11
- batchSize: 10
12
-
13
- <%_ function firstLetterUpperCase(text){
14
- return text.charAt(0).toUpperCase() + text.slice(1)
15
- } _%>
16
- <%_ function firstLetterLowerCase(str) {
17
- return str.charAt(0).toLowerCase() + str.slice(1)
18
- } _%>
@@ -1,21 +0,0 @@
1
- <%_ const join = require('path').join; _%>
2
- <%- firstLetterUpperCase(functionNameConfig) %>:
3
- handler: <%- join(resourceLocation, `${firstLetterUpperCase(functionName)}_${firstLetterUpperCase(handlerType)}.main`)%>
4
- name: ${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
5
- role: <%- roleName %>Role
6
- #<#<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
7
- #<#/<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
8
- events:
9
- - http:
10
- path: /<%- serviceTag %>/<%- firstLetterLowerCase(functionName) %>/<%- functionName %>/
11
- method: put
12
- cors: true
13
- #<#Authorizer#>
14
- #<#/Authorizer#>
15
-
16
- <%_ function firstLetterUpperCase(text){
17
- return text.charAt(0).toUpperCase() + text.slice(1)
18
- } _%>
19
- <%_ function firstLetterLowerCase(str) {
20
- return str.charAt(0).toLowerCase() + str.slice(1)
21
- } _%>
@@ -1,17 +0,0 @@
1
- <%_ const join = require('path').join; _%>
2
- <%- firstLetterUpperCase(functionNameConfig) %>:
3
- handler: <%- join(resourceLocation, `${firstLetterUpperCase(functionName)}_${firstLetterUpperCase(handlerType)}.main`)%>
4
- name: ${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
5
- role: <%- roleName %>Role
6
- #<#<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
7
- #<#/<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
8
- events:
9
- - sqs:
10
- arn: arn:aws:sqs:${self:custom.iz_region}:${self:custom.iz_accountId}:${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
11
- batchSize: 10
12
- <%_ function firstLetterUpperCase(text){
13
- return text.charAt(0).toUpperCase() + text.slice(1)
14
- } _%>
15
- <%_ function firstLetterLowerCase(str) {
16
- return str.charAt(0).toLowerCase() + str.slice(1)
17
- } _%>
@@ -1,13 +0,0 @@
1
- <%_ const join = require('path').join; _%>
2
- <%- firstLetterUpperCase(functionNameConfig) %>:
3
- handler: <%- join(resourceLocation, `${firstLetterUpperCase(functionName)}_${firstLetterUpperCase(handlerType)}.main`)%>
4
- name: ${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
5
- role: <%- roleName %>Role
6
- #<#<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
7
- #<#/<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
8
- <%_ function firstLetterUpperCase(text){
9
- return text.charAt(0).toUpperCase() + text.slice(1)
10
- } _%>
11
- <%_ function firstLetterLowerCase(str) {
12
- return str.charAt(0).toLowerCase() + str.slice(1)
13
- } _%>
@@ -1,17 +0,0 @@
1
- <%_ const join = require('path').join; _%>
2
- <%- firstLetterUpperCase(functionNameConfig) %>:
3
- handler: <%- join(resourceLocation, `${firstLetterUpperCase(functionName)}_${firstLetterUpperCase(handlerType)}.main`)%>
4
- name: ${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
5
- role: <%- roleName %>Role
6
- #<#<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
7
- #<#/<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
8
- events:
9
- - sqs:
10
- arn: arn:aws:sqs:${self:custom.iz_region}:${self:custom.iz_accountId}:${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
11
- batchSize: 10
12
- <%_ function firstLetterUpperCase(text){
13
- return text.charAt(0).toUpperCase() + text.slice(1)
14
- } _%>
15
- <%_ function firstLetterLowerCase(str) {
16
- return str.charAt(0).toLowerCase() + str.slice(1)
17
- } _%>
@@ -1,21 +0,0 @@
1
- <%_ const join = require('path').join; _%>
2
- <%- firstLetterUpperCase(functionNameConfig) %>:
3
- handler: <%- join(resourceLocation, `${firstLetterUpperCase(functionName)}_${firstLetterUpperCase(handlerType)}.main`)%>
4
- name: ${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
5
- role: <%- roleName %>Role
6
- #<#<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
7
- #<#/<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
8
- events:
9
- - http:
10
- path: /<%- serviceTag %>/<%- firstLetterLowerCase(functionName) %>/<%- functionName %>/
11
- method: put
12
- cors: true
13
- #<#Authorizer#>
14
- #<#/Authorizer#>
15
-
16
- <%_ function firstLetterUpperCase(text){
17
- return text.charAt(0).toUpperCase() + text.slice(1)
18
- } _%>
19
- <%_ function firstLetterLowerCase(str) {
20
- return str.charAt(0).toLowerCase() + str.slice(1)
21
- } _%>
@@ -1,17 +0,0 @@
1
- <%_ const join = require('path').join; _%>
2
- <%- firstLetterUpperCase(functionNameConfig) %>:
3
- handler: <%- join(resourceLocation, `${firstLetterUpperCase(functionName)}_${firstLetterUpperCase(handlerType)}.main`)%>
4
- name: ${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
5
- role: <%- roleName %>Role
6
- #<#<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
7
- #<#/<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
8
- events:
9
- - sqs:
10
- arn: arn:aws:sqs:${self:custom.iz_region}:${self:custom.iz_accountId}:${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
11
- batchSize: 10
12
- <%_ function firstLetterUpperCase(text){
13
- return text.charAt(0).toUpperCase() + text.slice(1)
14
- } _%>
15
- <%_ function firstLetterLowerCase(str) {
16
- return str.charAt(0).toLowerCase() + str.slice(1)
17
- } _%>
@@ -1,13 +0,0 @@
1
- <%_ const join = require('path').join; _%>
2
- <%- firstLetterUpperCase(functionNameConfig) %>:
3
- handler: <%- join(resourceLocation, `${firstLetterUpperCase(functionName)}_${firstLetterUpperCase(handlerType)}.main`)%>
4
- name: ${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
5
- role: <%- roleName %>Role
6
- #<#<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
7
- #<#/<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
8
- <%_ function firstLetterUpperCase(text){
9
- return text.charAt(0).toUpperCase() + text.slice(1)
10
- } _%>
11
- <%_ function firstLetterLowerCase(str) {
12
- return str.charAt(0).toLowerCase() + str.slice(1)
13
- } _%>
@@ -1,18 +0,0 @@
1
- <%_ const join = require('path').join; _%>
2
- <%- firstLetterUpperCase(functionNameConfig) %>:
3
- handler: <%- join(resourceLocation, `${firstLetterUpperCase(functionName)}_${firstLetterUpperCase(handlerType)}.main`)%>
4
- name: ${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
5
- role: <%- roleName %>Role
6
- #<#<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
7
- #<#/<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
8
- events:
9
- - sqs:
10
- arn: arn:aws:sqs:${self:custom.iz_region}:${self:custom.iz_accountId}:${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
11
- batchSize: 10
12
-
13
- <%_ function firstLetterUpperCase(text){
14
- return text.charAt(0).toUpperCase() + text.slice(1)
15
- } _%>
16
- <%_ function firstLetterLowerCase(str) {
17
- return str.charAt(0).toLowerCase() + str.slice(1)
18
- } _%>
@@ -1,21 +0,0 @@
1
- <%_ const join = require('path').join; _%>
2
- <%- firstLetterUpperCase(functionNameConfig) %>:
3
- handler: <%- join(resourceLocation, `${firstLetterUpperCase(functionName)}_${firstLetterUpperCase(handlerType)}.main`)%>
4
- name: ${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
5
- role: <%- roleName %>Role
6
- #<#<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
7
- #<#/<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
8
- events:
9
- - http:
10
- path: /<%- serviceTag %>/<%- firstLetterLowerCase(functionName) %>/<%- functionName %>/
11
- method: put
12
- cors: true
13
- #<#Authorizer#>
14
- #<#/Authorizer#>
15
-
16
- <%_ function firstLetterUpperCase(text){
17
- return text.charAt(0).toUpperCase() + text.slice(1)
18
- } _%>
19
- <%_ function firstLetterLowerCase(str) {
20
- return str.charAt(0).toLowerCase() + str.slice(1)
21
- } _%>
@@ -1,17 +0,0 @@
1
- <%_ const join = require('path').join; _%>
2
- <%- firstLetterUpperCase(functionNameConfig) %>:
3
- handler: <%- join(resourceLocation, `${firstLetterUpperCase(functionName)}_${firstLetterUpperCase(handlerType)}.main`)%>
4
- name: ${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
5
- role: <%- roleName %>Role
6
- #<#<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
7
- #<#/<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
8
- events:
9
- - sqs:
10
- arn: arn:aws:sqs:${self:custom.iz_region}:${self:custom.iz_accountId}:${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
11
- batchSize: 10
12
- <%_ function firstLetterUpperCase(text){
13
- return text.charAt(0).toUpperCase() + text.slice(1)
14
- } _%>
15
- <%_ function firstLetterLowerCase(str) {
16
- return str.charAt(0).toLowerCase() + str.slice(1)
17
- } _%>
@@ -1,13 +0,0 @@
1
- <%_ const join = require('path').join; _%>
2
- <%- firstLetterUpperCase(functionNameConfig) %>:
3
- handler: <%- join(resourceLocation, `${firstLetterUpperCase(functionName)}_${firstLetterUpperCase(handlerType)}.main`)%>
4
- name: ${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
5
- role: <%- roleName %>Role
6
- #<#<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
7
- #<#/<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
8
- <%_ function firstLetterUpperCase(text){
9
- return text.charAt(0).toUpperCase() + text.slice(1)
10
- } _%>
11
- <%_ function firstLetterLowerCase(str) {
12
- return str.charAt(0).toLowerCase() + str.slice(1)
13
- } _%>
@@ -1,18 +0,0 @@
1
- <%_ const join = require('path').join; _%>
2
- <%- firstLetterUpperCase(functionNameConfig) %>:
3
- handler: <%- join(resourceLocation, `${firstLetterUpperCase(functionName)}_${firstLetterUpperCase(handlerType)}.main`)%>
4
- name: ${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
5
- role: <%- roleName %>Role
6
- #<#<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
7
- #<#/<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
8
- events:
9
- - sqs:
10
- arn: arn:aws:sqs:${self:custom.iz_region}:${self:custom.iz_accountId}:${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
11
- batchSize: 10
12
-
13
- <%_ function firstLetterUpperCase(text){
14
- return text.charAt(0).toUpperCase() + text.slice(1)
15
- } _%>
16
- <%_ function firstLetterLowerCase(str) {
17
- return str.charAt(0).toLowerCase() + str.slice(1)
18
- } _%>
@@ -1,20 +0,0 @@
1
- <%_ const join = require('path').join; _%>
2
- <%- firstLetterUpperCase(functionNameConfig) %>:
3
- handler: <%- join(resourceLocation, `${firstLetterUpperCase(functionName)}_${firstLetterUpperCase(handlerType)}.main`)%>
4
- name: ${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
5
- role: <%- roleName %>Role
6
- #<#<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
7
- #<#/<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
8
- events:
9
- - http:
10
- path: /<%- serviceTag %>/<%- firstLetterLowerCase(functionName) %>/<%- functionName %>/
11
- method: put
12
- cors: true
13
- #<#Authorizer#>
14
- #<#/Authorizer#>
15
- <%_ function firstLetterUpperCase(text){
16
- return text.charAt(0).toUpperCase() + text.slice(1)
17
- } _%>
18
- <%_ function firstLetterLowerCase(str) {
19
- return str.charAt(0).toLowerCase() + str.slice(1)
20
- } _%>
@@ -1,17 +0,0 @@
1
- <%_ const join = require('path').join; _%>
2
- <%- firstLetterUpperCase(functionNameConfig) %>:
3
- handler: <%- join(resourceLocation, `${firstLetterUpperCase(functionName)}_${firstLetterUpperCase(handlerType)}.main`)%>
4
- name: ${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
5
- role: <%- roleName %>Role
6
- #<#<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
7
- #<#/<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
8
- events:
9
- - sqs:
10
- arn: arn:aws:sqs:${self:custom.iz_region}:${self:custom.iz_accountId}:${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
11
- batchSize: 10
12
- <%_ function firstLetterUpperCase(text){
13
- return text.charAt(0).toUpperCase() + text.slice(1)
14
- } _%>
15
- <%_ function firstLetterLowerCase(str) {
16
- return str.charAt(0).toLowerCase() + str.slice(1)
17
- } _%>
@@ -1,13 +0,0 @@
1
- <%_ const join = require('path').join; _%>
2
- <%- firstLetterUpperCase(functionNameConfig) %>:
3
- handler: <%- join(resourceLocation, `${firstLetterUpperCase(functionName)}_${firstLetterUpperCase(handlerType)}.main`)%>
4
- name: ${self:custom.iz_resourcePrefix}<%- firstLetterUpperCase(functionName) %><%- firstLetterUpperCase(handlerType) %>
5
- role: <%- roleName %>Role
6
- #<#<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
7
- #<#/<%- functionName %><%- firstLetterUpperCase(handlerType) %>FunctionSetting#>
8
- <%_ function firstLetterUpperCase(text){
9
- return text.charAt(0).toUpperCase() + text.slice(1)
10
- } _%>
11
- <%_ function firstLetterLowerCase(str) {
12
- return str.charAt(0).toLowerCase() + str.slice(1)
13
- } _%>