|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface IConcreteSet
IConcreteSet defines the interface for concrete set resources.
A concrete set is intended to represent a set of resources. For example,
compute servers, storage servers, network paths, etc.
| Method Summary | |
|---|---|
void |
add(IConcreteSet set,
boolean configure)
Adds the passed set to the current set. |
void |
change(IConcreteSet set,
Term term,
boolean configure)
Makes changes to the resources in the concrete set. |
IConcreteSet |
clone()
Makes a clone of the concrete set. |
IConcreteSet |
cloneEmpty()
Makes an "empty" clone of this concrete set. |
void |
close()
Closes all resources contained in the set. |
IConcreteSet |
collectReleased()
Collects any released (closed) and/or failed resources. |
void |
destroy()
Completes close for a concrete set with closed resources. |
void |
extend(Term term)
Informs the concrete set that its term has been extended. |
IConcreteSet |
extract(int count,
Term term,
java.util.Properties properties,
AuthToken client)
Extracts the specified units of resources for the given period of time. |
java.lang.String |
getNotices()
Gets a string of notices or events pertaining to the underlying resources. |
IAuthorityProxy |
getSiteProxy()
Return a proxy or reference for the unique site that owns these resources. |
int |
getUnits()
Returns how many units are contained in the set. |
int |
holding(java.util.Date date)
Returns how many units are in the set at the given time instance. |
int |
holding(Term term)
Returns how many units will be in the set for the given period of time. |
boolean |
isActive()
Checks if the concrete set is active. |
void |
modify(IConcreteSet set,
boolean configure)
Updates the units in the current set with information contained in the passed set. |
void |
probe()
Checks the status of pending operations. |
void |
remove(IConcreteSet set,
boolean configure)
Removes the passed set from the current set. |
void |
setShirakoPlugin(IShirakoPlugin plugin)
|
void |
setSiteProxy(IAuthorityProxy authority)
Set a proxy or reference for the unique site that owns these resources. |
void |
setup(ResourceReservation reservation)
Initializes the concrete set with information about the containing reservation. |
void |
validateConcrete(ResourceType type,
int units,
Term term)
Validate that the concrete set matches the abstract resource set parameters. |
void |
validateIncoming()
Validates a concrete set as it is received by an actor from another actor. |
void |
validateOutgoing()
Validates a concrete set as it is about to be sent from the actor to another actor. |
| Methods inherited from interface orca.shirako.api.ISerialize |
|---|
reset, save, save |
| Methods inherited from interface orca.shirako.api.IRecover |
|---|
revisit |
| Method Detail |
|---|
void setup(ResourceReservation reservation)
reservation - reservation this concrete set belongs to
void validateIncoming()
throws java.lang.Exception
This method is called from ResourceSet with no locks on.
java.lang.Exception - if validation fails
void validateOutgoing()
throws java.lang.Exception
This method is called from ResourceSet with no locks on.
java.lang.Exception - if validation fails
void validateConcrete(ResourceType type,
int units,
Term term)
throws java.lang.Exception
type - abstract resources resource typeunits - abstract resources unitsterm - abstract resources term
java.lang.Exception
IConcreteSet extract(int count,
Term term,
java.util.Properties properties,
AuthToken client)
throws java.lang.Exception
The concrete set is not required to maintain bookkeeping to verify if the extract operation can actually be completed successfully. The caller is responsible for all bookkeeping and ensuring that the concrete set has sufficient units to satisfy this request. Extract should not decrement the available units from the concrete set.
This method will typically be called with the kernel lock on.
count - number of units to extractterm - the term for extractionproperties - properties to attach to the extracted resources. If
any, these properties will replace any properties contained in
the set the resources are being extracted from.client - the client to extract resources to
java.lang.Exception
void add(IConcreteSet set,
boolean configure)
throws java.lang.Exception
extend(Term).
set - set to addconfigure - if true, configuration actions will be triggered for all
added units
java.lang.Exception
void remove(IConcreteSet set,
boolean configure)
throws java.lang.Exception
extend(Term).
set - set to removeconfigure - if true, configuration actions will be triggered for all
removed units
java.lang.Exception
void modify(IConcreteSet set,
boolean configure)
throws java.lang.Exception
extend(Term).
set - set containing the update dataconfigure - if true, configuration actions will be triggered for all
modified units
java.lang.Exception
void change(IConcreteSet set,
Term term,
boolean configure)
throws java.lang.Exception
set - concrete resources representing the new state of the current
setterm - new termconfigure - if true, configuration actions will be triggered for all
added, removed, or modified units
java.lang.Exception - thrown if something is wrong
void extend(Term term)
throws java.lang.Exception
term - new term
java.lang.Exception
IConcreteSet collectReleased()
throws java.lang.Exception
java.lang.Exceptionint getUnits()
int holding(Term term)
term - period of time
int holding(java.util.Date date)
date - time instance
void probe()
throws java.lang.Exception
java.lang.Exception
void close()
throws java.lang.Exception
java.lang.Exception
void destroy()
throws java.lang.Exception
java.lang.ExceptionIConcreteSet cloneEmpty()
IConcreteSet clone()
cloneEmpty(), this
method preserves the set: the set elements are the same objects as the
original IConcreteSet, but the indexing structures are different. That
is, adding/removing units to the original should not affect the clone.
But modifications to an individual unit should be visible form the
original and the clone.
boolean isActive()
void setShirakoPlugin(IShirakoPlugin plugin)
IAuthorityProxy getSiteProxy()
throws java.lang.Exception
java.lang.Exception
void setSiteProxy(IAuthorityProxy authority)
throws java.lang.Exception
java.lang.Exceptionjava.lang.String getNotices()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||