2
respostas

Problemas ao executar o jetty:run

Não estou conseguindo "rodar" o Jetty, ele da o seguinte erro:

[INFO] Started o.e.j.m.p.JettyWebAppContext@d2291de{/loja,file:///C:/Users/rafae/eclipse-workspace/lojaweb/src/main/webapp/,AVAILABLE}{file:///C:/Users/rafae/eclipse-workspace/lojaweb/src/main/webapp/} [INFO] Jetty server exiting. [INFO] ------------------------------------------------------------------------ [INFO] BUILD FAILURE [INFO] ------------------------------------------------------------------------ [INFO] Total time: 1.854 s [INFO] Finished at: 2019-03-22T11:59:54-03:00 [INFO] ------------------------------------------------------------------------ [ERROR] Failed to execute goal org.eclipse.jetty:jetty-maven-plugin:9.3.7.v20160115:run (default-cli) on project lojaweb: 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. [ERROR] [ERROR] For more information about the errors and possible solutions, please read the following articles: [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException

o meu codigo na configuração está assim:

lojaweb
    <plugins>
        <plugin>
            <groupId>org.eclipse.jetty</groupId>
            <artifactId>jetty-maven-plugin</artifactId>
            <version>9.3.7.v20160115</version>
            <configuration>
                <scanIntervalSeconds>10</scanIntervalSeconds>
                <webApp>
                    <contextPath>/loja</contextPath>
                </webApp>
            </configuration>
        </plugin>
    </plugins>
</build>

Eu utilizo o windows 10, será que é alguma configuração barrando a porta 8080?

2 respostas

O professor do curso podia responder!!!!!!!!!!!

Oi Rafael, tudo bem?

Pelo erro, a porta 8080 está sendo utilizada por algum outro processo.

Para trocar a porta do jetty, use esse comando:

mvn -Djetty.http.port=9999 jetty:run