public static byte[] getRandomBytes() {
        final byte[] requestContext = new byte[ThreadLocalRandom.current().nextInt(10) + 1];
        ThreadLocalRandom.current().nextBytes(requestContext);
        return requestContext;
    }
Test helper

@author boyan (boyan@alibaba-inc.com)

2018-Apr-11 10:16:07 AM
jraft-extension/java-log-storage-impl/src/test/java/com/alipay/sofa/jraft/test/TestUtils.java