Application Type - Jvm
JVM Application is a application that can run jvm processes. Because Onteon knows the type of the process, it can automatically do some actions like resize the memory on errors or create thread and memory dumps for later analyzing. You need to specify start command and executable file, which could be a jar file.
Example configuration
app:
name: 'java-application'
version: '1.0.0'
appType: 'standard'
procType: 'native'
processProvider:
name: 'JVMOsProcessProviderImpl'
version: '1.0.0'
executable:
start:
path: '${ont_app_path}/bin'
startJvmCommand: 'java -jar -Dserver.port=${ont_port_1}'
executableFileName: 'app.jar'
sysParams: null
mainClass: null
mainFunctionArgs: null
successLine: 'Spring Boot properly started'
makeActionOnMemoryOverflow: true
maxActionOnMemoryOverflow: 5
increasePercentageOnMemoryOverflow: 20
xms: 128M
xmx: 256M
cpus: null
memory: null
placeHolder:
name: 'PlaceHolderManagerImpl'
version: '1.0.0'
filesToReplace: []
variables: {}
serviceRepository:
healthCheckUrl: 'http://${address}:${ont_port_1}'
entities:
- entity:
priority: 1
port: ${ont_port_1}
protocol:
type: 'HTTP'
version: '1.1'
isExternal: true
isInternal: true
Configuration keys
app.name
Name of application.
app:
name: 'application-name'
app.version
Version of application.
app:
version: '1.0.0'
app.type
Application type. It should be set to standard
.
Possible values:
- standard - Standard application.
- embedded - Application used for internal purposes, such as edge balancer.
- unknown - Unknown application.
app:
appType: 'standard'
app.procType
Process type. It should be set to native
.
Possible values:
- native - Native application.
- docker - Docker application.
- unknown - Unknown application.
app:
procType: 'native'
app.processProvider.name
Name of process provider. It should be set to JVMOsProcessProviderImpl
.
Possible values:
- GenericOsProcessProviderImpl - for native processes.
- JVMOsProcessProviderImpl - for native JVM processes.
- DockerOsProcessProviderImpl - for docker processes.
app:
processProvider:
name: 'JVMOsProcessProviderImpl'
app.processProvider.version
Version of process provider. It should be set to 1.0.0
.
app:
processProvider:
version: '1.0.0'
app.processProvider.version.executable.start.path
Path to directory with executable.
app:
processProvider:
executable:
start:
path: '${ont_app_path}/bin'
app.processProvider.version.executable.start.startJvmCommand
Command to start JVM process.
app:
processProvider:
executable:
start:
startJvmCommand: 'java -jar -Dserver.port=${ont_port_1}'
app.processProvider.version.executable.start.executableFileName
Name of the archive with classes.
app:
processProvider:
executable:
start:
executableFileName: 'app.jar'
app.processProvider.version.executable.start.mainClass
Main Class to be used.
app:
processProvider:
executable:
start:
mainClass: null
app.processProvider.version.executable.start.sysParams
System params to add to command.
app:
processProvider:
executable:
start:
sysParams: null
app.processProvider.version.executable.start.mainFunctionArgs
Arguments for main function.
app:
processProvider:
executable:
start:
mainFunctionArgs: null
app.processProvider.version.executable.start.successLine
Log line that will determine that the application has started. If you do not specify success line, Onteon node will wait 90 seconds. Wait time can be changed here.
app:
processProvider:
executable:
start:
successLine: 'Application started...'
app.processProvider.version.executable.start.makeActionOnMemoryOverflow
Flag to configure if any action should be executed when memory overflow error occurrs.
app:
processProvider:
executable:
start:
makeActionOnMemoryOverflow: true
app.processProvider.version.executable.start.maxActionOnMemoryOverflow
How many times action should be executed.
app:
processProvider:
executable:
start:
maxActionOnMemoryOverflow: 5
app.processProvider.version.executable.start.increasePercentageOnMemoryOverflow
How much more (in terms of percentage) memory should be assigned for process.
app:
processProvider:
executable:
start:
increasePercentageOnMemoryOverflow: 20
app.processProvider.version.executable.start.xms
Value of JVM parameter xms
.
app:
processProvider:
executable:
start:
xms: 128M
app.processProvider.version.executable.start.xmx
Value of JVM parameter xmx
.
app:
processProvider:
executable:
start:
xmx: 256M
app.processProvider.version.executable.start.cpus
CPUs limit for process.
app:
processProvider:
executable:
start:
cpus: null
app.processProvider.version.executable.start.memory
Memory limit for process.
app:
processProvider:
executable:
start:
memory: null
app.placeHolder.name
Placeholder name.
app:
placeHolder:
name: 'PlaceHolderManagerImpl'
app.placeHolder.version
Placeholder version.
app:
placeHolder:
version: '1.0.0'
app.placeHolder.filesToReplace
List of files that will have placeholder replaced.
app:
placeHolder:
filesToReplace: []
app.placeHolder.variables
Placeholders variables in key-value format.
app:
placeHolder:
variables: {}
app.serviceRepository.healthCheckUrl
Url that will determine if application is alive.
app:
serviceRepository:
healthCheckUrl: 'http://${address}:${ont_port_1}/isAlive/'
app.serviceRepository.entities
List of service repository entities.
app:
serviceRepository:
entities:
- entity:
priority: 1
port: ${ont_port_1} # entity port
protocol:
type: 'HTTP' # entity protocol
version: '1.1' # entity protocol version
isExternal: true # if true, application will be available in edge balancer
isInternal: true # if true, application will be available in inner balancer