Class Overview
An atomic version of the ResourceAccessor. If atomic operations are required, use instances of
 this class. Atomicity is not guaranteed when using instances of ResourceAccessor alongside
 instances of this class. Furthermore, depending on the semantics of the lock, lock acquisition
 may fail, in which case users should handle the return value of each function if necessary. 
 
 Using this class is quite expensive; it should thus be used sparingly and only in systems where
 contention on these operations is expected. For most systems running Helix, this is typically not
 the case.
 
Summary
| 
  [Expand]
   Inherited Methods  | 
   
From class
  org.apache.helix.api.accessor.ResourceAccessor
  
   
  
    
    
	 
    
        | 
            
            
            
            
            
            boolean
         | 
        
        dropExternalView(ResourceId resourceId)
        
         drop external view of a resource 
  
   |  
	 
    
        | 
            
            
            
            
            
            boolean
         | 
        
        dropUserConfig(ResourceId resourceId)
        
         Clear any user-specified configuration from the resource 
  
   |  
	 
    
        | 
            
            
            
            
            
            boolean
         | 
        
        generateDefaultAssignment(ResourceId resourceId, int replicaCount, String participantGroupTag)
        
         Generate a default assignment for partitioned resources 
  
   |  
	 
    
        | 
            
            
            
            
            
            ResourceConfiguration
         | 
        
        getConfiguration(ResourceId resourceId)
        
         Get a resource configuration, which may include user-defined configuration, as well as
 rebalancer configuration 
  
   |  
	 
    
        | 
            
            
            
            
            
            ResourceAssignment
         | 
        
        getResourceAssignment(ResourceId resourceId)
        
         get resource assignment 
  
   |  
	 
    
        | 
            
            
            
            
            
            ParticipantAccessor
         | 
        
        participantAccessor()
        
         Get a ParticipantAccessor instance 
  
   |  
	 
    
        | 
            
            
            
            
            
            ExternalView
         | 
        
        readExternalView(ResourceId resourceId)
        
         get the external view of a resource 
  
   |  
	 
    
        | 
            
            
            
            
            
            RebalancerConfig
         | 
        
        readRebalancerConfig(ResourceId resourceId)
        
         Read the rebalancer config of the resource 
  
   |  
	 
    
        | 
            
            
            
            
            
            Resource
         | 
        
        readResource(ResourceId resourceId)
        
         Read a single snapshot of a resource 
  
   |  
	 
    
        | 
            
            
            
            
            
            UserConfig
         | 
        
        readUserConfig(ResourceId resourceId)
        
         Read the user config of the resource 
  
   |  
	 
    
        | 
            
            
            
            
            
            boolean
         | 
        
        resetResources(Set<ResourceId> resetResourceIdSet)
        
         reset resources for all participants 
  
   |  
	 
    
        | 
            
            
            
            
            
            boolean
         | 
        
        setExternalView(ResourceId resourceId, ExternalView extView)
        
         set external view of a resource 
  
   |  
	 
    
        | 
            
            
            
            
            
            boolean
         | 
        
        setRebalancerConfig(ResourceId resourceId, RebalancerConfig config)
        
         Set the config of the rebalancer. 
  
   |  
	 
    
        | 
            
            
            
            
            
            boolean
         | 
        
        setResource(ResourceConfig resourceConfig)
        
         Persist an existing resource's logical configuration 
  
   |  
	 
    
        | 
            
            
            
            
            
            boolean
         | 
        
        setResourceAssignment(ResourceId resourceId, ResourceAssignment resourceAssignment)
        
         save resource assignment 
  
   |  
	 
    
        | 
            
            
            
            
            
            boolean
         | 
        
        setUserConfig(ResourceId resourceId, UserConfig userConfig)
        
         Set the user config of the resource, overwriting existing user configs 
  
   |  
	 
    
        | 
            
            
            
            
            
            ResourceConfig
         | 
        
        updateResource(ResourceId resourceId, ResourceConfig.Delta resourceDelta)
        
         Update a resource configuration 
  
   |  
	 
    
        | 
            
            
            
            
            
            boolean
         | 
        
        updateUserConfig(ResourceId resourceId, UserConfig userConfig)
        
         Add user configuration to the existing resource user configuration. 
  
   |  
 
   
 
 | 
   
From class
  java.lang.Object
  
   
  
    
    
	 
    
        | 
            
            
            
            
            
            Object
         | 
        
        clone()
        
   |  
	 
    
        | 
            
            
            
            
            
            boolean
         | 
        
        equals(Object arg0)
        
   |  
	 
    
        | 
            
            
            
            
            
            void
         | 
        
        finalize()
        
   |  
	 
    
        | 
            
            
            final
            
            
            Class<?>
         | 
        
        getClass()
        
   |  
	 
    
        | 
            
            
            
            
            
            int
         | 
        
        hashCode()
        
   |  
	 
    
        | 
            
            
            final
            
            
            void
         | 
        
        notify()
        
   |  
	 
    
        | 
            
            
            final
            
            
            void
         | 
        
        notifyAll()
        
   |  
	 
    
        | 
            
            
            
            
            
            String
         | 
        
        toString()
        
   |  
	 
    
        | 
            
            
            final
            
            
            void
         | 
        
        wait()
        
   |  
	 
    
        | 
            
            
            final
            
            
            void
         | 
        
        wait(long arg0, int arg1)
        
   |  
	 
    
        | 
            
            
            final
            
            
            void
         | 
        
        wait(long arg0)
        
   |  
 
   
 
 | 
 
Public Constructors
 
    
      
    
      
  
  
      Parameters
      
        
          | clusterId
           | the cluster to access | 
        
        
          | accessor
           | a HelixDataAccessor for the physical properties | 
        
        
          | lockProvider
           | a lock provider
 | 
        
      
   
     
 
Public Methods
 
    
      
        public 
         
         
         
         
        boolean
      
      generateDefaultAssignment
      (ResourceId resourceId, int replicaCount, String participantGroupTag)
    
      
    
      
  Generate a default assignment for partitioned resources
 
  
      Parameters
      
        
          | resourceId
           | the resource to update | 
        
        
          | replicaCount
           | the new replica count (or -1 to use the existing one) | 
        
        
          | participantGroupTag
           | the new participant group tag (or null to use the existing one) | 
        
      
   
  
      Returns
      - true if assignment successful, false otherwise
 
   
     
 
 
    
      
    
      
  Read a single snapshot of a resource
 
  
      Parameters
      
        
          | resourceId
           | the resource id to read | 
        
      
   
  
      Returns
      - Resource or null if not present
 
   
     
 
 
    
      
        public 
         
         
         
         
        boolean
      
      setRebalancerConfig
      (ResourceId resourceId, RebalancerConfig config)
    
      
    
      
  Set the config of the rebalancer. This includes all properties required for rebalancing this
 resource
 
  
      Parameters
      
        
          | resourceId
           | the resource to update | 
        
        
          | config
           | the new rebalancer config | 
        
      
   
  
      Returns
      - true if the config was set, false otherwise
 
   
     
 
 
    
      
        public 
         
         
         
         
        boolean
      
      setResource
      (ResourceConfig resourceConfig)
    
      
    
      
  Persist an existing resource's logical configuration
 
  
      Parameters
      
        
          | resourceConfig
           | logical resource configuration | 
        
      
   
  
      Returns
      - true if resource is set, false otherwise
 
   
     
 
 
    
      
    
      
  Update a resource configuration
 
  
      Parameters
      
        
          | resourceId
           | the resource id to update | 
        
        
          | resourceDelta
           | changes to the resource | 
        
      
   
  
      Returns
      - ResourceConfig, or null if the resource is not persisted
 
   
     
 
Protected Methods
 
    
      
    
      
  Get a ParticipantAccessor instance