Authored by linlong

Merge branch 'master' into hotfix_0307

... ... @@ -35,6 +35,7 @@
<value>/go</value>
<value>/pushUnionOrders</value>
<value>/ClickUnionRest/addUnion4Jump</value>
<value>/ClickUnionRest/addUnion4Jump/goitunes</value>
<value>/PayChannelRest/getChannelType</value>
<value>/UnionRest/addBigData</value>
<value>/tencentMkt/TencentMktController/sendSms</value>
... ...
... ... @@ -23,6 +23,7 @@ import org.apache.commons.lang.StringUtils;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
... ... @@ -174,15 +175,18 @@ public class ClickUnionRest {
}
}
@RequestMapping("/addUnion4Jump")
@RequestMapping(value = {"/addUnion4Jump", "/addUnion4Jump/goitunes"})
public void addUnion4Stream(ClickUnionRequestBO bo, HttpServletRequest request, HttpServletResponse response) {
clickUnion.info("addUnion4Stream ClickUnionRequestBO{}", bo);
if (null == bo || StringUtils.isEmpty(bo.getUnion_type())) {
return;
}
String downloadDirect = "Y";
if(null != request && null != request.getRequestURI() && request.getRequestURI().endsWith("goitunes")){
downloadDirect = "N";
}
String clientIp = null;
String IP = RemoteIPInterceptor.getRemoteIP();
String downloadDirect = bo.getDownloadDirect();
if(StringUtils.isNotEmpty(IP)){
String[] IPS = IP.split(",");
... ... @@ -368,7 +372,7 @@ public class ClickUnionRest {
//response.setHeader("Location",url);
//如果不需要直接下载, 配置参数downloadDirect=N, 跳转应用宝下载
if(null != downloadDirect && "N".equals(downloadDirect.trim())){
url = "http://a.app.qq.com/o/simple.jsp?pkgname=com.yoho&g_f=995445";
url = "https://itunes.apple.com/cn/app/yoho!-you-huo/id490655927?mt=8";
}
response.sendRedirect(url);
} catch (Exception e) {
... ...
... ... @@ -413,6 +413,7 @@ public class UnionServiceImpl implements IUnionService,ApplicationEventPublisher
app_key = "yohomars_ios";
}
List<AppActivateIdfaList> _90DayIdfaList = appActivateIdfaListDAO.selectByUdidAndDate(new AppActivateIdfaList(Long.valueOf(yesterday), request.getUdid(), app_key));
activeUnion.info("check ios active info in 90 days. udid is {} and app_key is {},yesterday is {} and result is {}", request.getUdid(), app_key, yesterday, _90DayIdfaList);
// List<AppActivateIdfaList> _15DayIdfaList = appActivateIdfaListDAO.select15DaysByIdfaAndDate(new AppActivateIdfaList(Long.valueOf(yesterday), request.getUdid(), app_key));
//判断90天内是否在大数据有记录
if (CollectionUtils.isNotEmpty(_90DayIdfaList)) {
... ... @@ -450,6 +451,7 @@ public class UnionServiceImpl implements IUnionService,ApplicationEventPublisher
String appKey = request.getAppkey()+"_android";
// 如果90天内有记录,则直接返回
List<AppActivateUdidList> activateUdidLists = appActivateUdidListDAO.selectByImeiUdidDate(new AppActivateUdidList(Long.valueOf(yesterday), request.getUdid(), appKey));
activeUnion.info("check android active info in 90 days. udid is {} and app_key is {},yesterday is {} and result is {}", request.getUdid(), appKey, yesterday, activateUdidLists);
if (CollectionUtils.isNotEmpty(activateUdidLists)){
log.warn("android activateUnion error because 90 days has activate in bigdata database info with param is {}", request);
... ...