Skip to content

Demo Spring Boot application for the OLSS course

Notifications You must be signed in to change notification settings

pms967/olss-demo-app

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

35 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

OLSS demo application

Build & packaging

Manual build instructions

The build requires Java 11 sdk installed on your machine. To build, issue the following command:

$ ./mvnw package

Manual docker build instructions

A docker image for the app can be built using the following commands:

$ ./mvnw package
$ docker build --file docker/Dockerfile -t olss-demo-app .

Github actions build

See here.

Gitlab CI build

See here.

Demo app APIs

The OLSS provides a simple REST api described in this section.

Actuator API

GET /actuator/info

Returns information about the app (version, git commit id)

GET /actuator/health

Returns health status information

Hello API

GET /api/hello

Retutns a gentle hello from the API

Application state API

POST /api/application-state/refuse-traffic

Configures application so that traffic is refused, i.e. the readiness probe fails.

POST /api/application-state/accept-traffic

Configures application so that traffic is accepted, i.e. the readiness probe succeeds.

POST /api/application-state/break

Configures application so that liveness probe fails, i.e. the application is considered broken.

Memory Hog API

POST /api/memory/grow

Allocates a 10M heap chunk and returns the memory used by the memory hog.

POST /api/memory/clear

Clears the memory chunks and returns the memory used by the memory hog.

About

Demo Spring Boot application for the OLSS course

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Java 86.2%
  • Dockerfile 9.9%
  • Shell 3.9%