Skip to content

Example template for Java Spring boot microservice architecture project

Notifications You must be signed in to change notification settings

dfesalbon-java/microservice-architecture

 
 

Repository files navigation

Microservice Architecture using Spring Boot

Sample Java Spring Boot microservice architecture markdown guide.

Architecture Diagram

alt text

Follow these instructions to get each applications/services running:

INITIAL SET UP..

  • Go to/open the config-profiles folder.
  • Open terminal or bash.
  • Initialize git by running these commands
git init
git add .
git commit -m "sample commit"

alt text

STARTING SERVICE REGISTRY..

  • Go to/open the config service folder. Either in Eclipse or a terminal.
  • Please make sure that the config.server.git.uri is config-profiles folder directory alt text
  • Start the application. (Eclipse) -> Run as Spring boot (I have this for mine)
  • Start the application. (Maven) -> Please see maven documentations.
  • Go to/open the eureka registry folder. Either in Eclipse or a terminal.
  • Same with previous steps -> Start the application (Eclipse or Maven)
  • Visit http://localhost:8001 on your browser

alt text

You should see something like the picture above

SETTING UP GATEWAY..

  • Go to/open the zuul gateway folder. Either in Eclipse or a terminal.
  • Same with previous steps -> Start the application (Eclipse or Maven)

alt text

You should see something like the picture above

STARTING SAMPLE APPLICATION/SERVICE..

  • Go to/open the user-service folder. Either in Eclipse or a terminal.
  • Same with previous steps -> Start the application (Eclipse or Maven)

alt text

You should see something like the picture above

STARTING ANOTHER SAMPLE APPLICATION/SERVICE..

  • Go to/open the group-service folder. Either in Eclipse or a terminal.
  • Same with previous steps -> Start the application (Eclipse or Maven)

alt text

You should see something like the picture above

After all steps are followed, visiting http://localhost:8001 should be something like this:

alt text

Note:

Properties (ports, routes) of each application could be found and modified on the centralized cloud configuration repository (config-profiles folder)

Configuration Profiles Diagram

alt text

After all that, you may test it on POSTMAN. Thanks.

About

Example template for Java Spring boot microservice architecture project

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Java 100.0%