Class Revoker


  • public class Revoker
    extends java.lang.Object
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static void attemptRevoke​(org.apache.curator.framework.CuratorFramework client, java.lang.String path)
      Utility to mark a lock for revocation.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • attemptRevoke

        public static void attemptRevoke​(org.apache.curator.framework.CuratorFramework client,
                                         java.lang.String path)
                                  throws java.lang.Exception
        Utility to mark a lock for revocation. Assuming that the lock has been registered with a RevocationListener, it will get called and the lock should be released. Note, however, that revocation is cooperative.
        Parameters:
        client - the client
        path - the path of the lock - usually from something like InterProcessMutex.getParticipantNodes()
        Throws:
        java.lang.Exception - errors