public void put(Object key, RetryContext context) { if (map.size() >= capacity) { throw new RetryCacheCapacityExceededException("Retry cache capacity limit breached. " + "Do you need to re-consider the implementation of the key generator, " + "or the equals and hashCode of the items that failed?"); } map.put(key, context); }
public void put(Object key, RetryContext context) { if (map.size() >= capacity) { throw new RetryCacheCapacityExceededException("Retry cache capacity limit breached. " + "Do you need to re-consider the implementation of the key generator, " + "or the equals and hashCode of the items that failed?"); } map.put(key, new SoftReference<RetryContext>(context)); }
public void put(Object key, RetryContext context) { if (map.size() >= capacity) { throw new RetryCacheCapacityExceededException("Retry cache capacity limit breached. " + "Do you need to re-consider the implementation of the key generator, " + "or the equals and hashCode of the items that failed?"); } map.put(key, context); }
public void put(Object key, RetryContext context) { if (map.size() >= capacity) { throw new RetryCacheCapacityExceededException("Retry cache capacity limit breached. " + "Do you need to re-consider the implementation of the key generator, " + "or the equals and hashCode of the items that failed?"); } map.put(key, new SoftReference<RetryContext>(context)); }