Package com.j_spaces.core.service
Class ServiceAdminProxy
java.lang.Object
com.j_spaces.core.service.ServiceAdminProxy
- All Implemented Interfaces:
ServiceAdmin,DestroyAdmin,Serializable,Remote,JoinAdmin,ReferentUuid
- Direct Known Subclasses:
JSpaceAdminProxy
Copyright (c) 2010 GigaSpaces Technologies Ltd. All rights reserved
The software source code is proprietary and confidential information of GigaSpaces. You may use
the software source code solely under the terms and limitations of The license agreement granted
to you by GigaSpaces.
- See Also:
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionServiceAdminProxy(ServiceAdmin adminImpl, Uuid uuid) Constructor for use by getInstance(), ConstrainableAdminProxy. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddLookupAttributes(Entry[] attrSets) Add attribute sets for the service.voidaddLookupGroups(String[] groups) Add new groups to the set to join.voidaddLookupLocators(LookupLocator[] locators) Add locators for specific new lookup services to join.voiddestroy()Destroy the service, if possible, including its persistent storage.booleanProxies for servers with the same service ID are considered equal.static ServiceAdminProxygetInstance(ServiceAdmin adminImpl, Uuid uuid) Returns AdminProxy or ConstrainableAdminProxy instance, depending on whether given server implements RemoteMethodControl.Entry[]Get the current attribute sets for the service.String[]Get the list of groups to join.Get the list of locators of specific lookup services to join.Return theUuidthat has been assigned to the resource this proxy represents.inthashCode()Returns service ID hash code.voidmodifyLookupAttributes(Entry[] attrSetTemplates, Entry[] attrSets) Modify the current attribute sets, using the same semantics as ServiceRegistration.modifyAttributes.voidremoveLookupGroups(String[] groups) Remove groups from the set to join.voidremoveLookupLocators(LookupLocator[] locators) Remove locators for specific lookup services from the set to join.voidsetLookupGroups(String[] groups) Replace the list of groups to join with a new list.voidsetLookupLocators(LookupLocator[] locators) Replace the list of locators of specific lookup services to join with a new list.
-
Field Details
-
adminImpl
-
uuid
-
-
Constructor Details
-
ServiceAdminProxy
Constructor for use by getInstance(), ConstrainableAdminProxy.
-
-
Method Details
-
getInstance
Returns AdminProxy or ConstrainableAdminProxy instance, depending on whether given server implements RemoteMethodControl. -
hashCode
public int hashCode()Returns service ID hash code. -
equals
Proxies for servers with the same service ID are considered equal. -
destroy
Description copied from interface:DestroyAdminDestroy the service, if possible, including its persistent storage. This method should (in effect) spawn a separate thread to do the actual work asynchronously, and make a reasonable attempt to let this remote call return successfully. As such, a successful return from this method does not mean that the service has been destroyed. Although the service should make a reasonable attempt to let this remote call return successfully, the service must not wait indefinitely for other (in-progress and subsequent) remote calls to finish before proceeding to destroy itself. Once this method has been called, the service can, but need not, reject all other (in-progress and subsequent) remote calls to the service.- Specified by:
destroyin interfaceDestroyAdmin- Specified by:
destroyin interfaceServiceAdmin- Throws:
RemoteException
-
getLookupAttributes
Description copied from interface:JoinAdminGet the current attribute sets for the service.- Specified by:
getLookupAttributesin interfaceJoinAdmin- Returns:
- the current attribute sets for the service
- Throws:
RemoteException
-
addLookupAttributes
Description copied from interface:JoinAdminAdd attribute sets for the service. The resulting set will be used for all future joins. The attribute sets are also added to all currently-joined lookup services.- Specified by:
addLookupAttributesin interfaceJoinAdmin- Parameters:
attrSets- the attribute sets to add- Throws:
RemoteException
-
modifyLookupAttributes
public void modifyLookupAttributes(Entry[] attrSetTemplates, Entry[] attrSets) throws RemoteException Description copied from interface:JoinAdminModify the current attribute sets, using the same semantics as ServiceRegistration.modifyAttributes. The resulting set will be used for all future joins. The same modifications are also made to all currently-joined lookup services.- Specified by:
modifyLookupAttributesin interfaceJoinAdmin- Parameters:
attrSetTemplates- the templates for matching attribute setsattrSets- the modifications to make to matching sets- Throws:
RemoteException- See Also:
-
getLookupGroups
Description copied from interface:JoinAdminGet the list of groups to join. An empty array means the service joins no groups (as opposed to "all" groups).- Specified by:
getLookupGroupsin interfaceJoinAdmin- Returns:
- an array of groups to join. An empty array means the service joins no groups (as opposed to "all" groups).
- Throws:
RemoteException- See Also:
-
addLookupGroups
Description copied from interface:JoinAdminAdd new groups to the set to join. Lookup services in the new groups will be discovered and joined.- Specified by:
addLookupGroupsin interfaceJoinAdmin- Parameters:
groups- groups to join- Throws:
RemoteException- See Also:
-
removeLookupGroups
Description copied from interface:JoinAdminRemove groups from the set to join. Leases are cancelled at lookup services that are not members of any of the remaining groups.- Specified by:
removeLookupGroupsin interfaceJoinAdmin- Parameters:
groups- groups to leave- Throws:
RemoteException- See Also:
-
setLookupGroups
Description copied from interface:JoinAdminReplace the list of groups to join with a new list. Leases are cancelled at lookup services that are not members of any of the new groups. Lookup services in the new groups will be discovered and joined.- Specified by:
setLookupGroupsin interfaceJoinAdmin- Parameters:
groups- groups to join- Throws:
RemoteException- See Also:
-
getLookupLocators
Description copied from interface:JoinAdminGet the list of locators of specific lookup services to join.- Specified by:
getLookupLocatorsin interfaceJoinAdmin- Returns:
- the list of locators of specific lookup services to join
- Throws:
RemoteException- See Also:
-
addLookupLocators
Description copied from interface:JoinAdminAdd locators for specific new lookup services to join. The new lookup services will be discovered and joined.- Specified by:
addLookupLocatorsin interfaceJoinAdmin- Parameters:
locators- locators of specific lookup services to join- Throws:
RemoteException- See Also:
-
removeLookupLocators
Description copied from interface:JoinAdminRemove locators for specific lookup services from the set to join. Any leases held at the lookup services are cancelled.- Specified by:
removeLookupLocatorsin interfaceJoinAdmin- Parameters:
locators- locators of specific lookup services to leave- Throws:
RemoteException- See Also:
-
setLookupLocators
Description copied from interface:JoinAdminReplace the list of locators of specific lookup services to join with a new list. Leases are cancelled at lookup services that were in the old list but are not in the new list. Any new lookup services will be discovered and joined.- Specified by:
setLookupLocatorsin interfaceJoinAdmin- Parameters:
locators- locators of specific lookup services to join- Throws:
RemoteException- See Also:
-
getReferentUuid
Description copied from interface:ReferentUuidReturn theUuidthat has been assigned to the resource this proxy represents.- Specified by:
getReferentUuidin interfaceReferentUuid- Returns:
- the
Uuidassociated with the resource this proxy represents. Will not returnnull.
-