aweisberg commented on code in PR #3299:
URL: https://github.com/apache/cassandra/pull/3299#discussion_r1972007491


##########
src/java/org/apache/cassandra/dht/LocalPartitioner.java:
##########
@@ -49,9 +55,28 @@ public DecoratedKey decorateKey(ByteBuffer key)
         return new CachedHashDecoratedKey(getToken(key), key);
     }
 
-    public Token midpoint(Token left, Token right)
+    /**
+     * Convert a ByteBuffer containing the most significant of 'sigbytes' bytes
+     * representing a big-endian magnitude into a BigInteger.
+     */
+    private BigInteger bigForByteBuffer(ByteBuffer buffer, int sigbytes)
     {
-        throw new UnsupportedOperationException();
+        byte[] b = new byte[sigbytes];
+        buffer.get(b, buffer.position(), buffer.remaining());
+        return new BigInteger(1, b);
+    }
+
+    public Token midpoint(Token lt, Token rt)

Review Comment:
   No it's dead code from a different version of an interval tree



-- 
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.

To unsubscribe, e-mail: pr-unsubscr...@cassandra.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: pr-unsubscr...@cassandra.apache.org
For additional commands, e-mail: pr-h...@cassandra.apache.org

Reply via email to