unit = Durations.parse(comps[1]); } else { throw new IllegalArgumentException("Cannot parse time duration from: " + s);
backoffMS = Durations.min(backoffMS.multipliedBy(2), idApplicationWaitMS.multipliedBy(32)); log.warn("Temporary storage exception while acquiring id block - retrying in {}: {}", backoffMS, e); sleepAndConvertInterrupts(backoffMS);
@Override public String toString() { return String.format("Duration[%d %s]", length, Durations.abbreviate(unit)); }
@Override public int compareTo(Duration o) { return Durations.compare(length,unit,o.getLength(o.getNativeUnit()),o.getNativeUnit()); }
@Override public String toString() { return String.format("Timestamp[%d %s]", sinceEpoch, Durations.abbreviate(unit)); }
@Override public int compareTo(Timestamp o) { return Durations.compare(sinceEpoch, unit, o.sinceEpoch(o.getNativeUnit()), o.getNativeUnit()); }
unit = Durations.parse(comps[1]); } else { throw new IllegalArgumentException("Cannot parse time duration from: " + o.toString());
backoffMS = Durations.min(backoffMS.multiply(2), idApplicationWaitMS.multiply(32)); log.warn("Temporary storage exception while acquiring id block - retrying in {}: {}", backoffMS, e); sleepAndConvertInterrupts(backoffMS);
@Override public String toString() { return String.format("Timepoint[%d %s]", sinceEpoch, Durations.abbreviate(getNativeUnit())); } }
unit = Durations.parse(comps[1]); } else { throw new IllegalArgumentException("Cannot parse time duration from: " + s);
backoffMS = Durations.min(backoffMS.multipliedBy(2), idApplicationWaitMS.multipliedBy(32)); log.warn("Temporary storage exception while acquiring id block - retrying in {}: {}", backoffMS, e); sleepAndConvertInterrupts(backoffMS);
unit = Durations.parse(comps[1]); } else { throw new IllegalArgumentException("Cannot parse time duration from: " + o.toString());
unit = Durations.parse(comps[1]); } else { throw new IllegalArgumentException("Cannot parse time duration from: " + o.toString());