Search in sources :

Example 1 with Retryer

use of com.dtflys.forest.annotation.Retryer in project forest by dromara.

the class RetryerLifeCycle method onInvokeMethod.

@Override
public void onInvokeMethod(ForestRequest request, ForestMethod method, Object[] args) {
    Retryer annotation = (Retryer) request.getMethod().getExtensionParameterValue(PARAM_KEY_RETRYER);
    Class<? extends ForestRetryer> clazz = annotation.value();
    request.setRetryer(clazz);
}
Also used : ForestRetryer(com.dtflys.forest.retryer.ForestRetryer) Retryer(com.dtflys.forest.annotation.Retryer)

Aggregations

Retryer (com.dtflys.forest.annotation.Retryer)1 ForestRetryer (com.dtflys.forest.retryer.ForestRetryer)1