Remove deprecated method Connection.handleRetryAfter()

master
Richard Körber 2025-04-26 12:46:07 +02:00
parent 1dc3c7ad64
commit ba50d4ec72
No known key found for this signature in database
GPG Key ID: AAB9FD19C78AA3E0
1 changed files with 0 additions and 17 deletions

View File

@ -26,7 +26,6 @@ import edu.umd.cs.findbugs.annotations.Nullable;
import org.shredzone.acme4j.Login;
import org.shredzone.acme4j.Session;
import org.shredzone.acme4j.exception.AcmeException;
import org.shredzone.acme4j.exception.AcmeRetryAfterException;
import org.shredzone.acme4j.toolbox.JSON;
import org.shredzone.acme4j.toolbox.JSONBuilder;
@ -156,22 +155,6 @@ public interface Connection extends AutoCloseable {
*/
Optional<Instant> getRetryAfter();
/**
* Throws an {@link AcmeRetryAfterException} if the last status was HTTP Accepted and
* a Retry-After header was received.
*
* @param message
* Message to be sent along with the {@link AcmeRetryAfterException}
* @deprecated Prefer to use {@link #getRetryAfter()}.
*/
@Deprecated
default void handleRetryAfter(String message) throws AcmeException {
var retryAfter = getRetryAfter();
if (retryAfter.isPresent()) {
throw new AcmeRetryAfterException(message, retryAfter.get());
}
}
/**
* Gets the nonce from the nonce header.
*