0

Im new to spring application development.

How can i run my application while developing stage at tomcat server.

here i can see that the solution for final deployment. i just need to change some on ui every time i need to stop and start again. it kills me. So can you please help me her ??

my pom.xml dependencies are

org.springframework spring-binding 1.0.6

<dependency>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-data-rest</artifactId>
</dependency>

<dependency>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-web</artifactId>
</dependency>

<dependency>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-test</artifactId>
    <scope>test</scope>
</dependency>

<dependency>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-thymeleaf</artifactId>
</dependency>
Pranav MS
  • 2,235
  • 2
  • 23
  • 50

2 Answers2

2

Add devtools dependency to your project.

<dependency>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-devtools</artifactId>
</dependency>

Whenever files change in the classpath, applications using spring-boot-devtools will cause the application to restart. The benefit of this feature is the time required to verify the changes made is considerably reduced.

sahoora
  • 245
  • 1
  • 5
  • The managed version is 2.1.1.RELEASE The artifact is managed in org.springframework.boot:spring-boot-dependencies:2.1.1.RELEASE this is the error that i am getting now – Pranav MS Mar 15 '19 at 11:35
  • Have you added spring-boot-starter-parent dependency to your project? org.springframework.boot spring-boot-starter-parent 2.1.1.RELEASE To get rid of this error you have add starter parent dependency. – sahoora Mar 15 '19 at 11:54
  • If you are using any third party dependency i.e. hibernate or camel, A safer way to use is to override Boot's dependency management. As you are using spring-boot-starter-parent as your pom's parent you can do that by overriding the version property. – sahoora Mar 15 '19 at 12:04
1

Create the application with maven install gol, generating a jar, run the jar on your server with> java -jar your_jar.jar

W GDJ
  • 36
  • 3