|
@@ -259,12 +259,15 @@ public class TaskService {
|
|
|
String tokenUrl = tokenUri + "?grant_type=client_credentials"
|
|
|
+ "&client_id=" + clientId
|
|
|
+ "client_secret" + clientSecret;
|
|
|
+ log.info("------- /state 获取仿真云平台 token:" + tokenUrl);
|
|
|
String response = HttpUtil.get(closeableHttpClient, requestConfig, tokenUrl);
|
|
|
ObjectMapper objectMapper = new ObjectMapper();
|
|
|
JsonNode jsonNode = objectMapper.readTree(response);
|
|
|
String accessToken = jsonNode.path("access_token").asText();
|
|
|
+ log.info("------- /state 仿真云平台 token 为:" + accessToken);
|
|
|
Map<String, String> headers = new HashMap<>();
|
|
|
headers.put("Authorization", "Bearer " + accessToken);
|
|
|
+ log.info("------- /state 访问仿真云平台评价等级接口:" + accessToken);
|
|
|
HttpUtil.post(closeableHttpClient, requestConfig, evaluationLevelUri, headers, null);
|
|
|
|
|
|
|