Class InstancePending<T>
java.lang.Object
org.apache.hadoop.hbase.zookeeper.InstancePending<T>
Placeholder of an instance which will be accessed by other threads but is not yet created. Thread
safe.
-
Nested Class Summary
-
Field Summary
Modifier and TypeFieldDescriptionprivate InstancePending.InstanceHolder<T>
Piggybacking onpendingLatch
.private final CountDownLatch
-
Constructor Summary
-
Method Summary
-
Field Details
-
pendingLatch
-
instanceHolder
Piggybacking onpendingLatch
.
-
-
Constructor Details
-
InstancePending
-
-
Method Details
-
get
Returns the instance given by the methodprepare(T)
. This is an uninterruptible blocking method and the interruption flag will be set just before returning if any. -
prepare
Associates the given instance for the methodget()
. This method should be called once, andinstance
should be non-null. This method is expected to call as soon as possible because the methodget
is uninterruptibly blocked until this method is called.
-