Package org.apache.accumulo.core.client
Interface ConditionalWriter
-
- All Superinterfaces:
AutoCloseable
public interface ConditionalWriter extends AutoCloseable
ConditionalWriter provides the ability to do efficient, atomic read-modify-write operations on rows. These operations are performed on the tablet server while a row lock is held.- Since:
- 1.6.0
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static class
ConditionalWriter.Result
static class
ConditionalWriter.Status
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
close()
release any resources (like threads pools) used by conditional writerIterator<ConditionalWriter.Result>
write(Iterator<ConditionalMutation> mutations)
This method returns one result for each mutation passed to it.ConditionalWriter.Result
write(ConditionalMutation mutation)
This method has the same thread safety guarantees aswrite(Iterator)
-
-
-
Method Detail
-
write
Iterator<ConditionalWriter.Result> write(Iterator<ConditionalMutation> mutations)
This method returns one result for each mutation passed to it. This method is thread safe. Multiple threads can safely use a single conditional writer. Sharing a conditional writer between multiple threads may result in batching of request to tablet servers.- Returns:
- Result for each mutation submitted. The mutations may still be processing in the background when this method returns, if so the iterator will block.
-
write
ConditionalWriter.Result write(ConditionalMutation mutation)
This method has the same thread safety guarantees aswrite(Iterator)
- Returns:
- Result for the submitted mutation
-
close
void close()
release any resources (like threads pools) used by conditional writer- Specified by:
close
in interfaceAutoCloseable
-
-