Package org.cristalise.kernel.entity.proxy
package org.cristalise.kernel.entity.proxy
The Proxy API is a major part of the client-side functionality of the
CRISTAL API, which provides client-side proxy objects that represent the
Items and Agents on the server. It is the main entry point for many
components, such as Scripts and Job execution. An AgentProxy is returned on
login, and should be used as the root for all user-based CRISTAL interactions.
The Proxy API provides the following functionality:
- Transparent storage integration - Combines direct database access with remote calls to data retrieval methods on the Items. This allows client processes to load Item data directly from databases whenever possible without bothering the CRISTAL server. For example, the LDAP Lookup implementation allows client processes to load Item Properties directly from the LDAP server.
- Data object browsing and loading - The proxy objects allow client processes to browse through the storage cluster structure beneath the Item, and access the objects directly without having to unmarshall their XML forms. All object types have their own get methods, so there's no need to construct their paths nor cast.
- Job querying - Job objects may be retrieved directly from an ItemProxy, and may also be filtered by Activity name.
- Job execution - The
AgentProxyprovides the main execution method for Jobs. This method performs outcome validation and executes required CRISTAL Scripts in the client process before the execution is requested on the server. Additional execution methods to call Predefined Steps are also available. - Utility methods for resolution and marshalling - The AgentProxy provides utility methods for finding Items in the directory by name, path, or system key, and gives access to the Castor XML marshalling system to transform CRISTAL objects to XML and back again.
The core object of the Proxy API is the ProxyManager, which is initialized
as a static member of the Gateway on initialization. This object can be used
to create a Proxy object from a Path from the directory, and maintains a
connection to the server called the Proxy Update Notification Channel,
through which it subscribes to Items it holds proxies for so it can be
informed of changes to Item data through
ProxyMessage objects.
-
ClassDescriptionIt is a wrapper for the connection and communication with Agent It caches data loaded from the Agent to reduce communicationIt is a immutable wrapper for the connection and communication with Item and its data.An simple utility class to create new Proxies