13693261870
2025-07-07 ecee75f72d6e14ef15e31c3c6da22601a3658abb
去除fme日志
已修改11个文件
114 ■■■■ 文件已修改
pom.xml 7 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
se-system/pom.xml 19 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
se-system/src/main/java/com/terra/system/SeSystemApplication.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
se-system/src/main/java/com/terra/system/config/InitConfig.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
se-system/src/main/java/com/terra/system/config/ScheduleConfig.java 23 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
se-system/src/main/java/com/terra/system/config/SwaggerConfig.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
se-system/src/main/java/com/terra/system/config/WebConfig.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
se-system/src/main/java/com/terra/system/mapper/sys/AttachMapper.java 16 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
se-system/src/main/java/com/terra/system/service/sys/AttachService.java 21 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
se-system/src/main/resources/mapper/data/UploadMapper.xml 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
se-system/src/main/resources/mapper/sys/AttachMapper.xml 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
pom.xml
@@ -111,13 +111,6 @@
                <version>${tomcat.version}</version>
            </dependency>
            <!-- Springdoc webmvc 依赖配置 -->
            <dependency>
                <groupId>org.springdoc</groupId>
                <artifactId>springdoc-openapi-ui</artifactId>
                <version>${springdoc.version}</version>
            </dependency>
            <!-- pagehelper 分页插件 -->
            <dependency>
                <groupId>com.github.pagehelper</groupId>
se-system/pom.xml
@@ -34,12 +34,6 @@
            <groupId>com.alibaba.cloud</groupId>
            <artifactId>spring-cloud-starter-alibaba-sentinel</artifactId>
        </dependency>
        <!-- SpringBoot Actuator -->
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-actuator</artifactId>
        </dependency>
@@ -122,6 +116,11 @@
            <groupId>io.springfox</groupId>
            <artifactId>springfox-swagger-ui</artifactId>
            <version>2.9.2</version>
        </dependency>
        <dependency>
            <groupId>com.google.guava</groupId>
            <artifactId>guava</artifactId>
            <version>27.0-jre</version>
        </dependency>
        <!--httpclient-->
@@ -217,6 +216,14 @@
            <version>1.19.0</version>
        </dependency>
        <!-- se-common -->
        <!--dependency>
            <groupId>com.terra</groupId>
            <artifactId>se-common</artifactId>
            <version>1.0.2</version>
            <scope>compile</scope>
        </dependency-->
    </dependencies>
    <build>
se-system/src/main/java/com/terra/system/SeSystemApplication.java
@@ -2,6 +2,8 @@
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.annotation.EnableAspectJAutoProxy;
import org.springframework.scheduling.annotation.EnableAsync;
import springfox.documentation.swagger2.annotations.EnableSwagger2;
/**
@@ -11,7 +13,9 @@
 *
 * @author admin
 */
