package com.xiaopeng.common.core.constant; /** * 缓存常量信息 * * @author xiaopeng */ public class CacheConstants { /** * 缓存有效期,默认720(分钟) */ public final static long EXPIRATION = 720 * 2; //24小时 public final static long EXPIRATION_APPLET = 365 * 24 * 60; /** * 缓存刷新时间,默认120(分钟) */ public final static long REFRESH_TIME = 120; /** * 密码最大错误次数 */ public final static int PASSWORD_MAX_RETRY_COUNT = 5; /** * 密码锁定时间,默认10(分钟) */ public final static long PASSWORD_LOCK_TIME = 10; /** * 权限缓存前缀 */ public final static String LOGIN_TOKEN_KEY = "login_tokens:"; /** * 验证码 redis key */ public static final String CAPTCHA_CODE_KEY = "captcha_codes:"; /** * 参数管理 cache key */ public static final String SYS_CONFIG_KEY = "sys_config:"; /** * 字典管理 cache key */ public static final String SYS_DICT_KEY = "sys_dict:"; /** * 登录账户密码错误次数 redis key */ public static final String PWD_ERR_CNT_KEY = "pwd_err_cnt:"; /** * 登录IP黑名单 cache key */ public static final String SYS_LOGIN_BLACKIPLIST = SYS_CONFIG_KEY + "sys.login.blackIPList"; /** * 客服电话 */ public static final String CUSTOMER_SERVICE_PHONE = "CUSTOMER_SERVICE_PHONE"; /** * 最大下单距离 */ public static final String ORDER_DISTANCE = "ORDER_DISTANCE"; /** * 起终点最小距离 */ public static final String MIN_ORDER_DISTANCE ="MIN_ORDER_DISTANCE"; /** * 省市区信息 */ public static final String XP_REGION = "XP_REGION"; /** * 市区信息 */ public static final String XP_REGION_CITY = "XP_REGION_CITY"; /** * 省市区级联树 */ public static final String XP_REGION_CASCADER = "XP_REGION_CASCADER"; /** * 节假日 */ public static final String IS_HOLIDAY= "isHoliday_"; /** * 当天是工作日还是节假日 */ public static final String IS_DAY= "isDay_"; /** * 编号开头 */ public static final String ORD = "ord_"; /** * 队列编号 */ public static final String QUEUE_POINT_ID = "QUEUE_POINT_ID"; /** * 最大推单距离 */ public static final String MAX_PUSH_DISTANCE = "MAX_PUSH_DISTANCE"; /** * 附近点位距离 */ public static final String NEAR_POINT_DISTANCE = "NEAR_POINT_DISTANCE"; /** * 订单车辆位置 */ public static final String ORDER_OLD_LOCATION = "order_old_location:"; /** * 订单车辆轨迹 */ public static final String ORDER_ROUTE = "order_route:"; /** * 订单车辆轨迹,禁止用于其他用处 */ public static final String ORDER_ROUTE_CAPTURE = "order_route_capture:"; /** * 车辆挡位 */ public static final String GEAR_LEVEL = "gear_level:"; /** * 多路线规划快照(选路、下单校验) */ public static final String ORDER_MULTI_ROUTE_SNAPSHOT = "ORDER_MULTI_ROUTE_SNAPSHOT:"; /** * 用户默认路线偏好(高德 strategy) */ public static final String USER_ROUTE_PREFERENCE = "USER_ROUTE_PREFERENCE:"; /** * 重新派单 改派 */ public static final String reassign_Order = "reassign_order"; static final String ORDER_NAVIGATION_END_DATA = "ORDER_NAVIGATION_END_DATA:"; public static String navigationEnd(String key) { return ORDER_NAVIGATION_END_DATA + key; } static final String ORDER_NAVIGATION_START_DATA = "ORDER_NAVIGATION_START_DATA:"; public static String navigationStart(String key) { return ORDER_NAVIGATION_START_DATA + key; } static final String NEXT_ORDER = "NEXT_ORDER:"; public static String nextOrder(String currentOrder) { return NEXT_ORDER + currentOrder; } }