package org.springblade.thirdparty.ocr.config;

import feign.Request;
import feign.RequestInterceptor;
import org.springblade.thirdparty.ocr.interceptor.OCRRequestInterceptor;
import org.springframework.context.annotation.Bean;

import java.util.concurrent.TimeUnit;

/**
 * @author bfhuange
 * @since 2024/12/18
 */
public class OCRFeignClientConfig {
    @Bean
    public RequestInterceptor requestInterceptor() {
        return new OCRRequestInterceptor();
    }

    @Bean
    public Request.Options options() {
        return new Request.Options(10, TimeUnit.SECONDS, 60, TimeUnit.SECONDS, true);
    }
}
