1

I have been asked to combine two different Eclipse Java projects in Spring Boot so that they spit out results at the same address with different ports, eg:

localhost:19999/service/{yourRequest}
localhost:20000/service/{yourRequest}

Thus far I have been able to find zero documentation on it...probably because it's so much easier to just do it in two projects.

Anyone have any idea how to do this?

Bosko Mijin
  • 3,287
  • 3
  • 32
  • 45
kickpuncher11
  • 188
  • 2
  • 10
  • Ok. Currently I have two different Spring Boot projects in eclipse that return information when you visit their endpoints. I want to put them both in one project, with the same functionality. I know I can set the port in application.properties for 1 program, but I don't know how to set it for two different ports using two different programs in the same project. – kickpuncher11 Apr 10 '14 at 12:59
  • Are they the same application? Or two different applications (different codebase and configuration)? – Dave Syer Apr 10 '14 at 13:15
  • They're different. They both connect to Mongo, but select different databases and return JSON in different formats. – kickpuncher11 Apr 10 '14 at 13:19
  • 2
    You actually answered a similar question that *i believe* would solve my problem. http://stackoverflow.com/questions/21630820/configure-multiple-servletcontainers-servlets-with-spring-boot I just had no idea how to implement it – kickpuncher11 Apr 10 '14 at 13:39
  • That answer might work. Do you need both apps to run in the same process, or in the same Spring ApplicationContext? If the answer to either of those was "no" then it's easier just to launch two separate apps. – Dave Syer Apr 10 '14 at 14:09
  • I don't. But my team lead just told me that he mixed himself up...thought I was working with Mule, rather than Spring Boot. Sorry for the mixup, and thank you for responding. – kickpuncher11 Apr 10 '14 at 14:14

0 Answers0