Skip to content
This repository was archived by the owner on Apr 8, 2020. It is now read-only.

Getting Node invocation timed out error when invoking JS file using Microsoft.AspNetCore.NodeServices #1640

Closed
kgrvr opened this issue May 9, 2018 · 3 comments

Comments

@kgrvr
Copy link

kgrvr commented May 9, 2018

Title

Getting Node invocation timed out error when invoking JS file using Microsoft.AspNetCore.NodeServices

Functional impact

I developed application which is using NodeServices and deployed it on Azure using following article:
https://code.msdn.microsoft.com/How-to-export-HTML-to-PDF-c5afd0ce

It's working locally, but not on deployed version.
Getting node time out error:

The Node invocation timed out after 60000ms.
You can change the timeout duration by setting the InvocationTimeoutMilliseconds property on NodeServicesOptions.
The first debugging step is to ensure that your Node.js function always invokes the supplied callback (or throws an exception synchronously), even if it encounters an error. Otherwise, the .NET code has no way to know that it is finished or has failed. | Source: Microsoft.AspNetCore.NodeServices

Expected result

PDF should be created.

Actual result

NodeService throwing timeout error

I also followed related issues on Github:
#1377
#1177

But still getting Timeout error on deployed version. Any help would be appreciated. Thanks.

@Neminus
Copy link

Neminus commented May 24, 2018

Seeing the exact same problem in my Application.

The NodeService works perfect locally until deployed to azure.
I'm also getting the exact same error with a timeout after 60000ms.

I hope this issue gets a little bit more attention so it will be fixed soon.

@derSidge
Copy link

*upvote! many thanks for help in advance

@SteveSandersonMS
Copy link
Member

According to this StackOverflow answer,

phantomjs and other pdf rendering won't work in Azure App service running on default Windows Server. However you can now use Azure App service running on linux where jsreport nicely works.

Perhaps this is the reason for the task not completing. Sorry for the inconvenience, but this is not something controlled by any code in JavaScriptServices.

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

No branches or pull requests

4 participants