question: protected static Long convertUuidToLong ( UUID uuid ) { if ( uuid == null ) { return null ; } Long convertedUuid ; if ( uuid . version ( ) == 1 ) { convertedUuid = uuid . timestamp ( ) ; } else { convertedUuid = uuid . getMostSignificantBits ( ) ; } return convertedUuid ; }
target:  Converts a UUID to a Long for bucketing purposes. Order of input and output values is preserved as long.