项目作者: pramoddhone

项目描述 :
created for microservices based architecture skeleton
高级语言: Java
项目地址: git://github.com/pramoddhone/micro-sample-arch.git
创建时间: 2019-06-19T06:27:35Z
项目社区:https://github.com/pramoddhone/micro-sample-arch

开源协议:

下载


Sample microservice skeleton

You can reffered this project as a skeletion to start microservice. This skeletion is created using jhipster which will bi-default give many production ready tool

Getting Started

Please follow instruction to run it locally

Prerequisites

Make sure you have install following tool

  1. * jdk 8
  2. * choco installer (if you uses windows. With the help **choco** you can install following tools)
  3. * npm
  4. * jhipster
  5. * yarn
  6. * docker
  7. * mysql

Run each microservice by following command

  1. mvnw

Dealing with Eureka server

If you get Eureka server error while running microservice then there are two option 1. disable Eureka client or 2. setup Eureka Server

Disable Eureka Client

Go to application.yml to every microservice and disable following properties

  1. fetch-registry: false
  2. register-with-eureka: false

Setting up Eureka Server on your local

Clone the following project from github and run using following command

  1. git clone git@github.com:jhipster/jhipster-registry.git
  2. mvnw

You can access Eureka server by using URL http://localhost:8761/

Swagger Implementation

Swagger is implemented in this POC. You can see swagger documentation about REST API for each microservice in two ways

  1. 1 on Jhipster-registry project --> API section.
  2. 2 use URL **[MICROSERVICE_SERVICE_URL]/v2/api-docs**

Health URL

You can check health of particular microservice in two ways

  1. 1 On Jhispter registry
  2. 2 using URL **[MICROSERVICE_SERVICE_URL]management/health**

Information about microservice profile

You can check info of particular microservice in two ways

  1. 1 On Jhispter registry
  2. 2 using URL **[MICROSERVICE_SERVICE_URL]management/info**

Note : for this microservice we used MYSQL DB(Need to make it already installed) with username root and no password