Pre Merge pull request !3 from bigsun/v1.0.0.0
This commit is contained in:
commit
498c1d5c8b
|
|
@ -9,6 +9,7 @@ import com.dyj.common.client.AuthClient;
|
|||
import com.dyj.common.config.AgentConfiguration;
|
||||
import com.dyj.common.domain.ClientTokenInfo;
|
||||
import com.dyj.common.domain.DyResult;
|
||||
import com.dyj.common.domain.DySimpleResult;
|
||||
import com.dyj.common.domain.query.BaseQuery;
|
||||
import com.dyj.common.domain.query.ClientTokenQuery;
|
||||
import com.dyj.common.domain.vo.ClientTokenVo;
|
||||
|
|
@ -30,7 +31,7 @@ import javax.annotation.Resource;
|
|||
import java.util.Objects;
|
||||
|
||||
@Component
|
||||
public class ClientTokenInterceptor implements Interceptor<DyResult> {
|
||||
public class ClientTokenInterceptor implements Interceptor<DySimpleResult> {
|
||||
private final Log log = LogFactory.getLog(ClientTokenInterceptor.class);
|
||||
@Resource
|
||||
private AuthClient authClient;
|
||||
|
|
|
|||
|
|
@ -68,7 +68,7 @@ public class DyConfigurationRegister implements ResourceLoaderAware, BeanPostPro
|
|||
}
|
||||
String tokenSourceClass = dyConfigurationProperties.getTokenSourceClass();
|
||||
if (StringUtils.hasLength(tokenSourceClass)) {
|
||||
IAgentTokenService agentTokenService = applicationContext.getBean("dyTokenService", IAgentTokenService.class);
|
||||
IAgentTokenService agentTokenService = applicationContext.getBean("dyTokenService", IAgentTokenService.class);
|
||||
configuration.setAgentTokenService(agentTokenService);
|
||||
}
|
||||
//configuration.setInterceptorFactory(DyInterceptorFactory);
|
||||
|
|
@ -77,8 +77,8 @@ public class DyConfigurationRegister implements ResourceLoaderAware, BeanPostPro
|
|||
|
||||
public void setForestProperties() {
|
||||
DyForestConfigurationProperties forestProperties = dyConfigurationProperties.getForest();
|
||||
ForestConfiguration forestConfiguration = applicationContext.getBean(ForestConfiguration.class);
|
||||
if (Objects.nonNull(forestProperties)) {
|
||||
ForestConfiguration forestConfiguration = applicationContext.getBean(ForestConfiguration.class);
|
||||
forestConfiguration.setBackendName(forestProperties.getBackend());
|
||||
forestConfiguration.setMaxConnections(forestProperties.getMaxConnections());
|
||||
forestConfiguration.setMaxRouteConnections(forestProperties.getMaxRouteConnections());
|
||||
|
|
@ -94,20 +94,24 @@ public class DyConfigurationRegister implements ResourceLoaderAware, BeanPostPro
|
|||
forestConfiguration.setLogResponseStatus(forestProperties.isLogResponseStatus());
|
||||
forestConfiguration.setLogResponseContent(forestProperties.isLogResponseContent());
|
||||
forestConfiguration.setAsyncMode(forestProperties.getAsyncMode());
|
||||
for (DyWebUrlPathEnum value : DyWebUrlPathEnum.values()) {
|
||||
forestProperties.getVariables().put(value.getKey(), value.getValue());
|
||||
}
|
||||
for (DyAppletUrlPathEnum value : DyAppletUrlPathEnum.values()){
|
||||
forestProperties.getVariables().put(value.getKey(), value.getValue());
|
||||
}
|
||||
if(StringUtils.hasLength(dyConfigurationProperties.getDomain())){
|
||||
forestProperties.getVariables().put("domain", dyConfigurationProperties.getDomain());
|
||||
}
|
||||
if (StringUtils.hasLength(dyConfigurationProperties.getTtDomain())){
|
||||
forestProperties.getVariables().put("ttDomain", dyConfigurationProperties.getTtDomain());
|
||||
}
|
||||
forestConfiguration.setVariables(forestProperties.getVariables());
|
||||
}
|
||||
if (forestProperties == null) {
|
||||
forestProperties = new DyForestConfigurationProperties();
|
||||
}
|
||||
for (DyWebUrlPathEnum value : DyWebUrlPathEnum.values()) {
|
||||
forestProperties.getVariables().put(value.getKey(), value.getValue());
|
||||
}
|
||||
for (DyAppletUrlPathEnum value : DyAppletUrlPathEnum.values()) {
|
||||
forestProperties.getVariables().put(value.getKey(), value.getValue());
|
||||
}
|
||||
if (StringUtils.hasLength(dyConfigurationProperties.getDomain())) {
|
||||
forestProperties.getVariables().put("domain", dyConfigurationProperties.getDomain());
|
||||
}
|
||||
if (StringUtils.hasLength(dyConfigurationProperties.getTtDomain())) {
|
||||
forestProperties.getVariables().put("ttDomain", dyConfigurationProperties.getTtDomain());
|
||||
}
|
||||
|
||||
forestConfiguration.setVariables(forestProperties.getVariables());
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue