diff --git a/pom.xml b/pom.xml index 0fd8f50..13525d6 100644 --- a/pom.xml +++ b/pom.xml @@ -9,7 +9,7 @@ RelatedItems Collector jar https://github.com/Hygieia/${repository.name} - 3.1.3-SNAPSHOT + 3.1.4-SNAPSHOT relatedItems-collector @@ -51,7 +51,7 @@ hygieia-relateditems-collector 0.13 3.0.1 - 3.1.15 + 3.7.8 2.4 3.8.1 4.3.0 diff --git a/src/main/java/com/capitalone/dashboard/Application.java b/src/main/java/com/capitalone/dashboard/Application.java index 9015643..2c2327e 100644 --- a/src/main/java/com/capitalone/dashboard/Application.java +++ b/src/main/java/com/capitalone/dashboard/Application.java @@ -1,18 +1,25 @@ package com.capitalone.dashboard; +import com.capitalone.dashboard.config.MongoConfig; +import com.capitalone.dashboard.config.RestApiAppConfig; +import com.capitalone.dashboard.config.WebMVCConfig; +import com.ulisesbocchio.jasyptspringboot.annotation.EnableEncryptableProperties; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; +import org.springframework.boot.builder.SpringApplicationBuilder; +import org.springframework.boot.context.web.SpringBootServletInitializer; /** - *

RelatedItemsCollector

- * This application helps to collect relatedItems data - *

- * - * @since 09/28/2018 + * Application configuration and bootstrap */ @SpringBootApplication -public class Application { +@EnableEncryptableProperties +public class Application extends SpringBootServletInitializer { + @Override + protected SpringApplicationBuilder configure(SpringApplicationBuilder application) { + return application.sources(Application.class, RestApiAppConfig.class, WebMVCConfig.class, MongoConfig.class); + } public static void main(String[] args) { SpringApplication.run(Application.class, args); } diff --git a/src/main/java/com/capitalone/dashboard/controller/PingController.java b/src/main/java/com/capitalone/dashboard/controller/PingController.java new file mode 100644 index 0000000..e109ba1 --- /dev/null +++ b/src/main/java/com/capitalone/dashboard/controller/PingController.java @@ -0,0 +1,25 @@ +package com.capitalone.dashboard.controller; + +import org.springframework.http.HttpStatus; +import org.springframework.http.ResponseEntity; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; + +import static org.springframework.http.MediaType.APPLICATION_JSON_VALUE; +import static org.springframework.web.bind.annotation.RequestMethod.GET; + +@RestController +public class PingController { + + public PingController() { + + } + + @RequestMapping(value = "/ping", method = GET, produces = APPLICATION_JSON_VALUE) + public ResponseEntity ping () { + return ResponseEntity + .status(HttpStatus.OK) + .body("hello ric"); + } + +}