java.lang.AutoCloseable, java.io.Closeablepublic interface Lease
extends java.io.Closeable
InterProcessSemaphore. It is the client's responsibility
to close this lease when it is no longer needed so that other blocked clients can use it. If the
client crashes (or its session expires, etc.) the lease will automatically be closed.| Modifier and Type | Method | Description |
|---|---|---|
void |
close() |
Releases the lease so that other clients/processes can acquire it
|
byte[] |
getData() |
Return the data stored in the node for this lease
|
java.lang.String |
getNodeName() |
Return the the node for this lease
|
void close()
throws java.io.IOException
close in interface java.lang.AutoCloseableclose in interface java.io.Closeablejava.io.IOException - errorsbyte[] getData()
throws java.lang.Exception
java.lang.Exception - errorsjava.lang.String getNodeName()
java.lang.Exception - errorsCopyright © 2011–2018 The Apache Software Foundation. All rights reserved.