Skip to content

Latest commit

 

History

History

example-springboot

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 

Open Source Helpers

Spring Boot Example

Target of this module is to create a runable spring boot web application with the help of templates. A running copy you find in elasticobjects.org. The pages were a copy of a wordpress page.

The input files are not part of the fat jar to avoid the annoying build process when changing a semicolon. So to start the application one not just use "java -jar example-springboot/target/example-springboot-0.7.0
.jar"

Start

Instead with linux you have to start with

java -cp example-springboot/target/example-springboot-0.9.5.jar:example-springboot/input/ org.springframework.boot.loader.PropertiesLauncher

Or with windows use ";" instead of ":" as separator

java -cp example-springboot/target/example-springboot-0.9.5.jar;example-springboot/input/ org.springframework.boot.loader.PropertiesLauncher

Useed Modules

It uses configurations from the modules

The starting point is the
Start class.

The pages uses path parameters so the links are pure HTML links. The spring boot example is mostly a tool to navigate through the used configurations.

Web Controller

There are two Web-Controller classes defined.

  • WebEo defines two generic post end points
  • WebEoGet defines three special get end points using the path parameter to create an EO template call.

ConfigController

The configurations are loaded in the EOConfigCached.java as a singleton.

Templates

Page Templates

There are thre templates defined for rendering the page

Content Templates

The content will be loaded as a template within the Content.tpl from

Template Parts

Three part are loaded straigtforward:

The Svg.html for the responsiveness of the example site will be loaded as a file without parsing content.