com.sun.enterprise.config.serverbeans
Interface Cluster

All Superinterfaces:
org.jvnet.hk2.config.ConfigBeanProxy, org.jvnet.hk2.component.Injectable, Named, javax.validation.Payload, org.jvnet.hk2.config.types.PropertyBag, RefContainer, ReferenceContainer, SystemPropertyBag

@ConfigRefConstraint(message="{configref.invalid}",
                     payload=ConfigRefValidator.class)
public interface Cluster
extends org.jvnet.hk2.config.ConfigBeanProxy, org.jvnet.hk2.component.Injectable, org.jvnet.hk2.config.types.PropertyBag, Named, SystemPropertyBag, ReferenceContainer, RefContainer, javax.validation.Payload

A cluster defines a homogeneous set of server instances that share the same applications, resources, and configuration.


Nested Class Summary
static class Cluster.Decorator
           
static class Cluster.DeleteDecorator
           
static class Cluster.Duck
           
 
Method Summary
 void createResourceRef(java.lang.String enabled, java.lang.String refName)
           
 void deleteResourceRef(java.lang.String refName)
           
 ApplicationRef getApplicationRef(java.lang.String appName)
           
 java.lang.String getBroadcast()
          Gets the value of the broadcast property.
 java.lang.String getConfigRef()
          points to a named config.
 java.lang.String getGmsBindInterfaceAddress()
          Gets the value of the gmsBindInterfaceAddress property.
 java.lang.String getGmsEnabled()
          Gets the value of the gmsEnabled property.
 java.lang.String getGmsMulticastAddress()
          Gets the value of the gmsMulticastAddress property.
 java.lang.String getGmsMulticastPort()
          Gets the value of the gmsMulticastPort property.
 java.lang.String getHeartbeatAddress()
          Deprecated. 
 java.lang.String getHeartbeatEnabled()
          Deprecated. 
 java.lang.String getHeartbeatPort()
          Deprecated. 
 java.util.List<Server> getInstances()
           
 java.lang.String getName()
           
 java.util.List<org.jvnet.hk2.config.types.Property> getProperty()
          Properties as per PropertyBag
 java.lang.String getReference()
          Returns the cluster configuration reference
 ResourceRef getResourceRef(java.lang.String refName)
           
 java.util.List<ServerRef> getServerRef()
          Gets the value of the serverRef property.
 ServerRef getServerRefByRef(java.lang.String ref)
           
 java.util.List<SystemProperty> getSystemProperty()
          Gets the value of the systemProperty property.
 boolean isCluster()
           
 boolean isDas()
           
 boolean isInstance()
           
 boolean isResourceRefExists(java.lang.String refName)
           
 boolean isServer()
           
 void setBroadcast(java.lang.String value)
          Sets the value of the broadcast property.
 void setConfigRef(java.lang.String value)
          Sets the value of the configRef property.
 void setGmsBindInterfaceAddress(java.lang.String value)
          Sets the value of the gmsBindInterfaceAddress property.
 void setGmsEnabled(java.lang.String value)
          Sets the value of the gmsEnabled property.
 void setGmsMulticastAddress(java.lang.String value)
          Sets the value of the gmsMulticastAddress property.
 void setGmsMulticastPort(java.lang.String value)
          Sets the value of the gmsMulticastPort property.
 void setHeartbeatAddress(java.lang.String value)
          Deprecated. 
 void setHeartbeatEnabled(java.lang.String value)
          Deprecated. 
 void setHeartbeatPort(java.lang.String value)
          Deprecated. 
 void setName(java.lang.String value)
          Sets the cluster name
 
Methods inherited from interface org.jvnet.hk2.component.Injectable
injectedInto
 
Methods inherited from interface org.jvnet.hk2.config.types.PropertyBag
getProperty, getPropertyValue, getPropertyValue
 
Methods inherited from interface com.sun.enterprise.config.serverbeans.SystemPropertyBag
containsProperty, getPropertyValue, getSystemProperty, getSystemPropertyValue
 
Methods inherited from interface com.sun.enterprise.config.serverbeans.RefContainer
getApplicationRef, getResourceRef
 
Methods inherited from interface org.jvnet.hk2.config.ConfigBeanProxy
createChild, deepCopy, getParent, getParent
 

Method Detail

setName

void setName(java.lang.String value)
             throws java.beans.PropertyVetoException
Sets the cluster name

Specified by:
setName in interface Named
Parameters:
value - cluster name
Throws:
java.beans.PropertyVetoException - if a listener vetoes the change

getName

@Pattern(regexp="[A-Za-z0-9_][A-Za-z0-9\\-_\\.;]*",
         message="{cluster.invalid.name}",
         payload=Cluster.class)
java.lang.String getName()
Specified by:
getName in interface Named

getConfigRef

@NotNull
@Pattern(regexp="[A-Za-z0-9_][A-Za-z0-9\\-_\\.;]*")
java.lang.String getConfigRef()
points to a named config. All server instances in the cluster will share this config.

Returns:
a named config name

setConfigRef

void setConfigRef(java.lang.String value)
                  throws java.beans.PropertyVetoException
Sets the value of the configRef property.

Parameters:
value - allowed object is String
Throws:
java.beans.PropertyVetoException - if a listener vetoes the change

getGmsEnabled

@NotNull
java.lang.String getGmsEnabled()
Gets the value of the gmsEnabled property. When "gms-enabled" is set to "true", the GMS services will be started as a lifecycle module in each the application server in the cluster.

Returns:
true | false as a string, null means false

setGmsEnabled

void setGmsEnabled(java.lang.String value)
                   throws java.beans.PropertyVetoException
Sets the value of the gmsEnabled property.

Parameters:
value - allowed object is String
Throws:
java.beans.PropertyVetoException - if a listener vetoes the change

getBroadcast

@NotNull
java.lang.String getBroadcast()
Gets the value of the broadcast property. When "broadcast" is set to default of "udpmulticast" and GmsMulticastPort GMSMulticastAddress are not set, then their values are generated. When "broadcast" is set to implied unicast using udp or tcp protocol, then the VIRUTAL_MUTLICAST_URI_LIST is generated for virtual broadcast over unicast mode.

Returns:
true | false as a string, null means false

setBroadcast

void setBroadcast(java.lang.String value)
                  throws java.beans.PropertyVetoException
Sets the value of the broadcast property.

Parameters:
value - allowed object is String
Throws:
java.beans.PropertyVetoException - if a listener vetoes the change

getGmsMulticastPort

@Min(value=2048L)
@Max(value=49151L)
java.lang.String getGmsMulticastPort()
Gets the value of the gmsMulticastPort property. This is the communication port GMS uses to listen for group events. This should be a valid port number.

Returns:
possible object is String

setGmsMulticastPort

void setGmsMulticastPort(java.lang.String value)
                         throws java.beans.PropertyVetoException
Sets the value of the gmsMulticastPort property.

Parameters:
value - allowed object is String
Throws:
java.beans.PropertyVetoException - if a listener vetoes the change

getGmsMulticastAddress

java.lang.String getGmsMulticastAddress()
Gets the value of the gmsMulticastAddress property. This is the address (only multicast supported) at which GMS will listen for group events. Must be unique for each cluster.

Returns:
possible object is String

setGmsMulticastAddress

void setGmsMulticastAddress(java.lang.String value)
                            throws java.beans.PropertyVetoException
Sets the value of the gmsMulticastAddress property.

Parameters:
value - allowed object is String
Throws:
java.beans.PropertyVetoException - if a listener vetoes the change

getGmsBindInterfaceAddress

java.lang.String getGmsBindInterfaceAddress()
Gets the value of the gmsBindInterfaceAddress property.

Returns:
possible object is String

setGmsBindInterfaceAddress

void setGmsBindInterfaceAddress(java.lang.String value)
                                throws java.beans.PropertyVetoException
Sets the value of the gmsBindInterfaceAddress property.

Parameters:
value - allowed object is String
Throws:
java.beans.PropertyVetoException - if a listener vetoes the change

getHeartbeatEnabled

@Deprecated
java.lang.String getHeartbeatEnabled()
Deprecated. 

Gets the value of the heartbeatEnabled property. When "heartbeat-enabled" is set to "true", the GMS services will be started as a lifecycle module in each the application server in the cluster.When "heartbeat-enabled" is set to "false", GMS will not be started and its services will be unavailable. Clusters should function albeit with reduced functionality.

