NodeJS-Server-Input cannot process simple POST

Hello,

I tried to use the NodeJS-Server-Input Plugin (as an alternative to the HTTP-Server-Input Plugin) to catch a http request. I always get the message “Cannot POST /formStart” in the browser.

Browser console says: “Failed to load resource: the server responded with a status of 404 (Not Found)”.

Port 9090 is set in the NodeJS Server Input plugin preferences 1.

All PlanetPress Workflow services are started (PlanetPress Workflow NodeJS Service, …)

My webform

form action=“http://localhost:9090/formStart” method=“POST”>
input type=“text” name=“test” />
input type=“submit” />
/form>

NodeJS-Server-Input Plugin as first Step in the process

  • HTTP-Action: formStart
  • Mime-Type: text/html

What am I doing wrong?

Thanks,
Thomas

Works fine here. I used your HTML:

<html>
  <body>
    <form action="http://localhost:9090/formStart" method="POST">
      <input type="text" name="test" />
      <input type="submit" />
    </form>
  </body>
</html>

Then, in my process, I have a NodeJS Input task:

And immediately after, I have a Create File task that creates a basic HTML response to send back to the client:

The process ends with a Delete output task.

Then it must be a technical problem on my machine. I had the same settings in the plugin and it seems the request cannot not find the target. Do you have an idea what to check next?
I am using PlanetPress Connect version 2019.1 on windows 10 Pro with latest updates.
On another pc with win 10 pro and pp 2019.1 I have the same issue. :frowning:

Could it be that you are using Microsoft Edge as your browser? Microsoft has disabled loopbacks (i.e. localhost access) by default. See this MS article for more info.

To restore loopback access for Edge, you can do the following:

  • Launch a Command-Line window in administrator mode
  • Type the following command:
    CheckNetIsolation LoopbackExempt -a -n=Microsoft.MicrosoftEdge_8wekyb3d8bbwe​

I’m not sure if you can restore this setting globally for all applications, but the article mentioned above also explains how you can restore loopback for pretty much any individual application.

I am using Chrome and I also tried to set my ip as target (127.0.0.1 and also 192.168…). I changed the standard browser to Firefox, too. I am really puzzled about it.

Ok, I tried it this morning again and now it works :roll_eyes:
The strange thing is that I restarted the pc yesterday many times and it did not work.

Me again. Now I have the same issue as described before (I also had that issue more than one time since my last post here).

I have installed PlanetPress Workflow and PlanetPress Connect on a blank Windows 2016 Server.

I created a new Workflow process with NodeJS-Server-Input. My ajax request to that destination gets the response code 200 (OK), but does not get the response content. Replacing the NodeJS-Server-Input plugin with HTTP-Server-Input pluigin and changing the port to 8080 (in ajax call) everything works just fine (ajax call gets the response content from Workflow).

I restarted all services (Connect Server, Connect MySQL, PP Watch, PP Messenger, PP NodeJS Server) without success.

Any ideas what to do? Or should I just wait until it finally works by itself? That was my only solution in the past.

Things to check and try:

  • Firewall settings for port 9090
  • List of other applications that open ports and that may be using port 9090. Use netstat -a to get a full list
  • Change NodeJS’ default port to something else and try again (e.g. 7070)