Skip to content

The back-end for Ignio leveraged by spring boot microservices

Notifications You must be signed in to change notification settings

luk3Sky/Ignio-API

 
 

Repository files navigation

Ignio-API

The back-end for Ignio leveraged by spring boot microservices

Built With

  • Maven - Dependency Management
  • JDK - Java™ Platform, Standard Edition Development Kit
  • Spring Boot - Framework to ease the bootstrapping and development of new Spring Applications
  • MongoDB - Open-Source Relational Database Management System
  • git - Free and Open-Source distributed version control system
  • Prometheus - Monitoring system and time series database
  • Postman - API Development Environment (Testing Docmentation)

Task tracker

  • Service Discovery (Eureka)
  • Actuator
  • Logger (Console, File, Mail)
  • RESTful Web Service (CRUD) / Endpoints
  • HATEOS
  • Spring Boot Admin
  • MongoDB Integration
  • Micrometer
  • Grafna
  • Content Negotiation
  • Security
  • Dynamic API tokens
  • Docker configurations
  • Kubernetes deployment
  • Production Ops

Running the application locally

There are several ways to run a Spring Boot application on your local machine. One way is to execute the main method in each services for com.foxploit.ignio.<service>.<MainApplication> classes from your IDE.

  • Download the zip or clone the Git repository.
  • Unzip the zip file (if you downloaded one)
  • Open Command Prompt and Change directory (cd) to each service folders
  • Open Eclipse
    • File -> Import -> Existing Maven Project -> Navigate to the folder where you unzipped the zip
    • Select the project
  • Choose the Spring Boot Application file (search for @SpringBootApplication)
  • Right Click on the file and Run as Java Application

Alternatively you can use the Spring Boot Maven plugin like so:

  $ mvn spring-boot:run

Building the app

  $ mvn clean install

Documentation

Files and Directories [TODO]

The project (a.k.a. project directory) has a particular directory structure. A representative project is shown below:

.
├── Spring Elements
├── src
│   └── main
│       └── java
│           ├── com.arc.application
│           ├── com.arc.application.config
│           ├── com.arc.application.controller
│           ├── com.arc.application.exception
│           ├── com.arc.application.model
│           ├── com.arc.application.util
│           └── com.arc.application.repository
├── src
│   └── main
│       └── resources
│           └── static
│           │   ├── css
│           │   │   └── bootstrap.css
│           │   ├── images
│           │   ├── js
│           │   ├── favicon.ico
│           │   └── index.html
│           ├── templates
│           │   └── view.html
│           ├── application.properties
│           ├── banner.txt
│           └── log4j2.xml
├── src
│   └── test
│       └── java
├── JRE System Library
├── Maven Dependencies
├── bin
├── logs
│   └── application.log
├── src
├── target
│   └──application-0.0.1-SNAPSHOT
├── mvnw
├── mvnw.cmd
├── pom.xml
└── README.md

Services

  • gateway-server -- Provide route handling and proxy as a gateway to the microservices and UAA service
  • ignio-registry -- Provide service discovery of between microservices and registration
  • device-data-service -- Provide CRUD operations for device data and associated entities
  • device-analysis-service -- Provide analysis of the device data and provide real-time alerts

packages in each microservice

  • domain — to hold our entities;

  • repository — to communicate with the database;

  • service — to hold our business logic;

  • web.rest — to listen to the client and associated rest endpoints;

  • resources/ - Contains all the static resources, templates and property files.

  • resources/config - Contains all the configuration files.

  • resources/i18n - Contains message properties.

  • resources/static - contains static resources such as css, js and images.

  • resources/templates - contains server-side templates which are rendered by Spring.

  • resources/config/application.yml, application-dev.yml, application-prod.yml - Contains application-wide properties. Spring reads the properties defined in these files to configure the application including server’s default port, server’s context path, database URLs etc.

  • test/ - contains unit and integration tests

  • pom.xml - contains all the project dependencies

Resources

About

The back-end for Ignio leveraged by spring boot microservices

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Java 94.8%
  • HTML 4.8%
  • Other 0.4%