@Transient
    public boolean isFull() {
        // If we haven't established how many bytes are used on a volume then
        // assume it is not full (could be dangerous but worst case we will get
        // an IO error).
        if (volumeState.getBytesUsed() == null || volumeState.getBytesTotal() == null) {
            return false;
        }

        final long used = volumeState.getBytesUsed();
        final long total = volumeState.getBytesTotal();

        // If a byte limit has been set then ensure it is less than the total
        // number of bytes on the volume and if it is return whether the number
        // of bytes used are greater than this limit.
        if (bytesLimit != null && bytesLimit < total) {
            return volumeState.getBytesUsed() >= bytesLimit;
        }

        // No byte limit has been set by the user so establish the maximum size
        // that we will allow.
        // Choose the higher limit of either the total storage minus 10Gb or 99%
        // of total storage.
        final long minusOneGig = total - TEN_GB;
        final long percentage = (long) (total * NINETY_NINE_PERCENT);
        final long max = Math.max(minusOneGig, percentage);

        return used >= max;
    }
Utility to create a volume.

@param node       to use
@param path       to use
@param volumeType to use
@return volume
stroom-legacy/stroom-legacy-model_6_1/src/main/java/stroom/legacy/model_6_1/Volume.java