Erro na configuracao do spring com o intelij

1 resposta
spring
R

Ao tentar rodar a aplicacao pela primeira vez é me apresentado esse erro : ***************************
APPLICATION FAILED TO START


Description:

The Tomcat connector configured to listen on port 8080 failed to start. The port may already be in use or the connector may be misconfigured.

Action:

Verify the connector’s configuration, identify and stop any process that’s listening on port 8080, or configure this application to listen on another port.

2018-07-03 17:47:11.256 INFO 11059 — [ main] ationConfigEmbeddedWebApplicationContext : Closing org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext@6e2c9341: startup date [Tue Jul 03 17:46:59 BRT 2018]; root of context hierarchy
2018-07-03 17:47:11.264 INFO 11059 — [ main] o.s.j.e.a.AnnotationMBeanExporter : Unregistering JMX-exposed beans on shutdown

Process finished with exit code 1
poderiam me ajudar? qual arquivo mecher para alterar a porta?

1 Resposta

darlan_machado

O problema não está na configuração do Spring, está no fato de você já ter outra coisa rodando na porta 8080.
Se usa oracle XE, provavelmente seja ele o vilão.
Você só precisa alterar a porta do server, no application.properties, adicione a seguinte linha

server.port=9999

E você rodará o teu server embebed na porta 9999, altere a teu gosto, lembrando sempre de não ser uma porta em uso (8080, por exemplo) ou portas do sistema. Em geral, portas acima da 8000 estão livres.

Criado 3 de julho de 2018
Ultima resposta 4 de jul. de 2018
Respostas 1
Participantes 2