Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AsyncCreate does not work #50

Open
sauravmndl-zz opened this issue Aug 17, 2020 · 0 comments
Open

AsyncCreate does not work #50

sauravmndl-zz opened this issue Aug 17, 2020 · 0 comments

Comments

@sauravmndl-zz
Copy link

sauravmndl-zz commented Aug 17, 2020

I have an asyncCreate() with LongRunning.PingInSeconds=120
https://github.com/andrew-templeton/cfn-lambda/blob/development/index.js#L180
First time it wait for 120 sec and invokes lambda and exits.
The invocation works. I reply NotDone() and it gets the message so, as follows
INFO Got NotDone signal callback from implementation of cfn-lambda resource, engaging another tick in the cycle.
But after that it sets timeout again for 120 sec. But this doesn't work. It doesn't comeback after 120 sec. The code inside setTimeout() doesn't execute.

Logs form AsyncCreate:
INFO Long running configurations found and initialization sent SUCCESS, continuing with recurse operation: ....
INFO In 120 seconds, will recurse with event:.... (it has long running context)
PingInSeconds of 120 seconds passed, recursing lambda with: ......
Triggered long running ping step: {"StatusCode":202,"Payload":""}

  | 2020-08-18T00:58:01.902+05:30 | 2020-08-17T19:28:01.902Z xxx INFO Terminating this lambda and allowing lambda recursion to take over.
  | 2020-08-18T00:58:01.935+05:30 | END RequestId: xxxxx
  | 2020-08-18T00:58:01.935+05:30 | REPORT RequestId: xxx Duration: 124947.01 ms Billed Duration: 125000 ms Memory Size: 128 MB Max Memory Used: 117 MB Init Duration: 1322.69 ms
XRAY TraceId: xxx SegmentId: xxx Sampled: true

Logs from 1st (and only poll):
LongRunningRequestContext found, proceeding with ping cycle logic:
INFO Inside LongRunning request ping cycle and not timed out, diverting Create to handler with notDone callback supplied.
Got NotDone signal callback from implementation of cfn-lambda resource, engaging another tick in the cycle.
Long running configurations found and initialization sent SUCCESS, continuing with recurse operation:
In 120 seconds, will recurse with event:

2020-08-18T00:58:02.495+05:30 END RequestId: xxx
  2020-08-18T00:58:02.495+05:30

Please note the polling logs doesn't have following logs as AsyncCreate call which should execute in after setTimeout() time over:
PingInSeconds of 120 seconds passed, recursing lambda with: ......
Triggered long running ping step: {"StatusCode":202,"Payload":""}

  | 2020-08-18T00:58:01.902+05:30 | 2020-08-17T19:28:01.902Z xxx INFO Terminating this lambda and allowing lambda recursion to take over.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant