Compare commits

...

2 Commits

Author SHA1 Message Date
e23864fa72 [修改]探索如何设置maven镜像源
All checks were successful
CI / Docker-Build (push) Successful in 5m3s
2024-06-11 20:40:34 +08:00
212773e679 [修改]gitea自动构建/发布脚本文件
Some checks failed
CI / Docker-Build (push) Failing after 19m33s
2024-06-11 20:15:21 +08:00
3 changed files with 249 additions and 228 deletions

23
pom.xml
View File

@ -227,5 +227,26 @@
</plugin>
</plugins>
</build>
<repositories>
<repository>
<id>aliyun-central</id>
<url>https://maven.aliyun.com/repository/central</url>
</repository>
<repository>
<id>aliyun-snapshots</id>
<url>https://maven.aliyun.com/repository/snapshots</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>aliyun-central</id>
<url>https://maven.aliyun.com/repository/central</url>
</pluginRepository>
</pluginRepositories>
</project>

View File

@ -27,6 +27,6 @@ public class CgyStatsBO {
private AtomicLong visitor;
//实训人数
private final Set<Long> userSet = new HashSet<>();
//实训时长
//实训时长/s
private AtomicLong duration;
}

View File

@ -98,7 +98,7 @@ public class CgyStatsService {
+ "app_secret=" + statsBO.getAppSecret();
body.put("sign", EncryptUtil.md5(sb).toLowerCase());
//扩展字段
body.put("duration", statsBO.getDuration().get());
body.put("duration", statsBO.getDuration().get() / 60); //分钟
SimulationInfoQueryVO queryVO = new SimulationInfoQueryVO();
queryVO.setFunctionId(statsBO.getFunctionId());
List<SimulationInfoVO> sims = simulationService.listAllSimulation(queryVO);
@ -108,7 +108,7 @@ public class CgyStatsService {
httpHeaders.setContentType(MediaType.APPLICATION_JSON);
HttpEntity<Map<String, Object>> httpEntity = new HttpEntity<>(body, httpHeaders);
Map<String, String> resBody = restTemplate.postForObject(
"https://common-dev.educloudxr.com/api/applicationCenter/openapi/summary", httpEntity,
"http://gdjtapp.cdivtc.edu.cn/api/applicationCenter/openapi/summary", httpEntity,
Map.class);
if (resBody != null && Objects.equals(resBody.get("code"), "100001")) {
log.error(String.format("成工院虚仿平台同步数据失败:[%s][%s]", resBody.get("msg"),