|
|
package com.yoho.search.recall.scene.beans.persional;
|
|
|
|
|
|
import com.yoho.core.rest.client.ServiceCaller;
|
|
|
import com.yoho.search.core.personalized.models.UserPersionalFactorReq;
|
|
|
import com.yoho.search.core.personalized.models.UserPersionalFactorRsp;
|
|
|
import com.yoho.search.recall.scene.models.PersionalFactor;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.stereotype.Component;
|
|
|
|
|
|
import java.util.ArrayList;
|
...
|
...
|
@@ -9,6 +13,14 @@ import java.util.List; |
|
|
@Component
|
|
|
class UserPersionalFactorComponent {
|
|
|
|
|
|
@Autowired
|
|
|
private ServiceCaller serviceCaller;
|
|
|
|
|
|
//serviceCaller.asyncCall("message.publishIosUser", iosTokenBO, Integer.class);
|
|
|
|
|
|
private static final String SERVICE_NAME = "bigdata.UserPersionalFactor";
|
|
|
private static final int timeOut = 100;
|
|
|
|
|
|
/**
|
|
|
* 获取用户的个性化因子
|
|
|
*
|
...
|
...
|
@@ -29,5 +41,8 @@ class UserPersionalFactorComponent { |
|
|
return new PersionalFactor(brandIds, sortPriceArea,factor);
|
|
|
}
|
|
|
|
|
|
private UserPersionalFactorRsp queryUserPersionalFactorRsp( UserPersionalFactorReq userPersionalFactorReq){
|
|
|
return serviceCaller.call(SERVICE_NAME,userPersionalFactorReq,UserPersionalFactorRsp.class,timeOut);
|
|
|
}
|
|
|
|
|
|
} |
...
|
...
|
|