martin-g commented on a change in pull request #1186: HBASE-19146 Update
Protobuf to 3.11.4
URL: https://github.com/apache/hbase/pull/1186#discussion_r382009507
##########
File path:
hbase-protocol/src/main/java/com/google/protobuf/HBaseZeroCopyByteString.java
##########
@@ -55,23 +54,6 @@ public static ByteString wrap(final byte[] array) {
* @return wrapped array
*/
public static ByteString wrap(final byte[] array, int offset, int length) {
- return new BoundedByteString(array, offset, length);
- }
-
- // TODO:
- // ZeroCopyLiteralByteString.wrap(this.buf, 0, this.count);
-
- /**
- * Extracts the byte array from the given {@link ByteString} without copy.
- * @param buf A buffer from which to extract the array. This buffer must be
- * actually an instance of a {@code LiteralByteString}.
- * @return byte[] representation
- */
- public static byte[] zeroCopyGetBytes(final ByteString buf) {
Review comment:
This method was not in use by HBase itself and since the class is annotated
with `@InterfaceAudience.Private` I assume it is safe to remove it. If this is
the case then maybe HBaseZeroCopyByteString.java should be removed.
If this method is needed then the only way I see to implement it is by using
Reflection. Please let me know if I should do it!
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services