Last active
June 30, 2019 07:29
-
-
Save sgaem/485c99054f95d6d89cc255270dae0d0e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import org.springframework.boot.SpringApplication; | |
import org.springframework.boot.autoconfigure.SpringBootApplication; | |
import org.springframework.boot.builder.SpringApplicationBuilder; | |
import org.springframework.boot.web.support.SpringBootServletInitializer; | |
import org.springframework.web.bind.annotation.GetMapping; | |
import org.springframework.web.bind.annotation.RequestMapping; | |
import org.springframework.web.bind.annotation.RestController; | |
@SpringBootApplication | |
public class SampleJbossApplication extends SpringBootServletInitializer { | |
@Override | |
protected SpringApplicationBuilder configure(SpringApplicationBuilder application) { | |
return application.sources(SampleJbossApplication.class); | |
} | |
public static void main(String[] args) { | |
SpringApplication.run(SampleJbossApplication.class, args); | |
} | |
@RestController | |
class HelloController { | |
@RequestMapping("/hello") | |
@GetMapping | |
String hello() { | |
return "Hello World " + " !"; | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment