Interface Cluster
-
- All Superinterfaces:
org.jvnet.hk2.config.ConfigBeanProxy,org.glassfish.api.admin.config.Named,jakarta.validation.Payload,org.jvnet.hk2.config.types.PropertyBag,RefContainer,org.glassfish.api.admin.config.ReferenceContainer,SystemPropertyBag
@ConfigRefConstraint(message="{configref.invalid}", payload=ConfigRefValidator.class) @ReferenceConstraint(skipDuringCreation=true, payload=Cluster.class) public interface Cluster extends org.jvnet.hk2.config.ConfigBeanProxy, org.jvnet.hk2.config.types.PropertyBag, org.glassfish.api.admin.config.Named, SystemPropertyBag, org.glassfish.api.admin.config.ReferenceContainer, RefContainer, jakarta.validation.Payload
A cluster defines a homogeneous set of server instances that share the same applications, resources, and configuration.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static classCluster.Decoratorstatic classCluster.DeleteDecoratorstatic classCluster.Duck
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description voidcreateResourceRef(String enabled, String refName)voiddeleteResourceRef(String refName)ApplicationRefgetApplicationRef(String appName)@NotNull StringgetBroadcast()Gets the value of the broadcast property.@NotNull @Pattern(regexp="[A-Za-z0-9_][A-Za-z0-9\\-_\\.;]*") StringgetConfigRef()points to a named config.List<ClusterExtension>getExtensions()<T extends ClusterExtension>
List<T>getExtensionsByType(Class<T> type)<T extends ClusterExtension>
TgetExtensionsByTypeAndName(Class<T> type, String name)StringgetGmsBindInterfaceAddress()Gets the value of the gmsBindInterfaceAddress property.@NotNull StringgetGmsEnabled()Gets the value of the gmsEnabled property.StringgetGmsMulticastAddress()Gets the value of the gmsMulticastAddress property.@Min(2048L) @Max(49151L) StringgetGmsMulticastPort()Gets the value of the gmsMulticastPort property.StringgetHeartbeatAddress()Deprecated.StringgetHeartbeatEnabled()Deprecated.StringgetHeartbeatPort()Deprecated.List<Server>getInstances()@Pattern(regexp="[A-Za-z0-9_][A-Za-z0-9\\-_\\.;]*",message="{cluster.invalid.name}",payload=Cluster.class) StringgetName()List<org.jvnet.hk2.config.types.Property>getProperty()Properties as perPropertyBagStringgetReference()Returns the cluster configuration referenceResourceRefgetResourceRef(String refName)List<ServerRef>getServerRef()Gets the value of the serverRef property.ServerRefgetServerRefByRef(String ref)List<SystemProperty>getSystemProperty()Gets the value of the systemProperty property.booleanisCluster()booleanisDas()booleanisInstance()booleanisResourceRefExists(String refName)booleanisServer()booleanisVirtual()voidsetBroadcast(String value)Sets the value of the broadcast property.voidsetConfigRef(String value)Sets the value of the configRef property.voidsetGmsBindInterfaceAddress(String value)Sets the value of the gmsBindInterfaceAddress property.voidsetGmsEnabled(String value)Sets the value of the gmsEnabled property.voidsetGmsMulticastAddress(String value)Sets the value of the gmsMulticastAddress property.voidsetGmsMulticastPort(String value)Sets the value of the gmsMulticastPort property.voidsetHeartbeatAddress(String value)Deprecated.voidsetHeartbeatEnabled(String value)Deprecated.voidsetHeartbeatPort(String value)Deprecated.voidsetName(String value)Sets the cluster name-
Methods inherited from interface org.jvnet.hk2.config.ConfigBeanProxy
createChild, deepCopy, getParent, getParent
-
Methods inherited from interface org.jvnet.hk2.config.types.PropertyBag
addProperty, getProperty, getPropertyValue, getPropertyValue, lookupProperty, removeProperty, removeProperty
-
Methods inherited from interface com.sun.enterprise.config.serverbeans.RefContainer
getApplicationRef, getResourceRef
-
Methods inherited from interface com.sun.enterprise.config.serverbeans.SystemPropertyBag
containsProperty, getPropertyValue, getSystemProperty, getSystemPropertyValue
-
-
-
-
Method Detail
-
setName
void setName(String value) throws PropertyVetoException
Sets the cluster name- Specified by:
setNamein interfaceorg.glassfish.api.admin.config.Named- Parameters:
value- cluster name- Throws:
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) @Pattern(regexp="[A-Za-z0-9_][A-Za-z0-9\\-_\\.;]*",message="{cluster.invalid.name}",payload=Cluster.class) String getName()- Specified by:
getNamein interfaceorg.glassfish.api.admin.config.Named
-
getConfigRef
@NotNull @Pattern(regexp="[A-Za-z0-9_][A-Za-z0-9\\-_\\.;]*") @RemoteKey(message="{resourceref.invalid.configref}", type=Config.class) @NotNull @Pattern(regexp="[A-Za-z0-9_][A-Za-z0-9\\-_\\.;]*") 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(String value) throws PropertyVetoException
Sets the value of the configRef property.- Parameters:
value- allowed object isString- Throws:
PropertyVetoException- if a listener vetoes the change
-
getGmsEnabled
@NotNull @NotNull 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(String value) throws PropertyVetoException
Sets the value of the gmsEnabled property.- Parameters:
value- allowed object isString- Throws:
PropertyVetoException- if a listener vetoes the change
-
getBroadcast
@NotNull @NotNull 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(String value) throws PropertyVetoException
Sets the value of the broadcast property.- Parameters:
value- allowed object isString- Throws:
PropertyVetoException- if a listener vetoes the change
-
getGmsMulticastPort
@Min(2048L) @Max(49151L) @Min(2048L) @Max(49151L) 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(String value) throws PropertyVetoException
Sets the value of the gmsMulticastPort property.- Parameters:
value- allowed object isString- Throws:
PropertyVetoException- if a listener vetoes the change
-
getGmsMulticastAddress
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(String value) throws PropertyVetoException
Sets the value of the gmsMulticastAddress property.- Parameters:
value- allowed object isString- Throws:
PropertyVetoException- if a listener vetoes the change
-
getGmsBindInterfaceAddress
String getGmsBindInterfaceAddress()
Gets the value of the gmsBindInterfaceAddress property.- Returns:
- possible object is
String
-
setGmsBindInterfaceAddress
void setGmsBindInterfaceAddress(String value) throws PropertyVetoException
Sets the value of the gmsBindInterfaceAddress property.- Parameters:
value- allowed object isString- Throws:
PropertyVetoException- if a listener vetoes the change
-
getHeartbeatEnabled
@Deprecated 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(String value) throws PropertyVetoException
Deprecated.Sets the value of the heartbeatEnabled property.- Parameters:
value- allowed object isString- Throws:
PropertyVetoException- if a listener vetoes the change
-
getHeartbeatPort
@Deprecated 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(String value) throws PropertyVetoException
Deprecated.Sets the value of the heartbeatPort property.- Parameters:
value- allowed object isString- Throws:
PropertyVetoException- if a listener vetoes the change
-
getHeartbeatAddress
@Deprecated 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(String value) throws PropertyVetoException
Deprecated.Sets the value of the heartbeatAddress property.- Parameters:
value- allowed object isString- Throws:
PropertyVetoException- if a listener vetoes the change
-
getServerRef
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") 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 asetmethod 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 listSystemProperty- Specified by:
getSystemPropertyin interfaceSystemPropertyBag
-
getProperty
@ToDo(priority=IMPORTANT, details="Complete PropertyDesc for legal props") @PropertiesDesc(props=@PropertyDesc(name="GMS_LISTENER_PORT",defaultValue="9090",description="GMS listener port")) List<org.jvnet.hk2.config.types.Property> getProperty()Properties as perPropertyBag- Specified by:
getPropertyin interfaceorg.jvnet.hk2.config.types.PropertyBag
-
getExtensions
List<ClusterExtension> getExtensions()
-
getReference
@DuckTyped String getReference()
Returns the cluster configuration reference- Specified by:
getReferencein interfaceorg.glassfish.api.admin.config.ReferenceContainer- Returns:
- the config-ref attribute
-
isCluster
@DuckTyped boolean isCluster()
- Specified by:
isClusterin interfaceorg.glassfish.api.admin.config.ReferenceContainer
-
isServer
@DuckTyped boolean isServer()
- Specified by:
isServerin interfaceorg.glassfish.api.admin.config.ReferenceContainer
-
isDas
@DuckTyped boolean isDas()
- Specified by:
isDasin interfaceorg.glassfish.api.admin.config.ReferenceContainer
-
isInstance
@DuckTyped boolean isInstance()
- Specified by:
isInstancein interfaceorg.glassfish.api.admin.config.ReferenceContainer
-
isVirtual
@DuckTyped boolean isVirtual()
-
getApplicationRef
@DuckTyped ApplicationRef getApplicationRef(String appName)
-
getResourceRef
@DuckTyped ResourceRef getResourceRef(String refName)
-
isResourceRefExists
@DuckTyped boolean isResourceRefExists(String refName)
-
createResourceRef
@DuckTyped void createResourceRef(String enabled, String refName) throws org.jvnet.hk2.config.TransactionFailure
- Throws:
org.jvnet.hk2.config.TransactionFailure
-
deleteResourceRef
@DuckTyped void deleteResourceRef(String refName) throws org.jvnet.hk2.config.TransactionFailure
- Throws:
org.jvnet.hk2.config.TransactionFailure
-
getExtensionsByType
@DuckTyped <T extends ClusterExtension> List<T> getExtensionsByType(Class<T> type)
-
getExtensionsByTypeAndName
@DuckTyped <T extends ClusterExtension> T getExtensionsByTypeAndName(Class<T> type, String name)
-
-