public abstract class ProcessEnvironment extends Object
Modifier and Type | Field and Description |
---|---|
static String |
JBOSS_DOMAIN_UUID
The special process name value that triggers calculation of a UUID
|
static AttributeDefinition |
NAME
AttributeDefinition for the name attribute for a processes root resource |
Constructor and Description |
---|
ProcessEnvironment() |
Modifier and Type | Method and Description |
---|---|
protected abstract String |
getProcessName()
Gets the resolved name of this process; a value previously passed to
setProcessName(String) or
a value derived from the environment. |
OperationStepHandler |
getProcessNameReadHandler()
Gets an
OperationStepHandler that can read the name attribute for a processes root resource |
OperationStepHandler |
getProcessNameWriteHandler()
Gets an
OperationStepHandler that can write the name attribute for a processes root resource |
protected abstract boolean |
isRuntimeSystemPropertyUpdateAllowed(String propertyName,
String propertyValue,
boolean bootTime)
Gets whether updating the runtime system properties with the given property is allowed.
|
protected static String |
resolveGUID(String unresolvedName) |
protected abstract void |
setProcessName(String processName)
Sets the process name.
|
protected abstract void |
systemPropertyUpdated(String propertyName,
String propertyValue)
Notifies this
ProcessEnvironment that the runtime value of the given system property has been updated,
allowing it to update any state that was originally set via the system property during primordial process boot. |
public static final String JBOSS_DOMAIN_UUID
public static final AttributeDefinition NAME
AttributeDefinition
for the name
attribute for a processes root resourcepublic OperationStepHandler getProcessNameReadHandler()
OperationStepHandler
that can read the name
attribute for a processes root resourcepublic OperationStepHandler getProcessNameWriteHandler()
OperationStepHandler
that can write the name
attribute for a processes root resourceprotected abstract String getProcessName()
setProcessName(String)
or
a value derived from the environment.null
protected abstract void setProcessName(String processName)
getProcessNameWriteHandler()
; its visibility is protected only because subclasses need to implement it.processName
- the process name. May be null
in which case a default process name should be used.protected abstract boolean isRuntimeSystemPropertyUpdateAllowed(String propertyName, String propertyValue, boolean bootTime) throws OperationFailedException
propertyName
- the name of the property. Cannot be null
propertyValue
- the value of the property. May be null
bootTime
- true
if the process is currently bootingtrue
if the update can be applied to the runtime system properties; false if it
should just be stored in the persistent configuration and the process should be put into
reload-required state
.OperationFailedException
- if a change to the given property is not allowed at all; e.g. changing
jboss.server.base.dir
after primordial boot is not allowed; the
property can only be set from the command lineprotected abstract void systemPropertyUpdated(String propertyName, String propertyValue)
ProcessEnvironment
that the runtime value of the given system property has been updated,
allowing it to update any state that was originally set via the system property during primordial process boot.
This method should only be invoked after a call to isRuntimeSystemPropertyUpdateAllowed(String, String, boolean)
has returned true
.propertyName
- the name of the property. Cannot be null
propertyValue
- the value of the property. May be null
Copyright © 2015 JBoss by Red Hat. All rights reserved.