|
Brooklyn | |||||||
FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | PROPERTY | CONSTR | METHOD | DETAIL: FIELD | PROPERTY | CONSTR | METHOD |
java.lang.Objectbrooklyn.entity.basic.AbstractSoftwareProcessDriver
brooklyn.entity.basic.AbstractSoftwareProcessSshDriver
brooklyn.entity.basic.lifecycle.legacy.SshBasedAppSetup
brooklyn.entity.basic.lifecycle.legacy.SshBasedJavaAppSetup
@Deprecated abstract class SshBasedJavaAppSetup extends SshBasedAppSetup
Java application installation, configuration and startup using ssh. This class should be extended for use by entities that are implemented by a Java application. TODO complete documentation
Field Summary | |
---|---|
protected java.util.Map |
environmentPropertyFiles
|
protected int |
jmxPort
|
protected java.util.Map |
namedPropertyFiles
|
protected int |
rmiPort
|
Fields inherited from class SshBasedAppSetup | |
---|---|
log |
Fields inherited from class AbstractSoftwareProcessSshDriver | |
---|---|
BROOKLYN_HOME_DIR, CHECK_RUNNING, CUSTOMIZING, DEFAULT_INSTALL_BASEDIR, DEFAULT_RUN_BASEDIR, INSTALLING, KILLING, LAUNCHING, NO_VERSION_INFO, PID_FILENAME, RESTARTING, STOPPING, log, logSsh |
Fields inherited from class AbstractSoftwareProcessDriver | |
---|---|
entity |
Property Summary | |
---|---|
static Logger |
log
|
Constructor Summary | |
SshBasedJavaAppSetup(EntityLocal entity, SshMachineLocation machine)
|
Method Summary | |
---|---|
void
|
config()
|
protected java.util.List
|
getCustomJavaConfigOptions()
Return extra Java config options, ie arguments starting with - which are passed to the JVM prior to the class name. |
protected java.util.Map
|
getCustomJavaSystemProperties()
Return extra Java system properties (-D defines) used by the application. |
java.util.List
|
getJavaOpts()
arguments to pass to the JVM; this is the config options (e.g. |
protected java.util.Map
|
getJavaSystemProperties()
Returns the complete set of Java system properties (-D defines) to set for the application. |
protected java.util.Map
|
getJmxJavaSystemProperties()
Return the configuration properties required to enable JMX for a Java application. |
java.util.Map
|
getShellEnvironment()
Sets all JVM options (-X.. |
boolean
|
isJmxEnabled()
|
protected void
|
setEntityAttributes()
|
void
|
setEnvironmentPropertyFiles(java.util.Map propertyFiles)
|
void
|
setJmxPort(int val)
|
void
|
setNamedPropertyFiles(java.util.Map propertyFiles)
|
void
|
setRmiPort(int val)
|
Methods inherited from class AbstractSoftwareProcessSshDriver | |
---|---|
copyFile, copyFile, execute, execute, getDefaultVersion, getEntityVersionLabel, getEntityVersionLabel, getHostname, getInstallDir, getLocation, getMachine, getPortsUsed, getRunDir, getShellEnvironment, getVersion, newScript, newScript |
Methods inherited from class AbstractSoftwareProcessDriver | |
---|---|
customize, getEntity, getLocation, getResource, install, kill, launch, postLaunch, restart, start, stop, waitForConfigKey |
Field Detail |
---|
protected java.util.Map environmentPropertyFiles
protected int jmxPort
protected java.util.Map namedPropertyFiles
protected int rmiPort
Property Detail |
---|
static final Logger log
Constructor Detail |
---|
SshBasedJavaAppSetup(EntityLocal entity, SshMachineLocation machine)
Method Detail |
---|
@Override void config()
protected java.util.List getCustomJavaConfigOptions()
Note defines are handled separately, in getCustomJavaSystemProperties().
Override as needed; default is an empty list.
protected java.util.Map getCustomJavaSystemProperties()
java.util.List getJavaOpts()
See getShellEnvironment() for discussion of quoting/escaping strategy.
protected java.util.Map getJavaSystemProperties()
This is exposed to the JVM as the contents of the JAVA_OPTS environment variable. Default set contains config key, custom system properties, and JMX defines.
Null value means to set -Dkey otherwise it is -Dkey=value.
See getShellEnvironment() for discussion of quoting/escaping strategy.
protected java.util.Map getJmxJavaSystemProperties()
@Override java.util.Map getShellEnvironment()
All env vars are wrapped in double quotes when defined in the shell, so values in the resulting map can contain spaces, and must be valid bash expressions.
However variables such as JAVA_OPTS used by many scripts get passed as a string, not an array, so spaces in a single argument in the variable, say, a java system define, cannot be passed via this mechanism. We have tried a number of ways around this and conclusion is that the delegated scripts would have to be changed to allow this (treating JAVA_OPTS as an array, eg). If spaces are needed, raise a jira.
boolean isJmxEnabled()
@Override protected void setEntityAttributes()
void setEnvironmentPropertyFiles(java.util.Map propertyFiles)
void setJmxPort(int val)
void setNamedPropertyFiles(java.util.Map propertyFiles)
void setRmiPort(int val)
Brooklyn Multi-Cloud Application Management Platform
brooklyncentral.github.com. Apache License. © 2012.