@EnableAsync
@EnableSwagger2
@EnableAspectJAutoProxy(exposeProxy = true)
@SpringBootApplication(scanBasePackages = {"com.terra.system.*"})
public class SeSystemApplication
{
se-system/src/main/java/com/terra/system/config/InitConfig.java
@@ -58,7 +58,7 @@
            argsService.initSettingData();
            log.info("***************** 系统启动完毕 *****************" + "\n");
            log.info("API文档:http://localhost:" + serverPort + contextPath + "/swagger-ui.html");
            log.info("API文档:http://localhost:" + serverPort + "/swagger-ui.html");
            String autoQuery = env.getProperty("sys.autoQuery");
            if (StaticData.S1.equals(autoQuery)) {
se-system/src/main/java/com/terra/system/config/ScheduleConfig.java
@@ -100,27 +100,4 @@
            log.error(ex.getMessage(), ex);
        }
    }
    /**
     * 同步附件
     */
    @Scheduled(fixedRate = 30 * 1000)
    public void syncAttaches() {
        try {
            List<FmeLogEntity> list = attachService.selectFmeLogs();
            if (isBusy || null == list || list.isEmpty()) {
                return;
            }
            isBusy = true;
            for (FmeLogEntity entity : list) {
                attachService.syncAttaches(entity);
                attachService.updateFmeLog(entity.getId());
            }
            isBusy = false;
        } catch (Exception ex) {
            isBusy = false;
            log.error(ex.getMessage(), ex);
        }
    }
}
se-system/src/main/java/com/terra/system/config/SwaggerConfig.java
@@ -59,8 +59,8 @@
    private ApiInfo apiInfo() {
        return new ApiInfoBuilder()
                .title("Spring Boot接口API")
                .description("Spring Boot接口API查看")
                .title("接口API")
                .description("接口API")
                .version("1.0").build();
    }
}
se-system/src/main/java/com/terra/system/config/WebConfig.java
@@ -66,7 +66,7 @@
    /**
     * 跨域请求
     */
    @Override
    /*@Override
    protected void addCorsMappings(CorsRegistry registry) {
        registry.addMapping("/**")
                .allowCredentials(true)
@@ -74,7 +74,7 @@
                .allowedMethods("GET", "POST", "PUT", "DELETE", "OPTIONS")
                .allowedHeaders("*")
                .maxAge(3600);
    }
    }*/
    /**
     * 添加统一的拦截器
se-system/src/main/java/com/terra/system/mapper/sys/AttachMapper.java
@@ -140,22 +140,6 @@
    public Integer updates(List<AttachEntity> list);
    /**
     * 查询FME日志
     *
     * @param tabs
     * @return
     */
    public List<FmeLogEntity> selectFmeLogs(String tabs);
    /**
     * 更新FME日志
     *
     * @param id ID
     * @return
     */
    public Integer updateFmeLog(Integer id);
    /**
     * 根据元数据名称插入附件
     *
     * @param tab
se-system/src/main/java/com/terra/system/service/sys/AttachService.java
@@ -106,27 +106,6 @@
    }
    @Override
    public List<FmeLogEntity> selectFmeLogs(String tabs) {
        return attachMapper.selectFmeLogs(tabs);
    }
    /**
     * 查询FME日志
     */
    public List<FmeLogEntity> selectFmeLogs() {
        if (StringHelper.isEmpty(tabs)) {
            tabs = UploadAttachService.getTabs().replace("'", "");
        }
        return attachMapper.selectFmeLogs(tabs);
    }
    @Override
    public Integer updateFmeLog(Integer id) {
        return attachMapper.updateFmeLog(id);
    }
    @Override
    public Integer insertAttachByMeta(String tab, String tabGuid, String metaName, String dirid) {
        return attachMapper.insertAttachByMeta(tab, tabGuid, metaName, dirid);
    }
se-system/src/main/resources/mapper/data/UploadMapper.xml
@@ -19,8 +19,4 @@
    <select id="selectProject" resultType="com.terra.system.entity.data.DirEntity">
        select * from lf.sys_dir where pid = 0 and id > 1 order by order_num, code;
    </select>
    <select id="selectFmeLog" resultType="com.terra.system.entity.data.FmeLogEntity">
        select * from lf.sys_fme_log where parentid = #{parentid};
    </select>
</mapper>
se-system/src/main/resources/mapper/sys/AttachMapper.xml
@@ -104,16 +104,6 @@
        </foreach>
    </update>
    <!-- where count > 0 and update_time is null and create_time > now()::timestamp + '-5 min' and position(tcdm in '${tabs}') > 0; -->
    <select id="selectFmeLogs" resultType="com.terra.system.entity.data.FmeLogEntity">
        select * from lf.sys_fme_log
        where count > 0 and update_time is null and position(tcdm in '${tabs}') > 0;
    </select>
    <update id="updateFmeLog">
        update lf.sys_fme_log set update_time = now() where id = #{id};
    </update>
    <!-- and create_time > now()::timestamp + '-15 min' -->
    <insert id="insertAttachByMeta">
        insert into lf.sys_attach (name, guid, path, sizes, create_user, tab, tab_guid)