Closed bozhaobitsight closed 2 years ago
The GetEntitlement call will receive a null response when there is no active subscription. If the subscription creation fails because of the customer's AWS account issue, then the entitlement will not be active. The customer on initial setup may reach the registration page before AWS Marketplace processes their subscription request. It is recommended to consider the Marketplace APIs as source of truth for verifying customer's subscription and provisioning access to your software. The serverless application is working as expected
Describe the bug Running into a runtime error on the entitlementService script with the following log: `2022-03-14T21:05:27.152Z 60da1f47-10a8-5a34-adc1-45eea0e044ea INFO entitlementsResponse {}
2022-03-14T21:05:27.152Z 60da1f47-10a8-5a34-adc1-45eea0e044ea ERROR Invoke Error)",
" at processTicksAndRejections (internal/process/task_queues.js:97:5)",
" at async Promise.all (index 0)",
" at async Runtime.exports.handler (/var/task/entitlement-sqs.js:8:3)"
]
}`
{ "errorType": "TypeError", "errorMessage": "Cannot read property '0' of undefined", "stack": [ "TypeError: Cannot read property '0' of undefined", " at /var/task/entitlement-sqs.js:33:67", " at runMicrotasks (
To Reproduce Steps to reproduce the behavior:
Expected behavior This line in the entitlement-sqs.js,
const entitlementsResponse = await marketplaceEntitlementService.getEntitlements(entitlementParams).promise();
should not be returning an empty object.Desktop (please complete the following information):
Additional context Add any other context about the problem here.