startup error

master
yixian 5 years ago
parent 257f3c2572
commit 8e25f25888

@ -24,7 +24,6 @@ import java.util.stream.Collectors;
@Service @Service
public class PriorityListManagerImpl implements PriorityListManager { public class PriorityListManagerImpl implements PriorityListManager {
private static final String PRIORITY_ID = "id1_priority"; private static final String PRIORITY_ID = "id1_priority";
private static final String COLLECTION_NAME = "settle_priority_modify";
public static final String KEY_WHITELIST_CLIENTS = "whitelist_clients"; public static final String KEY_WHITELIST_CLIENTS = "whitelist_clients";
private final Logger logger = LoggerFactory.getLogger(getClass()); private final Logger logger = LoggerFactory.getLogger(getClass());
private final MerchantInfoProvider mchInfoProvider; private final MerchantInfoProvider mchInfoProvider;

@ -10,9 +10,12 @@ import com.alibaba.fastjson.JSONException;
import com.alibaba.fastjson.JSONObject; import com.alibaba.fastjson.JSONObject;
import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Value; import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.web.client.RestTemplateBuilder;
import org.springframework.data.redis.core.StringRedisTemplate; import org.springframework.data.redis.core.StringRedisTemplate;
import org.springframework.http.MediaType; import org.springframework.http.MediaType;
import org.springframework.http.RequestEntity; import org.springframework.http.RequestEntity;
import org.springframework.http.converter.ByteArrayHttpMessageConverter;
import org.springframework.http.converter.StringHttpMessageConverter;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import org.springframework.web.client.RestClientException; import org.springframework.web.client.RestClientException;
import org.springframework.web.client.RestClientResponseException; import org.springframework.web.client.RestClientResponseException;
@ -37,12 +40,15 @@ public class SettleTaskServiceImpl implements SettleTasksService {
public SettleTaskServiceImpl(SysSettlePlanMapper planMapper, StringRedisTemplate redisTemplate, public SettleTaskServiceImpl(SysSettlePlanMapper planMapper, StringRedisTemplate redisTemplate,
MerchantInfoProvider mchInfoProvider, @Value("${app.redis.prefix}") String prefix, MerchantInfoProvider mchInfoProvider, @Value("${app.redis.prefix}") String prefix,
RestTemplate restTemplate, @Value("${platform.services.transaction:http://127.0.0.1:6012}") String transactionHost) { @Value("${platform.services.transaction:http://127.0.0.1:6012}") String transactionHost) {
this.planMapper = planMapper; this.planMapper = planMapper;
this.redisTemplate = redisTemplate; this.redisTemplate = redisTemplate;
this.mchInfoProvider = mchInfoProvider; this.mchInfoProvider = mchInfoProvider;
this.prefix = prefix; this.prefix = prefix;
this.restTemplate = restTemplate; this.restTemplate = new RestTemplateBuilder()
.messageConverters(new ByteArrayHttpMessageConverter(),
new StringHttpMessageConverter(StandardCharsets.UTF_8))
.build();
this.transactionHost = transactionHost; this.transactionHost = transactionHost;
} }

Loading…
Cancel
Save