DEV Community

xxyopen
xxyopen

Posted on • Edited on

2 2

After I start a node program listening on port 8080, can I still start a Java program on port 8080 without reporting an error?

When I was working before, a node program listened to port 8080 before starting the Spring Boot Admin Server, and then started the Spring Boot Admin Server (the default is also port 8080).

At this time, the browser can access the Spring Boot Admin Server interface normally, but other Java services cannot be registered with the Spring Boot Admin Server, prompting a 404 error.

Later, it was found that the registration of the novel service was handled by the node program listening on port 8080, and the node program could be closed to register normally.

Is this because Node.Js can achieve port reuse? Can someone who knows it explain it in detail?

Top comments (0)

Hostinger image

Get n8n VPS hosting 3x cheaper than a cloud solution

Get fast, easy, secure n8n VPS hosting from $4.99/mo at Hostinger. Automate any workflow using a pre-installed n8n application and no-code customization.

Start now

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay