Interface ClusterAware


  • @Deprecated
    public interface ClusterAware
    Deprecated.
    The ClusterAware service interface may be implemented by components interested in being made aware of the cluster state or changes thereof the repository on which Sling primarily depends.

    Upon registration and whenever certain changes in the registered JCR Repository service occurs registered services of this type are made aware of the properties of the repository.

    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String SERVICE
      Deprecated.
      The name under which services must be registered.
    • Field Detail

      • SERVICE

        static final java.lang.String SERVICE
        Deprecated.
        The name under which services must be registered.
        See Also:
        Constant Field Values
    • Method Detail

      • unbindRepository

        void unbindRepository()
        Deprecated.
        Informs the service that no repository is currently bound.

        This method is called upon two occasions:

        • When the service is first registered and no repository is bound
        • When a bound repository is unbound and no replacement is bound
      • bindRepository

        void bindRepository​(java.lang.String repositoryId,
                            java.lang.String clusterId,
                            boolean isMaster)
        Deprecated.
        Informs the service on a bound repository.

        This method is called upon three occasions:

        • When the service is first registered and a repository is bound
        • When an existing bound repository is replaced by another bound repository
        • When a repository is being freshly bound
        • When a bound repository changes its master/slave (see isMaster) state.
        Parameters:
        repositoryId - The ID of the repository node upon which Sling is running. If the repository ID is not available from the repository, this parameter is set to null.
        clusterId - The ID of the cluster upon which Sling is running. If the cluster ID is not available from the repository, this parameter is set to null.
        isMaster - true if the main repository is operating as the master node in the cluster. If this parameter is false the node is operating as the slave.