error - "Script node is still starting\"

Hi,

When running a node js proxy api which connects to a sharepoint via ntlm authentication, i am getting an error-

{"fault":"{\"detail\":{\"errorcode\":\"scripts.node.runtime.ScriptStillStarting\"},\"faultstring\":\"Script node is still starting\"}"}

not sure what is to be done. Is this error related to any configuration settings or coding?

Thanks,

K.Prashanthi.

0 3 543
3 REPLIES 3

Hi K. Prashanthi,

You may have tried this, but just to make sure, you may learn some helpful information by viewing Node.js logs. In the Edge UI, open the proxy Overview page, and click Node.js Logs button.

See this page for more details on debugging.

adas
New Member

Hi @Prashanthi,

Its a little hard without looking at your nodejs script. But it typically happens in one of the following conditions:

- If your script has references to multiple node modules and dependencies and it usually takes a while to load these modules when you deploy the proxy and then to start the script. So you might see this error the initial few times, immediately after you deploy your nodejs proxy

- If your nodejs script has a http server and due to some wrong code, the http server fails to start. In this case the apigee runtime would try to start the script a few times(each time it wait for 30 seconds or so) and then makes few retries. If the http server code is not proper, you would consistently get this error.

The question is, are you getting this error only initial few times after you deploy/redeploy the proxy, or does this happen all the time. If its the latter, then you might want to post your nodejs script here so that we can have a look. Also, as Will suggested go and take a look at the nodejs logs, it would give you some preliminary information to debug this issue further.

This primarily happens due to the following reason :

If you have a javascript code in your node file and you have not started it as a server. i.e if you are missing this part of the code :

http.createServer(function (request, response) {    

     //Something

}).listen(8124);