public static boolean isPowerOfTwo(final int value) {
        return (value & (value - 1)) == 0;
    }
Is this value a power of two.

@param value to be tested to see if it is a power of two
@return true if the value is a power of 2 otherwise false
jraft-core/src/main/java/com/alipay/sofa/jraft/util/Ints.java