public long getId() {
        int notUsed = 64 - getUsedBits();
        long usedMask  = (0xFFFFFFFFFFFFFFFFL << notUsed) >>> notUsed;
        long countMask = (0xFFFFFFFFFFFFFFFFL >>> (64 - COUNT_BITS)) << (64 - COUNT_BITS);
        return id & (usedMask | countMask);
    }
Creates a bucket id with the given raw bucket id. This is a 64 bit mask
where the first 6 MSB bits set how many LSB bits should actually be used.
Right now it only have simple functionality. More will be added for it
to be configurable.
document/src/main/java/com/yahoo/document/BucketId.java