潘志宝
3 天以前 f853b02cb7b265379eceb2f0e3c38f9d63bb1b21
执行调度模型 默认时间
已修改2个文件
17 ■■■■ 文件已修改
iailab-module-model/iailab-module-model-biz/src/main/java/com/iailab/module/model/api/MdkApiImpl.java 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
iailab-module-model/iailab-module-model-biz/src/main/java/com/iailab/module/model/mdk/sample/ScheduleSampleInfoConstructor.java 11 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
iailab-module-model/iailab-module-model-biz/src/main/java/com/iailab/module/model/api/MdkApiImpl.java
@@ -249,14 +249,14 @@
    @Override
    public MdkScheduleRespDTO runSchedule(MdkScheduleReqDTO reqDTO) {
        MdkScheduleRespDTO resp = new MdkScheduleRespDTO();
        resp.setScheduleCode(reqDTO.getScheduleCode());
        resp.setScheduleTime(reqDTO.getScheduleTime());
        if (reqDTO.getScheduleTime() == null) {
            Calendar calendar = Calendar.getInstance();
            calendar.set(Calendar.MILLISECOND, 0);
            calendar.set(Calendar.SECOND, 0);
            resp.setScheduleTime(calendar.getTime());
            reqDTO.setScheduleTime(calendar.getTime());
        }
        resp.setScheduleCode(reqDTO.getScheduleCode());
        resp.setScheduleTime(reqDTO.getScheduleTime());
        String catchKey = "ScheduleResult:" + reqDTO.getScheduleCode();
        try {
            if (redisTemplate.hasKey(catchKey)) {
iailab-module-model/iailab-module-model-biz/src/main/java/com/iailab/module/model/mdk/sample/ScheduleSampleInfoConstructor.java
@@ -57,7 +57,7 @@
        // 统一获取计划数据的信息
        Set<String> planIds = modelInputParamEntityList.stream().filter(e -> ModelParamType.getEumByCode(e.getModelparamtype()).equals(ModelParamType.PLAN)).map(StScheduleModelParamEntity::getModelparamid).collect(Collectors.toSet());
        List<ApiPlanItemDTO> plans = planItemApi.getInfoByIds(planIds);
        Map<String, ApiPlanItemDTO> planMap = plans.stream().collect(Collectors.toMap(ApiPlanItemDTO::getId, Function.identity(), (e1,e2) -> e1));
        Map<String, ApiPlanItemDTO> planMap = plans.stream().collect(Collectors.toMap(ApiPlanItemDTO::getId, Function.identity(), (e1, e2) -> e1));
        for (StScheduleModelParamEntity entry : modelInputParamEntityList) {
            columnInfo.setParamType(entry.getModelparamtype());
@@ -65,12 +65,12 @@
            columnInfo.setDataLength(super.getDataLength(dynamicDataLength, entry.getModelparamportorder(), entry.getDatalength()));
            columnInfo.setModelParamOrder(entry.getModelparamorder());
            columnInfo.setModelParamPortOrder(entry.getModelparamportorder());
            columnInfo.setStartTime(getStartTime(columnInfo, predictTime,pointMap,planMap));
            columnInfo.setEndTime(getEndTime(columnInfo, predictTime,pointMap,planMap));
            columnInfo.setGranularity(super.getGranularity(columnInfo,pointMap,planMap));
            columnInfo.setStartTime(getStartTime(columnInfo, predictTime, pointMap, planMap));
            columnInfo.setEndTime(getEndTime(columnInfo, predictTime, pointMap, planMap));
            columnInfo.setGranularity(super.getGranularity(columnInfo, pointMap, planMap));
            //对每一个爪进行数据项归并
            if (curPortOrder != entry.getModelparamportorder()){
            if (curPortOrder != entry.getModelparamportorder()) {
                //当数据项端口号不为当前端口号时,封装上一个端口类,操作下一个端口类
                curPort.setColumnItemList(columnItemList);
                curPort.setDataLength(curDataLength);
@@ -100,7 +100,6 @@
    protected Integer getSampleCycle(String modelId) {
        return null;
    }
}