Returns:
true | false as a string, null means false

setHeartbeatEnabled

@Deprecated
void setHeartbeatEnabled(java.lang.String value)
                         throws java.beans.PropertyVetoException
Deprecated. 

Sets the value of the heartbeatEnabled property.

Parameters:
value - allowed object is String
Throws:
java.beans.PropertyVetoException - if a listener vetoes the change

getHeartbeatPort

@Deprecated
java.lang.String getHeartbeatPort()
Deprecated. 

Gets the value of the heartbeatPort property. This is the communication port GMS uses to listen for group events. This should be a valid port number.

Returns:
possible object is String

setHeartbeatPort

@Deprecated
void setHeartbeatPort(java.lang.String value)
                      throws java.beans.PropertyVetoException
Deprecated. 

Sets the value of the heartbeatPort property.

Parameters:
value - allowed object is String
Throws:
java.beans.PropertyVetoException - if a listener vetoes the change

getHeartbeatAddress

@Deprecated
java.lang.String getHeartbeatAddress()
Deprecated. 

Gets the value of the heartbeatAddress property. This is the address (only multicast supported) at which GMS will listen for group events.

Returns:
possible object is String

setHeartbeatAddress

@Deprecated
void setHeartbeatAddress(java.lang.String value)
                         throws java.beans.PropertyVetoException
Deprecated. 

Sets the value of the heartbeatAddress property.

Parameters:
value - allowed object is String
Throws:
java.beans.PropertyVetoException - if a listener vetoes the change

getServerRef

java.util.List<ServerRef> getServerRef()
Gets the value of the serverRef property. List of servers in the cluster

Returns:
list of configured ServerRef

getSystemProperty

@ToDo(priority=IMPORTANT,
      details="Provide PropertyDesc for legal system props")
java.util.List<SystemProperty> getSystemProperty()
Gets the value of the systemProperty property.

This accessor method returns a reference to the live list, not a snapshot. Therefore any modification you make to the returned list will be present inside the JAXB object. This is why there is not a set method for the systemProperty property.

For example, to add a new item, do as follows:

    getSystemProperty().add(newItem);
 

Objects of the following type(s) are allowed in the list SystemProperty

Specified by:
getSystemProperty in interface SystemPropertyBag

getProperty

@ToDo(priority=IMPORTANT,
      details="Complete PropertyDesc for legal props")
@PropertiesDesc(props=@PropertyDesc(name="GMS_LISTENER_PORT",description="GMS listener port"))
java.util.List<org.jvnet.hk2.config.types.Property> getProperty()
Properties as per PropertyBag

Specified by:
getProperty in interface org.jvnet.hk2.config.types.PropertyBag

getReference

@DuckTyped
java.lang.String getReference()
Returns the cluster configuration reference

Specified by:
getReference in interface ReferenceContainer
Returns:
the config-ref attribute

getInstances

@DuckTyped
java.util.List<Server> getInstances()

getServerRefByRef

@DuckTyped
ServerRef getServerRefByRef(java.lang.String ref)

isCluster

@DuckTyped
boolean isCluster()
Specified by:
isCluster in interface ReferenceContainer

isServer

@DuckTyped
boolean isServer()
Specified by:
isServer in interface ReferenceContainer

isDas

@DuckTyped
boolean isDas()
Specified by:
isDas in interface ReferenceContainer

isInstance

@DuckTyped
boolean isInstance()
Specified by:
isInstance in interface ReferenceContainer

getApplicationRef

@DuckTyped
ApplicationRef getApplicationRef(java.lang.String appName)

getResourceRef

@DuckTyped
ResourceRef getResourceRef(java.lang.String refName)

isResourceRefExists

@DuckTyped
boolean isResourceRefExists(java.lang.String refName)

createResourceRef

@DuckTyped
void createResourceRef(java.lang.String enabled,
                                 java.lang.String refName)
                       throws org.jvnet.hk2.config.TransactionFailure
Throws:
org.jvnet.hk2.config.TransactionFailure

deleteResourceRef

@DuckTyped
void deleteResourceRef(java.lang.String refName)
                       throws org.jvnet.hk2.config.TransactionFailure
Throws:
org.jvnet.hk2.config.TransactionFailure


Copyright © 2012 GlassFish Community. All Rights Reserved.