-
Notifications
You must be signed in to change notification settings - Fork 9
fix deploy error on node.js 10 #12
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
base: master
Are you sure you want to change the base?
Conversation
@aditmalik-synechron Any chance we can get this merged in? node v8 is end of life next month on AWS. |
This patch works for me as expected. |
Can this be merged please? AWS Lambda Node 8 runtime has been deprecated for a while now and this is causing deployment issues. |
Facing the same issue as the rest, please have this merged. Thanks! |
Any chance that we get this merged? Or any other package that has similar functionality out there? |
@@ -107,8 +107,7 @@ class ServerlessNestedPlugin { | |||
|
|||
this.serverless.service.provider.compiledCloudFormationTemplate = parentStack; | |||
fs.writeFile(this.packagePath + '/compiled-cloudformation-template.json', | |||
JSON.stringify(parentStack, null, ' ')); | |||
resolve(); | |||
JSON.stringify(parentStack, null, ' '), () => { resolve(); }); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we actually need to move resolve()
into the callback?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
JSON.stringify(parentStack, null, ' '), resolve);
This can probably work. However, I am no longer using this plugin already. I have revamped the lambda functions and shrink the no of objects.
How do you revamp your serverless application to below the 200 limit? I have tried several approaches and all of them are not really elegant solutions to me...
I’m currently considering serverless-additional-stacks to split all my resources into a different stack and refer them in my lambda function through ImportValue fn
…On 18 Sep 2020, 12:22 PM +0800, desmondchou ***@***.***>, wrote:
@desmondchou commented on this pull request.
In index.js:
> @@ -107,8 +107,7 @@ class ServerlessNestedPlugin {
this.serverless.service.provider.compiledCloudFormationTemplate = parentStack;
fs.writeFile(this.packagePath + '/compiled-cloudformation-template.json',
- JSON.stringify(parentStack, null, ' '));
- resolve();
+ JSON.stringify(parentStack, null, ' '), () => { resolve(); });
JSON.stringify(parentStack, null, ' '), resolve);
This can probably work. However, I am no longer using this plugin already. I have revamped the lambda functions and shrink the no of objects.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
Luckily I managed to do it by consolidating handler functions. Reducing number of functions bring the total number of objects down below 200 |
added callback function parameter when calling fs.writeFile in order to address issue #9