Explorar o código

去除数据库相关代码 仅保留client功能

juxin_zhenghao hai 9 horas
pai
achega
b26e27c39e

+ 11 - 11
pom.xml

@@ -65,17 +65,17 @@
             <version>5.8.1</version>
         </dependency>
 
-        <dependency>
-            <groupId>mysql</groupId>
-            <artifactId>mysql-connector-java</artifactId>
-        </dependency>
-
-        <!-- 阿里数据库连接池 -->
-        <dependency>
-            <groupId>com.alibaba</groupId>
-            <artifactId>druid-spring-boot-starter</artifactId>
-            <version>1.2.11</version>
-        </dependency>
+<!--        <dependency>-->
+<!--            <groupId>mysql</groupId>-->
+<!--            <artifactId>mysql-connector-java</artifactId>-->
+<!--        </dependency>-->
+
+<!--        &lt;!&ndash; 阿里数据库连接池 &ndash;&gt;-->
+<!--        <dependency>-->
+<!--            <groupId>com.alibaba</groupId>-->
+<!--            <artifactId>druid-spring-boot-starter</artifactId>-->
+<!--            <version>1.2.11</version>-->
+<!--        </dependency>-->
 
         <dependency>
             <groupId>junit</groupId>

+ 10 - 2
src/main/java/com/juxin/client/ClientApplication.java

@@ -3,11 +3,19 @@ package com.juxin.client;
 import org.mybatis.spring.annotation.MapperScan;
 import org.springframework.boot.SpringApplication;
 import org.springframework.boot.autoconfigure.SpringBootApplication;
+import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration;
+import org.springframework.boot.autoconfigure.jdbc.DataSourceTransactionManagerAutoConfiguration;
+import org.springframework.boot.autoconfigure.orm.jpa.HibernateJpaAutoConfiguration;
 import org.springframework.scheduling.annotation.EnableScheduling;
 
-@SpringBootApplication
+
 @EnableScheduling
