Package org.apache.jackrabbit.rmi.server
Class ServerAdapterFactory
- java.lang.Object
-
- org.apache.jackrabbit.rmi.server.ServerAdapterFactory
-
- All Implemented Interfaces:
RemoteAdapterFactory
@Deprecated public class ServerAdapterFactory extends Object implements RemoteAdapterFactory
Deprecated.RMI support is deprecated and will be removed in a future version of Jackrabbit; see Jira ticket JCR-4972 for more information.Default implementation of the
RemoteAdapterFactoryinterface. This factory uses the server adapters defined in this package as the default adapter implementations. Subclasses can override or extend the default adapters by implementing the corresponding factory methods.The
bufferSizeproperty can be used to configure the size of the buffer used by iterators to speed up iterator traversal over the network.
-
-
Constructor Summary
Constructors Constructor Description ServerAdapterFactory()Deprecated.
-
Method Summary
-
-
-
Method Detail
-
getBufferSize
public int getBufferSize()
Deprecated.Returns the iterator buffer size.- Returns:
- iterator buffer size
-
setBufferSize
public void setBufferSize(int bufferSize)
Deprecated.Sets the iterator buffer size.- Parameters:
bufferSize- iterator buffer size
-
getPortNumber
public int getPortNumber()
Deprecated.Returns the port number for server objects.- Specified by:
getPortNumberin interfaceRemoteAdapterFactory- Returns:
- port number, or 0 for the default
-
setPortNumber
public void setPortNumber(int portNumber)
Deprecated.Sets the port number for server objects.- Parameters:
portNumber- port number, or 0 for the default
-
getRemoteRepository
public RemoteRepository getRemoteRepository(Repository repository) throws RemoteException
Deprecated.Creates aServerRepositoryinstance. Returns a remote adapter for the given local repository.- Specified by:
getRemoteRepositoryin interfaceRemoteAdapterFactory- Parameters:
repository- local repository- Returns:
- remote repository adapter
- Throws:
RemoteException- on RMI errors
-
getRemoteSession
public RemoteSession getRemoteSession(Session session) throws RemoteException
Deprecated.Creates aServerSessioninstance. In case the underlying session is transaction enabled, the remote interface is will be transaction enabled too through theServerXASession. Returns a remote adapter for the given local session.- Specified by:
getRemoteSessionin interfaceRemoteAdapterFactory- Parameters:
session- local session- Returns:
- remote session adapter
- Throws:
RemoteException- on RMI errors
-
getRemoteWorkspace
public RemoteWorkspace getRemoteWorkspace(Workspace workspace) throws RemoteException
Deprecated.Creates aServerWorkspaceinstance. Returns a remote adapter for the given local workspace.- Specified by:
getRemoteWorkspacein interfaceRemoteAdapterFactory- Parameters:
workspace- local workspace- Returns:
- remote workspace adapter
- Throws:
RemoteException- on RMI errors
-
getRemoteObservationManager
public RemoteObservationManager getRemoteObservationManager(ObservationManager observationManager) throws RemoteException
Deprecated.Creates aServerObservationManagerinstance. Returns a remote adapter for the given local observation manager.- Specified by:
getRemoteObservationManagerin interfaceRemoteAdapterFactory- Parameters:
observationManager- local observation manager- Returns:
- remote observation manager adapter
- Throws:
RemoteException- on RMI errors
-
getRemoteNamespaceRegistry
public RemoteNamespaceRegistry getRemoteNamespaceRegistry(NamespaceRegistry registry) throws RemoteException
Deprecated.Creates aServerNamespaceRegistryinstance. Returns a remote adapter for the given local namespace registry.- Specified by:
getRemoteNamespaceRegistryin interfaceRemoteAdapterFactory- Parameters:
registry- local namespace registry- Returns:
- remote namespace registry adapter
- Throws:
RemoteException- on RMI errors
-
getRemoteNodeTypeManager
public RemoteNodeTypeManager getRemoteNodeTypeManager(NodeTypeManager manager) throws RemoteException
Deprecated.Creates aServerNodeTypeManagerinstance. Returns a remote adapter for the given local node type manager.- Specified by:
getRemoteNodeTypeManagerin interfaceRemoteAdapterFactory- Parameters:
manager- local node type manager- Returns:
- remote node type manager adapter
- Throws:
RemoteException- on RMI errors
-
getRemoteItem
public RemoteItem getRemoteItem(Item item) throws RemoteException
Deprecated.Creates aServerIteminstance. Returns a remote adapter for the given local item. This method will return an adapter that implements only theIteminterface. The caller may want to introspect the local item to determine whether to use either thegetRemoteNodeor thegetRemotePropertymethod instead.- Specified by:
getRemoteItemin interfaceRemoteAdapterFactory- Parameters:
item- local item- Returns:
- remote item adapter
- Throws:
RemoteException- on RMI errors
-
getRemoteProperty
public RemoteProperty getRemoteProperty(Property property) throws RemoteException
Deprecated.Creates aServerPropertyinstance. Returns a remote adapter for the given local property.- Specified by:
getRemotePropertyin interfaceRemoteAdapterFactory- Parameters:
property- local property- Returns:
- remote property adapter
- Throws:
RemoteException- on RMI errors
-
getRemoteNode
public RemoteNode getRemoteNode(Node node) throws RemoteException
Deprecated.Creates aServerNodeinstance. Returns a remote adapter for the given local node.- Specified by:
getRemoteNodein interfaceRemoteAdapterFactory- Parameters:
node- local node- Returns:
- remote node adapter
- Throws:
RemoteException- on RMI errors
-
getRemoteVersion
public RemoteVersion getRemoteVersion(Version version) throws RemoteException
Deprecated.Creates aServerVersioninstance. Returns a remote adapter for the given local version.- Specified by:
getRemoteVersionin interfaceRemoteAdapterFactory- Parameters:
version- local version- Returns:
- remote version adapter
- Throws:
RemoteException- on RMI errors
-
getRemoteVersionHistory
public RemoteVersionHistory getRemoteVersionHistory(VersionHistory versionHistory) throws RemoteException
Deprecated.Creates aServerVersionHistoryinstance. Returns a remote adapter for the given local version history.- Specified by:
getRemoteVersionHistoryin interfaceRemoteAdapterFactory- Parameters:
versionHistory- local version history- Returns:
- remote version history adapter
- Throws:
RemoteException- on RMI errors
-
getRemoteNodeType
public RemoteNodeType getRemoteNodeType(NodeType type) throws RemoteException
Deprecated.Creates aServerNodeTypeinstance. Returns a remote adapter for the given local node type.- Specified by:
getRemoteNodeTypein interfaceRemoteAdapterFactory- Parameters:
type- local node type- Returns:
- remote node type adapter
- Throws:
RemoteException- on RMI errors
-
getRemoteItemDefinition
public RemoteItemDefinition getRemoteItemDefinition(ItemDefinition def) throws RemoteException
Deprecated.Creates aServerItemDefinitioninstance. Returns a remote adapter for the given local item definition. This method will return an adapter that implements only theItemDefinitioninterface. The caller may want to introspect the local item definition to determine whether to use either thegetRemoteNodeDefor thegetRemotePropertyDefmethod instead.- Specified by:
getRemoteItemDefinitionin interfaceRemoteAdapterFactory- Parameters:
def- local item definition- Returns:
- remote item definition adapter
- Throws:
RemoteException- on RMI errors
-
getRemoteNodeDefinition
public RemoteNodeDefinition getRemoteNodeDefinition(NodeDefinition def) throws RemoteException
Deprecated.Creates aServerNodeDefinitioninstance. Returns a remote adapter for the given local node definition.- Specified by:
getRemoteNodeDefinitionin interfaceRemoteAdapterFactory- Parameters:
def- local node definition- Returns:
- remote node definition adapter
- Throws:
RemoteException- on RMI errors
-
getRemotePropertyDefinition
public RemotePropertyDefinition getRemotePropertyDefinition(PropertyDefinition def) throws RemoteException
Deprecated.Creates aServerPropertyDefinitioninstance. Returns a remote adapter for the given local property definition.- Specified by:
getRemotePropertyDefinitionin interfaceRemoteAdapterFactory- Parameters:
def- local property definition- Returns:
- remote property definition adapter
- Throws:
RemoteException- on RMI errors
-
getRemoteLock
public RemoteLock getRemoteLock(Lock lock) throws RemoteException
Deprecated.Creates aServerLockinstance. Returns a remote adapter for the given local lock.- Specified by:
getRemoteLockin interfaceRemoteAdapterFactory- Parameters:
lock- local lock- Returns:
- remote lock adapter
- Throws:
RemoteException- on RMI errors
-
getRemoteQueryManager
public RemoteQueryManager getRemoteQueryManager(Session session, QueryManager manager) throws RemoteException
Deprecated.Creates aServerQueryManagerinstance. Returns a remote adapter for the given local query manager.- Specified by:
getRemoteQueryManagerin interfaceRemoteAdapterFactory- Parameters:
session- current sessionmanager- local query manager- Returns:
- remote query manager adapter
- Throws:
RemoteException- on RMI errors
-
getRemoteQuery
public RemoteQuery getRemoteQuery(Query query) throws RemoteException
Deprecated.Creates aServerQueryinstance. Returns a remote adapter for the given local query.- Specified by:
getRemoteQueryin interfaceRemoteAdapterFactory- Parameters:
query- local query- Returns:
- remote query adapter
- Throws:
RemoteException- on RMI errors
-
getRemoteQueryResult
public RemoteQueryResult getRemoteQueryResult(QueryResult result) throws RemoteException
Deprecated.Creates aServerQueryResultinstance. Returns a remote adapter for the given local query result.- Specified by:
getRemoteQueryResultin interfaceRemoteAdapterFactory- Parameters:
result- local query result- Returns:
- remote query result adapter
- Throws:
RemoteException- on RMI errors
-
getRemoteRow
public RemoteRow getRemoteRow(Row row) throws RemoteException
Deprecated.Creates aServerQueryResultinstance. Returns a remote adapter for the given local query row.- Specified by:
getRemoteRowin interfaceRemoteAdapterFactory- Parameters:
row- local query row- Returns:
- remote query row adapter
- Throws:
RemoteException- on RMI errors
-
getRemoteEvent
public RemoteEventCollection getRemoteEvent(long listenerId, EventIterator events) throws RemoteException
Deprecated.Creates aServerEventCollectioninstances. Returns a remote adapter for the given local events.- Specified by:
getRemoteEventin interfaceRemoteAdapterFactory- Parameters:
listenerId- The listener identifier to which the events are to be dispatched.events- the local events- Returns:
- remote event iterator adapter
- Throws:
RemoteException- on RMI errors
-
optimizeIterator
protected RemoteIterator optimizeIterator(RemoteIterator remote) throws RemoteException
Deprecated.Optimizes the given remote iterator for transmission across the network. This method retrieves the first set of elements from the iterator by callingRemoteIterator.nextObjects()and then asks for the total size of the iterator. If the size is unkown or greater than the length of the retrieved array, then the elements, the size, and the remote iterator reference are wrapped into aBufferIteratorinstance that gets passed over the network. If the retrieved array of elements contains all the elements in the iterator, then the iterator instance is discarded and just the elements are wrapped into aArrayIteratorinstance to be passed to the client.Subclasses can override this method to provide alternative optimizations.
- Parameters:
remote- remote iterator- Returns:
- optimized remote iterator
- Throws:
RemoteException- on RMI errors
-
getRemoteNodeIterator
public RemoteIterator getRemoteNodeIterator(NodeIterator iterator) throws RemoteException
Deprecated.Creates aServerNodeIteratorinstance. Returns a remote adapter for the given local node iterator.- Specified by:
getRemoteNodeIteratorin interfaceRemoteAdapterFactory- Parameters:
iterator- local node iterator- Returns:
- remote iterator adapter
- Throws:
RemoteException- on RMI errors
-
getRemotePropertyIterator
public RemoteIterator getRemotePropertyIterator(PropertyIterator iterator) throws RemoteException
Deprecated.Creates aServerPropertyIteratorinstance. Returns a remote adapter for the given local property iterator.- Specified by:
getRemotePropertyIteratorin interfaceRemoteAdapterFactory- Parameters:
iterator- local property iterator- Returns:
- remote iterator adapter
- Throws:
RemoteException- on RMI errors
-
getRemoteVersionIterator
public RemoteIterator getRemoteVersionIterator(VersionIterator iterator) throws RemoteException
Deprecated.Creates aServerVersionIteratorinstance. Returns a remote adapter for the given local version iterator.- Specified by:
getRemoteVersionIteratorin interfaceRemoteAdapterFactory- Parameters:
iterator- local version iterator- Returns:
- remote iterator adapter
- Throws:
RemoteException- on RMI errors
-
getRemoteNodeTypeIterator
public RemoteIterator getRemoteNodeTypeIterator(NodeTypeIterator iterator) throws RemoteException
Deprecated.Creates aServerNodeTypeIteratorinstance. Returns a remote adapter for the given local node type iterator.- Specified by:
getRemoteNodeTypeIteratorin interfaceRemoteAdapterFactory- Parameters:
iterator- local node type iterator- Returns:
- remote iterator adapter
- Throws:
RemoteException- on RMI errors
-
getRemoteRowIterator
public RemoteIterator getRemoteRowIterator(RowIterator iterator) throws RemoteException
Deprecated.Creates aServerRowIteratorinstance. Returns a remote adapter for the given local row iterator.- Specified by:
getRemoteRowIteratorin interfaceRemoteAdapterFactory- Parameters:
iterator- local row iterator- Returns:
- remote iterator adapter
- Throws:
RemoteException- on RMI errors
-
getRemoteLockManager
public RemoteLockManager getRemoteLockManager(LockManager lockManager) throws RemoteException
Deprecated.- Specified by:
getRemoteLockManagerin interfaceRemoteAdapterFactory- Throws:
RemoteException
-
getRemoteVersionManager
public RemoteVersionManager getRemoteVersionManager(Session session, VersionManager versionManager) throws RemoteException
Deprecated.- Specified by:
getRemoteVersionManagerin interfaceRemoteAdapterFactory- Throws:
RemoteException
-
getRemoteAccessControlManager
public RemoteAccessControlManager getRemoteAccessControlManager(AccessControlManager acm) throws RemoteException
Deprecated.Creates aServerAccessControlManagerinstance. Returns a remote adapter for the given local access control manager.- Specified by:
getRemoteAccessControlManagerin interfaceRemoteAdapterFactory- Parameters:
acm- local access control manager- Returns:
- remote access control manager
- Throws:
RemoteException- on RMI errors
-
getRemotePrivilege
public RemotePrivilege getRemotePrivilege(Privilege local) throws RemoteException
Deprecated.Description copied from interface:RemoteAdapterFactoryReturns a remote adapter for the given local access control manager.- Specified by:
getRemotePrivilegein interfaceRemoteAdapterFactory- Returns:
- remote access control manager
- Throws:
RemoteException- on RMI errors
-
getRemotePrivilege
public RemotePrivilege[] getRemotePrivilege(Privilege[] local) throws RemoteException
Deprecated.Description copied from interface:RemoteAdapterFactoryReturns a remote adapter for the given local access control manager.- Specified by:
getRemotePrivilegein interfaceRemoteAdapterFactory- Returns:
- remote access control manager
- Throws:
RemoteException- on RMI errors
-
getRemoteAccessControlPolicy
public RemoteAccessControlPolicy getRemoteAccessControlPolicy(AccessControlPolicy local) throws RemoteException
Deprecated.Description copied from interface:RemoteAdapterFactoryReturns a remote adapter for the given local access control manager.- Specified by:
getRemoteAccessControlPolicyin interfaceRemoteAdapterFactory- Returns:
- remote access control manager
- Throws:
RemoteException- on RMI errors
-
getRemoteAccessControlPolicy
public RemoteAccessControlPolicy[] getRemoteAccessControlPolicy(AccessControlPolicy[] local) throws RemoteException
Deprecated.Description copied from interface:RemoteAdapterFactoryReturns a remote adapter for the given local access control manager.- Specified by:
getRemoteAccessControlPolicyin interfaceRemoteAdapterFactory- Returns:
- remote access control manager
- Throws:
RemoteException- on RMI errors
-
getRemoteAccessControlPolicyIterator
public RemoteIterator getRemoteAccessControlPolicyIterator(AccessControlPolicyIterator iterator) throws RemoteException
Deprecated.Creates aServerNodeIteratorinstance. Returns a remote adapter for the given local access control manager.- Specified by:
getRemoteAccessControlPolicyIteratorin interfaceRemoteAdapterFactory- Returns:
- remote access control manager
- Throws:
RemoteException- on RMI errors
-
getRemoteAccessControlEntry
public RemoteAccessControlEntry getRemoteAccessControlEntry(AccessControlEntry local) throws RemoteException
Deprecated.Description copied from interface:RemoteAdapterFactoryReturns a remote adapter for the given local access control manager.- Specified by:
getRemoteAccessControlEntryin interfaceRemoteAdapterFactory- Returns:
- remote access control manager
- Throws:
RemoteException- on RMI errors
-
getRemoteAccessControlEntry
public RemoteAccessControlEntry[] getRemoteAccessControlEntry(AccessControlEntry[] local) throws RemoteException
Deprecated.Description copied from interface:RemoteAdapterFactoryReturns a remote adapter for the given local access control manager.- Specified by:
getRemoteAccessControlEntryin interfaceRemoteAdapterFactory- Returns:
- remote access control manager
- Throws:
RemoteException- on RMI errors
-
getRemotePrincipal
public RemotePrincipal getRemotePrincipal(Principal principal) throws RemoteException
Deprecated.Description copied from interface:RemoteAdapterFactoryReturns a remote adapter for the given local access control manager.- Specified by:
getRemotePrincipalin interfaceRemoteAdapterFactory- Returns:
- remote access control manager
- Throws:
RemoteException- on RMI errors
-
getRemotePrincipalIterator
public RemoteIterator getRemotePrincipalIterator(Iterator<Principal> principals) throws RemoteException
Deprecated.Description copied from interface:RemoteAdapterFactoryReturns a remote adapter for the given local access control manager.- Specified by:
getRemotePrincipalIteratorin interfaceRemoteAdapterFactory- Returns:
- remote access control manager
- Throws:
RemoteException- on RMI errors
-
-