Ice Reference Documentation | ||
---|---|---|
<<< Previous | Slice Documentation | Next >>> |
interface |
A session object is used by IceGrid clients to allocate and
release objects. Client sessions are either created with the
Registry
object or the registry client ::Glacier2::SessionManager
object.
Keep the session alive.
Allocate an object.
Allocate an object with the given type.
Release an object.
Set the allocation timeout.
void keepAlive(); |
Keep the session alive. Clients should call this operation regularly to prevent the server from reaping the session.
[ "ami", "amd" ] Object* allocateObjectById( |
Allocate an object. Depending on the allocation timeout, this operation might hang until the object is available or until the timeout is reached.
The identity of the object to allocate.
The proxy of the allocated object.
ObjectNotRegisteredException
Raised if the object with the given identity is not registered with the registry.
AllocationException
Raised if the object can't be allocated.
[ "ami", "amd" ]
Object* allocateObjectByType(string type)
throws
|
Allocate an object with the given type. Depending on the allocation timeout, this operation might hang until an object becomes available or until the timeout is reached.
The type of the object.
The proxy of the allocated object.
if no objects with the given type can be allocated.
void releaseObject( |
Release an object.
The identity of the object to release.
ObjectNotRegisteredException
Raised if the object with the given identity is not registered with the registry.
AllocationException
Raised if the given object can't be released. This might happen if the object isn't allocatable or isn't allocated by the session.
void setAllocationTimeout(int timeout); |
Set the allocation timeout. If no objects are available for an allocation request, the request will hang for the duration of this timeout.
The timeout in milliseconds.
<<< Previous | Home | Next >>> |
IceGrid::ServiceInstanceDescriptor | Up | IceGrid::TemplateDescriptor |