Difference between revisions of "SpringBoot"

Line 39: Line 39:
  
 
to get latest Spring Boot Web Starter pom.xml configurations visit : [https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-web https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-web]
 
to get latest Spring Boot Web Starter pom.xml configurations visit : [https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-web https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-web]
 +
 +
 +
==SpringBoot - Application Boot==
 +
Spring Boot application startup class :
 +
 +
<source>
 +
package com.oasissofttech.springboot;
 +
 +
import org.springframework.boot.SpringApplication;
 +
import org.springframework.boot.autoconfigure.SpringBootApplication;
 +
 +
@SpringBootApplication
 +
public class SpringBootTutorial1App {
 +
public static void main(String[] args) {
 +
SpringApplication.run(SpringBootTutorial1App.class,args);
 +
}
 +
}
 +
</source>

Revision as of 07:43, 3 June 2018


SpringBoot - Maven - Pom.xml

<project xmlns="http://maven.apache.org/POM/4.0.0"
	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
	xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
	<modelVersion>4.0.0</modelVersion>
	<groupId>com.oasissoftech.springboot</groupId>
	<artifactId>SpringBoot-Tutorial-1</artifactId>
	<version>0.0.1-SNAPSHOT</version>
	<name>SpringBoot-Tutorial-1</name>

	<parent>
		<groupId>org.springframework.boot</groupId>
		<artifactId>spring-boot-starter-parent</artifactId>
		<version>2.0.2.RELEASE</version>
	</parent>

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

	<properties>
		<java.version>1.8</java.version>
	</properties>

</project>

to get latest Spring Boot Starter Parent pom.xml configurations visit : https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-parent

to get latest Spring Boot Web Starter pom.xml configurations visit : https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-web


SpringBoot - Application Boot

Spring Boot application startup class :

package com.oasissofttech.springboot;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

@SpringBootApplication
public class SpringBootTutorial1App {
	public static void main(String[] args) {
		SpringApplication.run(SpringBootTutorial1App.class,args);
	}
}