Public Member Functions | |
ContainerServicesImpl (AcsManagerProxy acsManagerProxy, POA componentPOA, AcsCorba acsCorba, AcsLogger logger, int clientHandle, String clientCurl, ComponentStateManager componentStateManager, ThreadFactory threadFactory) | |
String | getName () |
ComponentStateManager | getComponentStateManager () |
AcsLogger | getLogger () |
void | registerComponentListener (ComponentListener listener) |
void | fireComponentsAvailable (List< ComponentDescriptor > compDescs) |
void | fireComponentsUnavailable (List< String > compNames) |
void | assignUniqueEntityId (EntityT entity) throws AcsJContainerServicesEx |
String[] | findComponents (String curlWildcard, String typeWildcard) throws AcsJContainerServicesEx |
ComponentDescriptor | getComponentDescriptor (String curl) throws AcsJContainerServicesEx |
org.omg.CORBA.Object | getComponent (String curl) throws AcsJContainerServicesEx |
org.omg.CORBA.Object | getComponentNonSticky (String curl) throws AcsJContainerServicesEx |
org.omg.CORBA.Object | getDefaultComponent (String componentIDLType) throws AcsJContainerServicesEx |
org.omg.CORBA.Object | getCollocatedComponent (String compUrl, String targetCompUrl) throws AcsJContainerServicesEx |
org.omg.CORBA.Object | getCollocatedComponent (ComponentQueryDescriptor spec, boolean markAsDefaul, String targetCompUrl) throws AcsJContainerServicesEx |
org.omg.CORBA.Object | getDynamicComponent (ComponentQueryDescriptor compDesc, boolean markAsDefault) throws AcsJContainerServicesEx |
org.omg.CORBA.Object | getDynamicComponent (ComponentSpec compSpec, boolean markAsDefault) throws AcsJContainerServicesEx |
org.omg.CORBA.Object | getReferenceWithCustomClientSideTimeout (org.omg.CORBA.Object originalCorbaRef, double timeoutSeconds) throws AcsJContainerServicesEx |
DAL | getCDB () throws AcsJContainerServicesEx |
void | releaseComponent (String curl) |
OffShoot | activateOffShoot (Servant servant) throws AcsJContainerServicesEx |
void | deactivateOffShoot (Servant cbServant) throws AcsJContainerServicesEx |
synchronized AdvancedContainerServices | getAdvancedContainerServices () |
void | releaseAllComponents () |
ThreadFactory | getThreadFactory () |
Static Public Attributes | |
final String | PROPERTYNAME_FAKE_UID_FOR_TESTING = "acs.container.fakeUIDsForTesting" |
Protected Attributes | |
final AcsManagerProxy | m_acsManagerProxy |
final AcsLogger | m_logger |
Package Functions | |
public< T > T | getTransparentXmlComponent (Class< T > transparentXmlIF, org.omg.CORBA.Object componentReference, Class flatXmlIF) throws AcsJContainerServicesEx |
AcsCorba | getAcsCorba () |
void | setMethodsExcludedFromInvocationLogging (String[] methodsExcludedFromInvocationLogging) |
Private Member Functions | |
void | checkOffShootServant (Servant servant) throws AcsJContainerServicesEx |
Private Attributes | |
AdvancedContainerServicesImpl | advancedContainerServices |
volatile UIDLibrary | uidLibrary |
volatile IdentifierJ | identifierArchive |
final boolean | fakeUIDsForTesting = Boolean.getBoolean(PROPERTYNAME_FAKE_UID_FOR_TESTING) |
volatile AcsLogger | componentLogger |
final Map< String, org.omg.CORBA.Object > | m_usedComponentsMap |
final Map< String, org.omg.CORBA.Object > | m_usedNonStickyComponentsMap |
final Map< String, ComponentDescriptor > | m_componentDescriptorMap |
final int | m_clientHandle |
final String | m_clientName |
final AcsCorba | acsCorba |
final POA | m_clientPOA |
final ComponentStateManager | m_componentStateManager |
final ThreadFactory | m_threadFactory |
volatile String[] | methodsExcludedFromInvocationLogging |
ComponentListener | compListener |
ContainerServices
interface. To be used by ACS components, as well as any other clients that need access to components. This class is "cheap" to instantiate because many resources it uses are singletons and or objects otherwise shared among instances. It should thus be ok to create one instance per component or other client.
This class has to be thread-safe, because a component's functional methods can be called from different ORB threads, or because the component could itself create threads, each of them accessing this object.
|
ctor.
|
|
Implements alma::acs::container::ContainerServicesBase.
|
|
Implements alma::acs::container::ContainerServices.
|
|
|
|
Deactivates the offshoot corba object. Caution: this method returns immediately, while the underlying org.omg.PortableServer.POAOperations#deactivate_object(byte[]) still works on the deactivation. If activateOffShoot(Servant) is called too shortly after deactivation, an exception will be thrown. TODO: find a remedy
Implements alma::acs::container::ContainerServicesBase.
|
|
Implements alma::acs::container::ContainerServices.
|
|
|
|
|
|
|
|
Implements alma::acs::container::ContainerServicesBase.
|
|
Implements alma::acs::container::ContainerServicesBase.
|
|
Dynamic version of getCollocatedComponent(String, String).
Implements alma::acs::container::ContainerServices.
|
|
Gets a component that will run collocated with a given component.
Implements alma::acs::container::ContainerServices.
|
|
Implements alma::acs::container::ContainerServices.
|
|
Implements alma::acs::container::ContainerServices.
|
|
Gets a non-sticky reference to a component. This is typically used by "weak clients" such as graphical user interfaces that only want to observe the running system without interfering with its functioning. A non-sticky reference does not bind the Manager to keep alive the Component, and the Client requesting a non-sticky reference is not considered when checking for reference counts. The non-sticky reference should not be released, as that call will fail. The Manager can deactivate Components independently of any non-sticky reference. Since a non-sticky reference is not considered in reference counting, it will also not activate the component if it is not already active. As a consequence, asking for a non-sticky reference to a not-active Component throws an exception. The client represented by id (the handle) must have adequate access rights to access the component.
Implements alma::acs::container::ContainerServices.
|
|
{} This method should only be called by a component that lives inside a container; a component client that is not a component itself should not call it, would result in a NPE!
Implements alma::acs::container::ContainerServices.
|
|
Implements alma::acs::container::ContainerServices.
|
|
Implements alma::acs::container::ContainerServices.
|
|
Implements alma::acs::container::ContainerServices.
|
|
The component must retrieve its logger object from this interface (as opposed to using the The goal is to have "componentName" and other fields in all ALMA log entries, and have tool support for filtering logs by component, subsystem, user, ...
Implements alma::acs::container::ContainerServicesBase.
|
|
Gets the component name (which the component does not know statically) Implements alma::acs::container::ContainerServicesBase.
|
|
Wraps a component reference (or offshoot reference etc) such that the given timeout is applied on the client side of calls to this (possibly remote) object. If the total call, including de-/serialization and network travel, takes longer than the given timeout, an This allows us to override the general timeout given at the system level (e.g. orb.properties file in case of jacorb) and the container-level timeout given in the CDB container configuration. It is possible to set the timeout to values that are shorter or longer than the default timeout. You should chose a timeout value that matches the expected response time, with a large safety margin of Note that calls to which the specified timeout should apply must be made on the object reference returned from this method, and not on the original object that gets passed to this method! Some corba implementations may apply the timeout to both objects though, or return the original object.
Implements alma::acs::container::ContainerServices.
|
|
Implements alma::acs::container::ContainerServicesBase.
|
|
{}. todo: implement: ask AcsContainer if it knows componentReference, and if it has transpXml-IF; if so, get component impl directly; check if respective component helper allows direct calls to transpXmlIF (by not implementing _getInterfaceTranslator, or some explicit flag); move intercepting layer (ContainerSealant) so that it's still in between the components.
Implements alma::acs::container::ContainerServices.
|
|
Allows a client to register a callback object that gets notified when some component(s) in use by the client (= components the client requested previously) dies or comes back to life (with
If the client wants to get notified even for components that it does not hold a reference to, then
Implements alma::acs::container::ContainerServices.
|
|
|
|
Releases the specified component reference. This involves notification of the manager, as well as calling Note that references to other components are released by this method, where the components hosted inside this container act as clients. These referenced components may run inside this or some other container/container. TODO optionally run in a separate thread to gain speed, especially needed for quick shutdown; consider race condition at the manager with new activation request for the same component though.
Implements alma::acs::container::ContainerServices.
|
|
With this optional call, automatic invocation logging for certain offshoot methods can be disabled.
|
|
|
|
|
|
Optional callback object for component available/unavailable notification |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
cheat property that allows testing without identifier archive present, because UIDs will be faked |
|
|