Authored by chaogeng

update

... ... @@ -9,6 +9,7 @@ import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
import javax.annotation.Resource;
import java.util.ArrayList;
import java.util.List;
... ... @@ -17,7 +18,7 @@ public class RedisHashCache {
private final static Logger logger = LoggerFactory.getLogger(RedisHashCache.class);
@Autowired
@Resource(name="yhHashOperations")
YHHashOperations<String, String, String> yhHashOperations;
/**
... ...
... ... @@ -8,12 +8,14 @@ import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
import javax.annotation.Resource;
@Component
public class RedisListCache {
private static Logger logger = LoggerFactory.getLogger(RedisListCache.class);
@Autowired
@Resource(name="yhListOperations")
YHListOperations<String, String> yhListOperations;
/**
... ...
... ... @@ -43,7 +43,7 @@ public class UnionOrderServiceImpl implements IUnionOrderService {
List<OrderInfo> resList = new ArrayList<OrderInfo>();
Long size = redisListCache.size(UNION_ORDER_KEY);
int sizeInt = size == null ? 0 : size.intValue();
limit = sizeInt < size ? sizeInt : limit;
limit = sizeInt < limit ? sizeInt : limit;
for(int i=0; i < limit; i++){
UnionOrders unionOrder = redisListCache.rightPop(UNION_ORDER_KEY, UnionOrders.class);
logger.info("getUnionOrders: get order list form bigdata redis: key is {}, result is {}", UNION_ORDER_KEY, unionOrder);
... ...
... ... @@ -42,7 +42,7 @@ public class BigDataOrderInfoTask {
@Autowired
IUserOrdersDAO userOrdersDAO;
@Scheduled(cron = "0/10 * * * * ?")
@Scheduled(cron = "* 0/10 * * * ?")
public void run() {
UnionOrderReqVO reqVO = new UnionOrderReqVO();
reqVO.setLimit(20);
... ...
... ... @@ -26,15 +26,13 @@ activeTime_4=24
redis.readonly.proxy.address=test-bigdata-redis-1903805580.cn-north-1.elb.amazonaws.com.cn
redis.readonly.proxy.port=6379
redis.readonly.proxy.auth=
redis.readonly.proxy.database=1
redis.proxy.address=test-bigdata-redis-1903805580.cn-north-1.elb.amazonaws.com.cn
redis.proxy.port=6379
redis.proxy.auth=
redis.notsync.twemproxy.addresses=test-bigdata-redis-1903805580.cn-north-1.elb.amazonaws.com.cn:6379
redis.notsync.twemproxy.auth=
redis.notsync.twemproxy.database=1
redis.proxy.database=1
########## common rabbitmq ##########
#aws
... ...