Skip to content

Commit 6f91c71

Browse files
committed
HBASE-28001: Add request attribute support to BufferedMutator (apache#6076) (addendum)
Add default implementations of the new methods so that a custom implementation of AsyncBufferedMutatorBuilder will not fail to compile after upgrade.
1 parent 5e2bb4b commit 6f91c71

File tree

1 file changed

+14
-2
lines changed

1 file changed

+14
-2
lines changed

hbase-client/src/main/java/org/apache/hadoop/hbase/client/AsyncBufferedMutatorBuilder.java

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -106,13 +106,25 @@ default AsyncBufferedMutatorBuilder setMaxRetries(int maxRetries) {
106106

107107
/**
108108
* Set a rpc request attribute.
109+
* <p>
110+
* Introduced in 2.6.1. Any custom implementations of this class should implement this method
111+
* in order to take advantage of the new behavior.
112+
* </p>
109113
*/
110-
AsyncBufferedMutatorBuilder setRequestAttribute(String key, byte[] value);
114+
default AsyncBufferedMutatorBuilder setRequestAttribute(String key, byte[] value) {
115+
throw new UnsupportedOperationException("Not implemented");
116+
}
111117

112118
/**
113119
* Set multiple rpc request attributes.
120+
* <p>
121+
* Introduced in 2.6.1. Any custom implementations of this class should implement this method
122+
* in order to take advantage of the new behavior.
123+
* </p>
114124
*/
115-
AsyncBufferedMutatorBuilder setRequestAttributes(Map<String, byte[]> requestAttributes);
125+
default AsyncBufferedMutatorBuilder setRequestAttributes(Map<String, byte[]> requestAttributes) {
126+
throw new UnsupportedOperationException("Not implemented");
127+
}
116128

117129
/**
118130
* Create the {@link AsyncBufferedMutator} instance.

0 commit comments

Comments
 (0)