|
|
@@ -57,7 +57,7 @@ public class PreViewedService {
|
|
|
|| CollectionUtils.isEmpty(videos)) {
|
|
|
return;
|
|
|
}
|
|
|
- // 1 更新预曝光数据 过期时间 30min
|
|
|
+ // 1 更新预曝光数据 过期时间 5min
|
|
|
String[] videoIds = new String[videos.size()];
|
|
|
for (int i = 0; i < videoIds.length; i++) {
|
|
|
videoIds[i] = String.valueOf(videos.get(i).getVideoId());
|
|
|
@@ -73,17 +73,17 @@ public class PreViewedService {
|
|
|
/**
|
|
|
* 遍历 preview.exp.config(expCode → minutes),用 judgeHitAlgoExp 判断是否命中(算法层)。
|
|
|
* judgeHitAlgoExp 同时覆盖 abExpCodes 通道和 root.session.id.exp.layer.config.算法 尾号通道。
|
|
|
- * 都不命中 → 默认 30min。
|
|
|
+ * 都不命中 → 默认 5min。
|
|
|
*/
|
|
|
private int resolveExpireMinutes(int appType, String rootSessionId, Set<String> abExpCodes) {
|
|
|
if (MapUtils.isNotEmpty(preViewExpConfig)) {
|
|
|
for (Map.Entry<String, Integer> entry : preViewExpConfig.entrySet()) {
|
|
|
if (experimentService.judgeHitAlgoExp(appType, rootSessionId, abExpCodes, entry.getKey())) {
|
|
|
- return entry.getValue() != null ? entry.getValue() : 30;
|
|
|
+ return entry.getValue() != null ? entry.getValue() : 5;
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
- return 30;
|
|
|
+ return 5;
|
|
|
}
|
|
|
|
|
|
public Set<Long> getVideoIds(int appType, String mid) {
|
|
|
@@ -108,20 +108,20 @@ public class PreViewedService {
|
|
|
|| CollectionUtils.isEmpty(videos)) {
|
|
|
return;
|
|
|
}
|
|
|
- // 1 更新预曝光数据 过期时间 30min
|
|
|
+ // 1 更新预曝光数据 过期时间 5min
|
|
|
String[] videoIds = new String[videos.size()];
|
|
|
for (int i = 0; i < videoIds.length; i++) {
|
|
|
videoIds[i] = String.valueOf(videos.get(i).getVideoId());
|
|
|
}
|
|
|
String key = String.format(SESSION_PRE_VIEWED_FILTER_KEY, appType, mid, sessionId);
|
|
|
|
|
|
- int expire = 30;
|
|
|
+ int expire = 5;
|
|
|
if (MapUtils.isNotEmpty(preViewExpConfig)) {
|
|
|
for (Map.Entry<String, Integer> entry : preViewExpConfig.entrySet()) {
|
|
|
if (CommonCollectionUtils.contains(abExpCodes, entry.getKey())) {
|
|
|
expire = entry.getValue() != null
|
|
|
? entry.getValue()
|
|
|
- : 30;
|
|
|
+ : 5;
|
|
|
break;
|
|
|
}
|
|
|
}
|