增加token验证失败异常信息

This commit is contained in:
ajaxfan
2021-04-21 09:44:39 +08:00
parent 88170027a6
commit 0966f4c4ef
7 changed files with 124 additions and 12 deletions

View File

@ -0,0 +1,22 @@
package com.chinaunicom.ebtp.mall.cloud.attachment.sdk.fallback;
import org.springframework.stereotype.Component;
import com.chinaunicom.ebtp.mall.cloud.attachment.sdk.service.DocumentDataService;
import feign.Response;
@Component
public class DocumentDataServiceFallback implements DocumentDataService {
@Override
public Response get(String fileId) {
return null;
}
// @Override
// public Response get() {
// return null;
// }
}

View File

@ -0,0 +1,22 @@
package com.chinaunicom.ebtp.mall.cloud.attachment.sdk.service;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;
import com.chinaunicom.ebtp.mall.cloud.attachment.sdk.fallback.DocumentDataServiceFallback;
import feign.Response;
/**
* 文档中心数据服务客户端
*
* @author Ajaxfan
*/
@FeignClient(value = "${document.data.service.id}", fallback = DocumentDataServiceFallback.class)
public interface DocumentDataService {
@GetMapping("v1.0/files/downloadResponse")
Response get(@RequestParam("fileId") String fileId);
}

View File

@ -6,4 +6,5 @@ server.max-http-header-size=2048576
# document center id
document.center.service.id=core-service-document-center
document.data.service.id=core-service-document-center
document.center.ip-address=http://10.242.31.158:8806/doc/