Reputation: 563
I've more than one project in eclipse which require jetty server (I use maven). I run project1 with no problem. Then I want to turn off project1 and/or just normally start project2. I'm getting error:
[ERROR] Failed to execute goal org.eclipse.jetty:jetty-maven-plugin:9.3.9.v20160517:run (default-cli) on project PROJECT2: Failure: Address already in use: bind -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
How may I restart/rerun jetty server? The problem is in engaged port (localhost:8080). First solution is to restart elipse.
Upvotes: 0
Views: 1311
Reputation: 908
If you want to run the projects concurrently, take a look at this answer. Basically, you'll need to configure the port in one (or both) of the projects' pom.xml so that the ports in the Jetty Maven plugin don't conflict.
If you only want to run one project at a time, just be sure to stop the Eclipse debugger before starting the next by clicking on the red "stop" button . When I forget to do this, I just kill the corresponding java processes.
Upvotes: 1