|
GigaSpaces XAP 8.0 API | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface Machines
Machines hold all the different Machines that are currently
discovered.
Provides simple means to get all the current machines, as well as as registering for machine lifecycle (added and removed) events.
| Method Summary | |
|---|---|
void |
addLifecycleListener(MachineLifecycleEventListener eventListener)
Allows to add a MachineLifecycleEventListener. |
ElasticMachineProvisioningFailureEventManager |
getElasticMachineProvisioningFailure()
Returns the elastic machine provisioning failure event manager allowing to add and remove ElasticMachineProvisioningFailureEventListeners. |
ElasticMachineProvisioningProgressChangedEventManager |
getElasticMachineProvisioningProgressChanged()
Returns the elastic machine provisioning failure event manager allowing to add and remove ElasticMachineProvisioningProgressChangedEventListeners. |
Map<String,Machine> |
getHostsByAddress()
Returns a map of machines by host address. |
Map<String,Machine> |
getHostsByName()
Returns a map of machines by host names. |
MachineAddedEventManager |
getMachineAdded()
Returns the machines added event manager allowing to add and remove MachineAddedEventListeners. |
Machine |
getMachineByHostAddress(String hostAddress)
Returns the machine by the host address. |
Machine |
getMachineByHostName(String hostName)
Returns the machine by the host name. |
MachineRemovedEventManager |
getMachineRemoved()
Returns the grid service container added event manager allowing to add and remove MachineRemovedEventListeners. |
Machine[] |
getMachines()
Returns all currently discovered machines. |
int |
getSize()
Returns the number of machines current discovered. |
Map<String,Machine> |
getUids()
Returns a map of machines with the key as the uid. |
boolean |
isEmpty()
Returns true if there are no machines, false otherwise. |
void |
removeLifeycleListener(MachineLifecycleEventListener eventListener)
Allows to remove a MachineLifecycleEventListener. |
boolean |
waitFor(int numberOfMachines)
Waits indefinitely till the provided number of machines are up. |
boolean |
waitFor(int numberOfMachines,
long timeout,
TimeUnit timeUnit)
Waits for the given timeout (in time unit) till the provided number of machines are up. |
Machine |
waitFor(String host)
Waits indefinitely till the machine with the given host (name/address) is discovered. |
Machine |
waitFor(String host,
long timeout,
TimeUnit timeUnit)
Waits for the given timeout (in time unit) till the machien with the given host (name/address) is discovered. |
| Methods inherited from interface org.openspaces.admin.AdminAware |
|---|
getAdmin |
| Methods inherited from interface java.lang.Iterable |
|---|
iterator |
| Method Detail |
|---|
Machine[] getMachines()
Machine getMachineByHostAddress(String hostAddress)
hostAddress - The host address to lookup the machine by
null if there is no oneMachine getMachineByHostName(String hostName)
Map<String,Machine> getUids()
Map<String,Machine> getHostsByAddress()
Map<String,Machine> getHostsByName()
int getSize()
boolean isEmpty()
true if there are no machines, false otherwise.
boolean waitFor(int numberOfMachines)
numberOfMachines - The number of containers to wait for
boolean waitFor(int numberOfMachines,
long timeout,
TimeUnit timeUnit)
true if the required number of machines were discovered, false
if the timeout expired.
numberOfMachines - The number of containers to wait forMachine waitFor(String host)
host - The machine host name or address
Machine waitFor(String host,
long timeout,
TimeUnit timeUnit)
null
if the machine was not discovered.
host - The machine host name or addresstimeout - The timeout value to waittimeUnit - The time unit of the timeout value
null if it was not discovered within the provided timeoutMachineAddedEventManager getMachineAdded()
MachineAddedEventListeners.
MachineRemovedEventManager getMachineRemoved()
MachineRemovedEventListeners.
void addLifecycleListener(MachineLifecycleEventListener eventListener)
MachineLifecycleEventListener.
void removeLifeycleListener(MachineLifecycleEventListener eventListener)
MachineLifecycleEventListener.
ElasticMachineProvisioningFailureEventManager getElasticMachineProvisioningFailure()
ElasticMachineProvisioningFailureEventListeners.
ElasticMachineProvisioningProgressChangedEventManager getElasticMachineProvisioningProgressChanged()
ElasticMachineProvisioningProgressChangedEventListeners.
|
GigaSpaces XAP 8.0 API | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||