|
@@ -38,8 +38,6 @@ public class PermissionServiceUpdateMessage {
|
|
|
|
|
|
@Autowired
|
|
|
private DcucAuthConfig dcucAuthConfig;
|
|
|
- @Autowired
|
|
|
- private IServiceAuthResultService serviceAuthResultService;
|
|
|
|
|
|
|
|
|
* 服务变更通知
|
|
@@ -57,18 +55,6 @@ public class PermissionServiceUpdateMessage {
|
|
|
serviceChangeNoticeDto.setContents(dtoList);
|
|
|
|
|
|
sendMessage(serviceChangeNoticeDto);
|
|
|
- for (AppServiceCodeDto appServiceCodeDto : dtoList) {
|
|
|
- List<ServiceAuthResult> results = serviceAuthResultService.serviceAuthResultList(appServiceCodeDto.getAppCode());
|
|
|
- if (StringUtils.isNotEmpty(appServiceCodeDto.getAppCode())) {
|
|
|
-
|
|
|
- List<ServiceAuthenticationResVO> serviceAuthenticationResVOS = new ArrayList<>();
|
|
|
- results.forEach(item -> {
|
|
|
- ServiceAuthenticationResVO vo = new ServiceAuthenticationResVO();
|
|
|
- vo.setServiceCode(item.getServiceCode());
|
|
|
- serviceAuthenticationResVOS.add(vo);
|
|
|
- });
|
|
|
- }
|
|
|
- }
|
|
|
}
|
|
|
|
|
|
|
|
@@ -91,14 +77,14 @@ public class PermissionServiceUpdateMessage {
|
|
|
|
|
|
HttpEntity<ServiceChangeNoticeDto> httpEntity = new HttpEntity<>(dto, headers);
|
|
|
|
|
|
- logger.info("Service permission update request body : {}", JSONUtil.toJsonStr(httpEntity));
|
|
|
+ logger.info("发送服务级权限变更通知, 通知内容 : {}", JSONUtil.toJsonStr(dto));
|
|
|
try {
|
|
|
ResponseMessage result = restTemplate.postForObject(dcucAuthConfig.getServicePermissionUrl(),
|
|
|
httpEntity, ResponseMessage.class);
|
|
|
-
|
|
|
- logger.info("Service permission update response: {} ", JsonUtils.toJSONString(result));
|
|
|
+
|
|
|
+ logger.info("服务级权限变更通知,返回结果: {} ", JsonUtils.toJSONString(result));
|
|
|
} catch (Exception e) {
|
|
|
- logger.error("PermissionUpdateService.sendMessage()请求失败:", e);
|
|
|
+ logger.error("服务级权限变更通知请求失败", e);
|
|
|
}
|
|
|
}
|
|
|
|