-@MapperScan(basePackages = "com.juxin.**.mapper")
+//@MapperScan(basePackages = "com.juxin.**.mapper")
+@SpringBootApplication(exclude = {
+        DataSourceAutoConfiguration.class,
+        DataSourceTransactionManagerAutoConfiguration.class,
+        HibernateJpaAutoConfiguration.class
+})
 public class ClientApplication {
 
     public static void main(String[] args) {

+ 17 - 17
src/main/java/com/juxin/client/rpa/mapper/MachineLicenseMapper.java

@@ -1,17 +1,17 @@
-package com.juxin.client.rpa.mapper;
-
-import com.juxin.client.rpa.dto.MachineLicenseFilterDto;
-import com.juxin.client.rpa.dto.MachineLicensePo;
-import org.apache.ibatis.annotations.Mapper;
-import org.springframework.stereotype.Repository;
-
-import java.util.List;
-
-@Mapper
-public interface MachineLicenseMapper {
-    void insert(MachineLicensePo po);
-
-    List<MachineLicensePo> selectMachineLicense(MachineLicenseFilterDto dto);
-    void update(MachineLicensePo po);
-    void deleteByPrimaryKey(Long id);
-}
+//package com.juxin.client.rpa.mapper;
+//
+//import com.juxin.client.rpa.dto.MachineLicenseFilterDto;
+//import com.juxin.client.rpa.dto.MachineLicensePo;
+//import org.apache.ibatis.annotations.Mapper;
+//import org.springframework.stereotype.Repository;
+//
+//import java.util.List;
+//
+//@Mapper
+//public interface MachineLicenseMapper {
+//    void insert(MachineLicensePo po);
+//
+//    List<MachineLicensePo> selectMachineLicense(MachineLicenseFilterDto dto);
+//    void update(MachineLicensePo po);
+//    void deleteByPrimaryKey(Long id);
+//}

+ 79 - 79
src/main/java/com/juxin/client/rpa/test/LicenseManager.java

@@ -1,84 +1,84 @@
-package com.juxin.client.rpa.test;
-
-import com.google.gson.Gson;
-import com.juxin.client.rpa.constant.TaieOcConstants;
-import com.juxin.client.rpa.constant.TaieOcManageCode;
-import com.juxin.client.rpa.dto.DubboResult;
-import com.juxin.client.rpa.dto.MachineLicenseAcquireReqDto;
-import com.juxin.client.rpa.dto.MachineLicensePo;
-import com.juxin.client.rpa.dto.MachineLicenseRespDto;
-import com.juxin.client.rpa.mapper.MachineLicenseMapper;
-import com.juxin.client.rpa.utils.SM2Utils;
-import lombok.extern.slf4j.Slf4j;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-import org.springframework.transaction.interceptor.TransactionAspectSupport;
-
-import java.text.SimpleDateFormat;
-import java.util.Calendar;
-import java.util.Date;
-
-@Service
-@Slf4j
-public class LicenseManager {
-    private static final Gson gson = new Gson();
-
-    @Autowired
-    private MachineLicenseMapper machineLicenseMapper;
-
-    public DubboResult<MachineLicenseRespDto> createLicense(MachineLicenseAcquireReqDto reqDto, String datetime) {
-        // 根据机器信息判定是否需要登录
-        DubboResult<MachineLicenseRespDto> result;
-        try {
-            SimpleDateFormat sdf = new SimpleDateFormat(TaieOcConstants.DATE_LONG_FORMAT);
-//            Calendar cal = Calendar.getInstance();
-//            cal.add(Calendar.YEAR, licenseExpireDate);
-//          时间戳毫秒设置为零,对应处理入库时间预防 秒级四舍五入情况,导致入库时间+1s,导致rpa登录校验失败
-//            cal.set(Calendar.MILLISECOND, 0); //毫秒
+//package com.juxin.client.rpa.test;
+//
+//import com.google.gson.Gson;
+//import com.juxin.client.rpa.constant.TaieOcConstants;
+//import com.juxin.client.rpa.constant.TaieOcManageCode;
+//import com.juxin.client.rpa.dto.DubboResult;
+//import com.juxin.client.rpa.dto.MachineLicenseAcquireReqDto;
+//import com.juxin.client.rpa.dto.MachineLicensePo;
+//import com.juxin.client.rpa.dto.MachineLicenseRespDto;
+//import com.juxin.client.rpa.mapper.MachineLicenseMapper;
+//import com.juxin.client.rpa.utils.SM2Utils;
+//import lombok.extern.slf4j.Slf4j;
+//import org.springframework.beans.factory.annotation.Autowired;
+//import org.springframework.stereotype.Service;
+//import org.springframework.transaction.interceptor.TransactionAspectSupport;
+//
+//import java.text.SimpleDateFormat;
+//import java.util.Calendar;
+//import java.util.Date;
+//
+//@Service
+//@Slf4j
+//public class LicenseManager {
+//    private static final Gson gson = new Gson();
+//
+//    @Autowired
+//    private MachineLicenseMapper machineLicenseMapper;
+//
+//    public DubboResult<MachineLicenseRespDto> createLicense(MachineLicenseAcquireReqDto reqDto, String datetime) {
+//        // 根据机器信息判定是否需要登录
+//        DubboResult<MachineLicenseRespDto> result;
+//        try {
 //            SimpleDateFormat sdf = new SimpleDateFormat(TaieOcConstants.DATE_LONG_FORMAT);
-//            DubboResult<SmartRobotDto> smartRobotResult = robotManager.queryRobotByKey(reqDto.getMachineCode() + reqDto.getUser());
-//            if (!smartRobotResult.success()) {
-//                return DubboResult.newFailure(smartRobotResult.getCode(), smartRobotResult.getMessage());
-//            }
-            // 先判断是否获取过license信息
-//            List<MachineLicensePo> machineLicensePos = machineLicenseMapper.selectMachineLicense(MachineLicenseFilterDto.MachineLicenseFilterBuilder()
+////            Calendar cal = Calendar.getInstance();
+////            cal.add(Calendar.YEAR, licenseExpireDate);
+////          时间戳毫秒设置为零,对应处理入库时间预防 秒级四舍五入情况,导致入库时间+1s,导致rpa登录校验失败
+////            cal.set(Calendar.MILLISECOND, 0); //毫秒
+////            SimpleDateFormat sdf = new SimpleDateFormat(TaieOcConstants.DATE_LONG_FORMAT);
+////            DubboResult<SmartRobotDto> smartRobotResult = robotManager.queryRobotByKey(reqDto.getMachineCode() + reqDto.getUser());
+////            if (!smartRobotResult.success()) {
+////                return DubboResult.newFailure(smartRobotResult.getCode(), smartRobotResult.getMessage());
+////            }
+//            // 先判断是否获取过license信息
+////            List<MachineLicensePo> machineLicensePos = machineLicenseMapper.selectMachineLicense(MachineLicenseFilterDto.MachineLicenseFilterBuilder()
+////                    .machineKey(reqDto.getMachineCode() + reqDto.getUser())
+////                    .licenseType(reqDto.getLicenseType())
+////                    .machineType(reqDto.getMachineType())
+////                    .requestParam(reqDto.getParamsMap() == null ? TaieOcConstants.EMPTY_STRING : gson.toJson(reqDto.getParamsMap()))
+////                    .build());
+////            if (CollectionUtils.isNotEmpty(machineLicensePos)) {
+////                return DubboResult.newSuccess(machineLicensePos.get(0).createRespDto(smartRobotResult.getObject().getAuthState()));
+////            }
+//            // 获取license信息
+////            Date endTime = cal.getTime();
+//            Date endTime = sdf.parse(datetime);
+//            String license = SM2Utils.generateLicense(reqDto.getLicenseType(), reqDto.getMachineType()
+//                    , sdf.format(endTime), reqDto.getParamsMap());
+//
+//            // license申请信息落库
+//            MachineLicensePo licensePo = MachineLicensePo.builder()
+//                    .license(license)
 //                    .machineKey(reqDto.getMachineCode() + reqDto.getUser())
-//                    .licenseType(reqDto.getLicenseType())
 //                    .machineType(reqDto.getMachineType())
 //                    .requestParam(reqDto.getParamsMap() == null ? TaieOcConstants.EMPTY_STRING : gson.toJson(reqDto.getParamsMap()))
+//                    .startTime(Calendar.getInstance().getTime())
+//                    .endTime(endTime)
+//                    .licenseType(reqDto.getLicenseType())
+//                    .build();
+//            machineLicenseMapper.insert(licensePo);
+//            log.info("入库许可数据信息licensePo = {MachineLicensePo@7487} \"MachineLicensePo(id=null, machineKey=PE3ZVJ9NS9592TJS6XG06CREWC3ZP9T3FHAD5TVCXSPAN50872M0admin, machineType=design, license=3045022054ae9fe57b7bb8c0489bd435e7c1c18e128d9fb0a6351ea381065226060c2bc6022100a2882713d129f247d30cef9a80a57f55810215997f9a4c4005c4f2d9cf90b219==2026-01-01 00:00:00, licenseType=local, startTime=Thu Aug 28 17:49:00 GMT+08:00 2025, endTime=Thu Jan 01 00:00:00 GMT+08:00 2026, isValid=0, requestParam=)\":" + licensePo);
+//            result = DubboResult.newSuccess(MachineLicenseRespDto.builder()
+//                    .license(license)
+//                    .licenseType(reqDto.getLicenseType())
+//                    .expireTime(sdf.format(endTime))
 //                    .build());
-//            if (CollectionUtils.isNotEmpty(machineLicensePos)) {
-//                return DubboResult.newSuccess(machineLicensePos.get(0).createRespDto(smartRobotResult.getObject().getAuthState()));
-//            }
-            // 获取license信息
-//            Date endTime = cal.getTime();
-            Date endTime = sdf.parse(datetime);
-            String license = SM2Utils.generateLicense(reqDto.getLicenseType(), reqDto.getMachineType()
-                    , sdf.format(endTime), reqDto.getParamsMap());
-
-            // license申请信息落库
-            MachineLicensePo licensePo = MachineLicensePo.builder()
-                    .license(license)
-                    .machineKey(reqDto.getMachineCode() + reqDto.getUser())
-                    .machineType(reqDto.getMachineType())
-                    .requestParam(reqDto.getParamsMap() == null ? TaieOcConstants.EMPTY_STRING : gson.toJson(reqDto.getParamsMap()))
-                    .startTime(Calendar.getInstance().getTime())
-                    .endTime(endTime)
-                    .licenseType(reqDto.getLicenseType())
-                    .build();
-            machineLicenseMapper.insert(licensePo);
-            log.info("入库许可数据信息licensePo = {MachineLicensePo@7487} \"MachineLicensePo(id=null, machineKey=PE3ZVJ9NS9592TJS6XG06CREWC3ZP9T3FHAD5TVCXSPAN50872M0admin, machineType=design, license=3045022054ae9fe57b7bb8c0489bd435e7c1c18e128d9fb0a6351ea381065226060c2bc6022100a2882713d129f247d30cef9a80a57f55810215997f9a4c4005c4f2d9cf90b219==2026-01-01 00:00:00, licenseType=local, startTime=Thu Aug 28 17:49:00 GMT+08:00 2025, endTime=Thu Jan 01 00:00:00 GMT+08:00 2026, isValid=0, requestParam=)\":" + licensePo);
-            result = DubboResult.newSuccess(MachineLicenseRespDto.builder()
-                    .license(license)
-                    .licenseType(reqDto.getLicenseType())
-                    .expireTime(sdf.format(endTime))
-                    .build());
-            return result;
-        } catch (Exception e) {
-            e.printStackTrace();
-            log.error(e.getMessage(), e);
-            TransactionAspectSupport.currentTransactionStatus().setRollbackOnly();
-            return DubboResult.newFailure(TaieOcManageCode.LICENSE_AQUIRE.getCode(), TaieOcManageCode.LICENSE_AQUIRE.getMessage());
-        }
-    }
-}
+//            return result;
+//        } catch (Exception e) {
+//            e.printStackTrace();
+//            log.error(e.getMessage(), e);
+//            TransactionAspectSupport.currentTransactionStatus().setRollbackOnly();
+//            return DubboResult.newFailure(TaieOcManageCode.LICENSE_AQUIRE.getCode(), TaieOcManageCode.LICENSE_AQUIRE.getMessage());
+//        }
+//    }
+//}

+ 44 - 44
src/main/java/com/juxin/client/rpa/test/Test.java

@@ -1,44 +1,44 @@
-package com.juxin.client.rpa.test;
-
-import com.juxin.client.rpa.dto.DubboResult;
-import com.juxin.client.rpa.dto.MachineLicenseAcquireReqDto;
-import com.juxin.client.rpa.dto.MachineLicenseRespDto;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.scheduling.annotation.Scheduled;
-import org.springframework.stereotype.Component;
-
-@Component
-
-public class Test {
-    @Autowired
-    private  LicenseManager licenseManager;
-
-    //@Scheduled(cron = "30 19 18 * * ?")
-    public void test() {
-        MachineLicenseAcquireReqDto reqDto = new MachineLicenseAcquireReqDto();
-        reqDto.setMachineCode("72QXCN8B79JZZC40DKZPJVXTFEFJ4F8Z1BT039R555FT37C1J3Q0");
-        reqDto.setUser("adminstrator");
-        String datetime = "2026-01-01 00:00:00";
-//        designLocal
-        reqDto.setLicenseType("local");
-        reqDto.setMachineType("design");
-        System.out.println("执行入参:" + reqDto);
-        DubboResult<MachineLicenseRespDto> designLocal = licenseManager.createLicense(reqDto,datetime);
-
-        //design remote
-        reqDto.setLicenseType("remote");
-        System.out.println("执行入参:" + reqDto);
-        DubboResult<MachineLicenseRespDto> designRemote = licenseManager.createLicense(reqDto,datetime);
-
-//        executor remote
-        reqDto.setMachineType("executor");
-        System.out.println("执行入参:" + reqDto);
-        DubboResult<MachineLicenseRespDto> executorRemote = licenseManager.createLicense(reqDto,datetime);
-
-//        executor local
-        reqDto.setLicenseType("local");
-        System.out.println("执行入参:" + reqDto);
-        DubboResult<MachineLicenseRespDto> executorLocal = licenseManager.createLicense(reqDto,datetime);
-        //Assert.assertNotNull(1);
-    }
-}
+//package com.juxin.client.rpa.test;
+//
+//import com.juxin.client.rpa.dto.DubboResult;
+//import com.juxin.client.rpa.dto.MachineLicenseAcquireReqDto;
+//import com.juxin.client.rpa.dto.MachineLicenseRespDto;
+//import org.springframework.beans.factory.annotation.Autowired;
+//import org.springframework.scheduling.annotation.Scheduled;
+//import org.springframework.stereotype.Component;
+//
+//@Component
+//
+//public class Test {
+//    @Autowired
+//    private  LicenseManager licenseManager;
+//
+//    //@Scheduled(cron = "30 19 18 * * ?")
+//    public void test() {
+//        MachineLicenseAcquireReqDto reqDto = new MachineLicenseAcquireReqDto();
+//        reqDto.setMachineCode("72QXCN8B79JZZC40DKZPJVXTFEFJ4F8Z1BT039R555FT37C1J3Q0");
+//        reqDto.setUser("adminstrator");
+//        String datetime = "2026-01-01 00:00:00";
+////        designLocal
+//        reqDto.setLicenseType("local");
+//        reqDto.setMachineType("design");
+//        System.out.println("执行入参:" + reqDto);
+//        DubboResult<MachineLicenseRespDto> designLocal = licenseManager.createLicense(reqDto,datetime);
+//
+//        //design remote
+//        reqDto.setLicenseType("remote");
+//        System.out.println("执行入参:" + reqDto);
+//        DubboResult<MachineLicenseRespDto> designRemote = licenseManager.createLicense(reqDto,datetime);
+//
+////        executor remote
+//        reqDto.setMachineType("executor");
+//        System.out.println("执行入参:" + reqDto);
+//        DubboResult<MachineLicenseRespDto> executorRemote = licenseManager.createLicense(reqDto,datetime);
+//
+////        executor local
+//        reqDto.setLicenseType("local");
+//        System.out.println("执行入参:" + reqDto);
+//        DubboResult<MachineLicenseRespDto> executorLocal = licenseManager.createLicense(reqDto,datetime);
+//        //Assert.assertNotNull(1);
+//    }
+//}

+ 24 - 24
src/main/resources/application.yml

@@ -1,26 +1,26 @@
 server:
   port: 9995
-spring:
-  datasource:
-    type: com.alibaba.druid.pool.DruidDataSource
-    driverClassName: com.mysql.cj.jdbc.Driver
-    druid:
-      url: jdbc:mysql://localhost:9994/driver?useUnicode=true&characterEncoding=utf8&useSSL=false&serverTimezone=Asia/Shanghai&allowMultiQueries=true
-      username: root
-      password: hS#$Fik8g9f2d0a6ie
-      # 初始连接数
-      initialSize: 10
-      # 最小连接池数量
-      minIdle: 5
-      # 最大连接池数量
-      maxActive: 50
-      # 配置获取连接等待超时的时间
-      maxWait: 60000
-      # 配置间隔多久才进行一次检测,检测需要关闭的空闲连接,单位是毫秒
-      timeBetweenEvictionRunsMillis: 60000
-      # 配置一个连接在池中最小生存的时间,单位是毫秒
-      minEvictableIdleTimeMillis: 300000
-      # 配置一个连接在池中最大生存的时间,单位是毫秒
-      maxEvictableIdleTimeMillis: 900000
-mybatis-plus:
-  mapper-locations: classpath:mapper/*.xml
+#spring:
+#  datasource:
+#    type: com.alibaba.druid.pool.DruidDataSource
+#    driverClassName: com.mysql.cj.jdbc.Driver
+#    druid:
+#      url: jdbc:mysql://localhost:9994/driver?useUnicode=true&characterEncoding=utf8&useSSL=false&serverTimezone=Asia/Shanghai&allowMultiQueries=true
+#      username: root
+#      password: hS#$Fik8g9f2d0a6ie
+#      # 初始连接数
+#      initialSize: 10
+#      # 最小连接池数量
+#      minIdle: 5
+#      # 最大连接池数量
+#      maxActive: 50
+#      # 配置获取连接等待超时的时间
+#      maxWait: 60000
+#      # 配置间隔多久才进行一次检测,检测需要关闭的空闲连接,单位是毫秒
+#      timeBetweenEvictionRunsMillis: 60000
+#      # 配置一个连接在池中最小生存的时间,单位是毫秒
+#      minEvictableIdleTimeMillis: 300000
+#      # 配置一个连接在池中最大生存的时间,单位是毫秒
+#      maxEvictableIdleTimeMillis: 900000
+#mybatis-plus:
+#  mapper-locations: classpath:mapper/*.xml

+ 40 - 40
src/main/resources/com/juxin/client/rpa/mapper/MachineLicenseMapper.xml

@@ -1,43 +1,43 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
-<mapper namespace="com.juxin.client.rpa.mapper.MachineLicenseMapper">
-    <resultMap id="MachineLicensePo" type="com.juxin.client.rpa.dto.MachineLicensePo">
-        <id column="id" jdbcType="BIGINT" property="id" />
-        <result column="machine_key" jdbcType="VARCHAR" property="machineKey" />
-        <result column="machine_type" jdbcType="VARCHAR" property="machineType" />
-        <result column="license" jdbcType="VARCHAR" property="license"/>
-        <result column="license_type" jdbcType="VARCHAR" property="licenseType" />
-        <result column="start_time" jdbcType="TIMESTAMP" property="startTime" />
-        <result column="end_time" jdbcType="TIMESTAMP" property="endTime" />
-        <result column="is_valid" jdbcType="BIT" property="isValid" />
-        <result column="request_param" jdbcType="VARCHAR" property="requestParam" />
-    </resultMap>
+<!--<?xml version="1.0" encoding="UTF-8" ?>-->
+<!--<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >-->
+<!--<mapper namespace="com.juxin.client.rpa.mapper.MachineLicenseMapper">-->
+<!--    <resultMap id="MachineLicensePo" type="com.juxin.client.rpa.dto.MachineLicensePo">-->
+<!--        <id column="id" jdbcType="BIGINT" property="id" />-->
+<!--        <result column="machine_key" jdbcType="VARCHAR" property="machineKey" />-->
+<!--        <result column="machine_type" jdbcType="VARCHAR" property="machineType" />-->
+<!--        <result column="license" jdbcType="VARCHAR" property="license"/>-->
+<!--        <result column="license_type" jdbcType="VARCHAR" property="licenseType" />-->
+<!--        <result column="start_time" jdbcType="TIMESTAMP" property="startTime" />-->
+<!--        <result column="end_time" jdbcType="TIMESTAMP" property="endTime" />-->
+<!--        <result column="is_valid" jdbcType="BIT" property="isValid" />-->
+<!--        <result column="request_param" jdbcType="VARCHAR" property="requestParam" />-->
+<!--    </resultMap>-->
 
-    <sql id="Base_Column_List">
-        `id`, `machine_key`, `machine_type`, `license`, `license_type`, `start_time`,`end_time`, `is_valid`, `request_param`
-    </sql>
+<!--    <sql id="Base_Column_List">-->
+<!--        `id`, `machine_key`, `machine_type`, `license`, `license_type`, `start_time`,`end_time`, `is_valid`, `request_param`-->
+<!--    </sql>-->
 
-    <insert id="insert" parameterType="com.juxin.client.rpa.dto.MachineLicensePo">
-        insert into smart_rpa_machine_license_info (`machine_key`, `machine_type`, `license`, `license_type`, `start_time`,`end_time`, `is_valid`,`request_param`)
-            values (#{machineKey},#{machineType},#{license},#{licenseType},#{startTime},#{endTime},1,#{requestParam})
-    </insert>
+<!--    <insert id="insert" parameterType="com.juxin.client.rpa.dto.MachineLicensePo">-->
+<!--        insert into smart_rpa_machine_license_info (`machine_key`, `machine_type`, `license`, `license_type`, `start_time`,`end_time`, `is_valid`,`request_param`)-->
+<!--            values (#{machineKey},#{machineType},#{license},#{licenseType},#{startTime},#{endTime},1,#{requestParam})-->
+<!--    </insert>-->
 
-    <update id="deleteByPrimaryKey" parameterType="java.lang.Long">
-        update smart_rpa_machine_license_info
-          set is_valid = 0
-        where id = #{id} and is_valid = 1
-    </update>
-    <sql id="filter">
-        <if test="machineKey != null">and machine_key = #{machineKey}</if>
-        <if test="license != null">and license = #{license}</if>
-        <if test="licenseType != null">and license_type = #{licenseType}</if>
-        <if test="requestParam != null">and request_param = #{requestParam}</if>
-        <if test="machineType != null">and machine_type = #{machineType}</if>
-    </sql>
-    <select id = "selectMachineLicense" parameterType="com.juxin.client.rpa.dto.MachineLicenseFilterDto" resultMap="MachineLicensePo">
-        select <include refid="Base_Column_List" />
-            from smart_rpa_machine_license_info where is_valid and end_time > now()
-        <include refid="filter"></include>
-         order by start_time desc
-    </select>
-</mapper>
+<!--    <update id="deleteByPrimaryKey" parameterType="java.lang.Long">-->
+<!--        update smart_rpa_machine_license_info-->
+<!--          set is_valid = 0-->
+<!--        where id = #{id} and is_valid = 1-->
+<!--    </update>-->
+<!--    <sql id="filter">-->
+<!--        <if test="machineKey != null">and machine_key = #{machineKey}</if>-->
+<!--        <if test="license != null">and license = #{license}</if>-->
+<!--        <if test="licenseType != null">and license_type = #{licenseType}</if>-->
+<!--        <if test="requestParam != null">and request_param = #{requestParam}</if>-->
+<!--        <if test="machineType != null">and machine_type = #{machineType}</if>-->
+<!--    </sql>-->
+<!--    <select id = "selectMachineLicense" parameterType="com.juxin.client.rpa.dto.MachineLicenseFilterDto" resultMap="MachineLicensePo">-->
+<!--        select <include refid="Base_Column_List" />-->
+<!--            from smart_rpa_machine_license_info where is_valid and end_time > now()-->
+<!--        <include refid="filter"></include>-->
+<!--         order by start_time desc-->
+<!--    </select>-->
+<!--</mapper>-->