All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.dahua.eco.base.spring.config.RestTemplateProperties Maven / Gradle / Ivy

package com.dahua.eco.base.spring.config;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.PropertySource;

@Configuration
@PropertySource(value = {
        "classpath:application.properties",
        "classpath:config/application.properties",
        "classpath:component.properties",
        "classpath:config/component.properties"
    }, ignoreResourceNotFound = true)
public class RestTemplateProperties {

    @Value("${spring.rest.factory.readTimeout:60000}")
    private Integer readTimeout;

    @Value("${spring.rest.factory.connectTimeout:15000}")
    private Integer connectTimeout;


    @Value("${spring.rest.factory.retryCount:3}")
    private Integer retryCount;

    public Integer getReadTimeout() {
        return readTimeout;
    }

    public void setReadTimeout(Integer readTimeout) {
        this.readTimeout = readTimeout;
    }

    public Integer getConnectTimeout() {
        return connectTimeout;
    }

    public void setConnectTimeout(Integer connectTimeout) {
        this.connectTimeout = connectTimeout;
    }

    public Integer getRetryCount() {
        return retryCount;
    }

    public void setRetryCount(Integer retryCount) {
        this.retryCount = retryCount;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy