rholder / guava-retrying

This is a small extension to Google's Guava library to allow for the creation of configurable retrying strategies for an arbitrary function call, such as something that talks to a remote service with flaky uptime.
Apache License 2.0
1.43k stars 275 forks source link

Make RetryListener use a generic type on the interface not on method. #62

Open spjoe opened 8 years ago

spjoe commented 8 years ago
public interface RetryListener {
    <V> void onRetry(Attempt<V> var1);
}

should be:

public interface RetryListener<V> {
    void onRetry(Attempt<V> var1);
}

with this change, withRetryListener would work much more naturally.

Because this is technically a breaking change also a new interface could be introduced and a new method called like withTypedRetryListener