pom.xml 13 KB
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
    <parent>
        <groupId>com.zteits.boot</groupId>
        <artifactId>parking-framework</artifactId>
        <version>${revision}</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>parking-legacy-common</artifactId>
    <packaging>jar</packaging>

    <name>${project.artifactId}</name>
    <description>
        存量公共库:老工程 zteits-framework 的 com.clouds.common.* 原样落位。

        ⚠️ 这里**故意不是** parking-common 的一部分,包名也保留 com.clouds.common:
        - 存量 6000+ 个类里写死了 import com.clouds.common.*,改包名要动全仓
        - 它的 spring 配置类(RedisConfig/RedissonConfig/ControllerExceptionHandler 等)
          与 parking-framework 的 @AutoConfiguration 是两套东西,混在一起会出现重复 Bean

        所以它是一个**边界清晰的兼容层**:只允许被存量业务模块依赖,
        新写的 parking-module-* 代码不要碰它。P8 老模块下线时整个模块删除。

        P2 的验收标准之一「dependency:tree 里没有 dubbo」就靠这个模块守住:
        它 import 的 com.alibaba.dubbo.* 已在 tools/p2_strip_dubbo.py 里全部替换掉。
    </description>

    <dependencies>
        <!-- 存量 api 契约(老 zteits-api)。依赖方向与老工程一致:
             zteits-framework → zteits-api -->
        <dependency>
            <groupId>com.zteits.boot</groupId>
            <artifactId>parking-module-api</artifactId>
        </dependency>
        <dependency>
            <groupId>com.zteits.boot</groupId>
            <artifactId>parking-common</artifactId>
        </dependency>

        <!-- 新框架的登录态。只有 com.clouds.common.web.auth.LoginUserBridge 用它
             (把 Spring Security 的 LoginUser 适配成存量 UserInfo,见该类注释),
             但方向不能反:security starter 不依赖本模块,所以不会成环。
             ⚠️ 是 compile scope,会传递给所有依赖本模块的存量业务模块 —— 这正好也解决了
                「业务模块要用 @PreAuthorize、而 security 在 starter-mybatis 里是 provided
                不传递」的问题。 -->
        <dependency>
            <groupId>com.zteits.boot</groupId>
            <artifactId>parking-spring-boot-starter-security</artifactId>
        </dependency>

        <!-- 存量代码的两把瑞士军刀(原先是 Dubbo 带进来的,Dubbo 已移除,必须显式声明)。
             ⚠️ 必须是 commons-collections4 那一份:Spring 的 CollectionUtils 没有
             isNotEmpty,而存量代码有 938 处调用(详见 tools/p2_strip_dubbo.py)。
             这两个都是 compile scope,会传递给所有依赖本模块的存量业务模块。 -->
        <dependency>
            <groupId>org.apache.commons</groupId>
            <artifactId>commons-lang3</artifactId>
        </dependency>
        <dependency>
            <groupId>org.apache.commons</groupId>
            <artifactId>commons-collections4</artifactId>
        </dependency>
        <!-- 老 commons-lang 2.x(org.apache.commons.lang,与 lang3 两套并存)。
             存量 15 个文件 import 它调 isBlank/isNotBlank。
             ⚠️ 版本必须由 BOM 管成 2.2:不管就会被 barcode4j → commons-cli:1.0
                拖到 commons-lang:1.0,而 1.0 没有 isBlank/isNotBlank。详见 BOM 里的说明。 -->
        <dependency>
            <groupId>commons-lang</groupId>
            <artifactId>commons-lang</artifactId>
        </dependency>

        <!-- Web / Spring -->
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-web</artifactId>
        </dependency>
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-aop</artifactId>
        </dependency>
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-data-redis</artifactId>
        </dependency>
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-validation</artifactId>
        </dependency>
        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-messaging</artifactId>
        </dependency>

        <!-- 缓存 / 锁 -->
        <dependency>
            <groupId>org.redisson</groupId>
            <artifactId>redisson-spring-boot-starter</artifactId>
        </dependency>

        <!-- 存量第三方(版本全部在 parking-dependencies 的「存量兼容依赖」段) -->
        <dependency>
            <groupId>com.xiaoleilu</groupId>
            <artifactId>hutool-all</artifactId>
        </dependency>
        <dependency>
            <groupId>cn.hutool</groupId>
            <artifactId>hutool-all</artifactId>
        </dependency>
        <dependency>
            <groupId>com.google.guava</groupId>
            <artifactId>guava</artifactId>
        </dependency>
        <dependency>
            <groupId>org.apache.httpcomponents</groupId>
            <artifactId>httpclient</artifactId>
        </dependency>
        <dependency>
            <groupId>com.squareup.okhttp</groupId>
            <artifactId>okhttp</artifactId>
        </dependency>
        <dependency>
            <groupId>com.squareup.okhttp3</groupId>
            <artifactId>okhttp</artifactId>
        </dependency>
        <dependency>
            <groupId>com.squareup.okio</groupId>
            <artifactId>okio</artifactId>
        </dependency>
        <!-- 存量业务模块用到的两个「平台级」第三方,放这里让 7 个存量模块都能继承到
             (老工程是每个模块 pom 各写一遍,新工程收口到这一处;P8 随本模块一起删):
             - xxl-job:105 个存量 Job
             - rocketmq:51 个存量生产者/消费者(中兴 fork 的阿里云 ONS 版)
             - enclosed 计费引擎:zteits-bill 的云计费依赖 com.zteits.charge.* -->
        <dependency>
            <groupId>com.xuxueli</groupId>
            <artifactId>xxl-job-core</artifactId>
        </dependency>
        <dependency>
            <groupId>com.zteits.rocketmq</groupId>
            <artifactId>spring-boot-starter-rocketmq</artifactId>
        </dependency>
        <dependency>
            <groupId>com.zteits.enclosed</groupId>
            <artifactId>zteits-parking-charge-spring-boot-starter</artifactId>
        </dependency>
        <dependency>
            <groupId>com.google.code.gson</groupId>
            <artifactId>gson</artifactId>
        </dependency>
        <dependency>
            <groupId>com.thoughtworks.xstream</groupId>
            <artifactId>xstream</artifactId>
        </dependency>
        <dependency>
            <groupId>com.nimbusds</groupId>
            <artifactId>nimbus-jose-jwt</artifactId>
        </dependency>
        <dependency>
            <groupId>io.jsonwebtoken</groupId>
            <artifactId>jjwt</artifactId>
        </dependency>
        <dependency>
            <groupId>com.sign</groupId>
            <artifactId>sign</artifactId>
        </dependency>
        <dependency>
            <groupId>io.swagger</groupId>
            <artifactId>swagger-annotations</artifactId>
            <version>1.5.6</version>
        </dependency>

        <!-- 支付 -->
        <dependency>
            <groupId>com.alipay.sdk</groupId>
            <artifactId>alipay-sdk-java</artifactId>
        </dependency>
        <dependency>
            <groupId>com.nuonuo</groupId>
            <artifactId>open-sdk</artifactId>
        </dependency>
        <dependency>
            <groupId>com.hgsoft.zengzhiyingyong</groupId>
            <artifactId>secure-sdk</artifactId>
        </dependency>
        <dependency>
            <groupId>cn.jpush.api</groupId>
            <artifactId>jpush-client</artifactId>
        </dependency>
        <dependency>
            <groupId>cn.jpush.api</groupId>
            <artifactId>jiguang-common</artifactId>
        </dependency>
        <dependency>
            <groupId>com.hub</groupId>
            <artifactId>client-sdk</artifactId>
        </dependency>

        <!-- 阿里云:OSS / ONS / 短信 / 号码认证 -->
        <dependency>
            <groupId>com.aliyun.oss</groupId>
            <artifactId>aliyun-sdk-oss</artifactId>
        </dependency>
        <dependency>
            <groupId>com.aliyun.openservices</groupId>
            <artifactId>ons-client</artifactId>
        </dependency>
        <dependency>
            <groupId>com.aliyun</groupId>
            <artifactId>aliyun-java-sdk-core</artifactId>
        </dependency>
        <dependency>
            <groupId>com.aliyun</groupId>
            <artifactId>aliyun-java-sdk-dypnsapi</artifactId>
        </dependency>
        <dependency>
            <groupId>com.aliyun</groupId>
            <artifactId>alibabacloud-dysmsapi20170525</artifactId>
        </dependency>

        <!-- 文件 / 报表 / 文档 -->
        <dependency>
            <groupId>com.github.tobato</groupId>
            <artifactId>fastdfs-client</artifactId>
        </dependency>
        <dependency>
            <groupId>net.lingala.zip4j</groupId>
            <artifactId>zip4j</artifactId>
        </dependency>
        <dependency>
            <groupId>com.jcraft</groupId>
            <artifactId>jsch</artifactId>
        </dependency>
        <dependency>
            <groupId>commons-net</groupId>
            <artifactId>commons-net</artifactId>
        </dependency>
        <dependency>
            <groupId>net.sourceforge.javacsv</groupId>
            <artifactId>javacsv</artifactId>
        </dependency>
        <dependency>
            <groupId>org.apache.poi</groupId>
            <artifactId>poi-ooxml</artifactId>
        </dependency>
        <dependency>
            <groupId>net.sourceforge.dynamicreports</groupId>
            <artifactId>dynamicreports-core</artifactId>
        </dependency>
        <dependency>
            <groupId>net.sourceforge.dynamicreports</groupId>
            <artifactId>dynamicreports-adhoc</artifactId>
        </dependency>
        <dependency>
            <groupId>com.lowagie</groupId>
            <artifactId>itext</artifactId>
        </dependency>
        <dependency>
            <groupId>com.google.zxing</groupId>
            <artifactId>core</artifactId>
        </dependency>
        <dependency>
            <groupId>com.google.zxing</groupId>
            <artifactId>javase</artifactId>
        </dependency>

        <!-- 存量里「只有个别模块用」的几门外围技术,同样收口到这里,避免 7 个业务模块
             各写一遍(老工程就是各写一遍,版本还漂了)。都是 compile scope:
             · mail      —— park/pay 的 MailService(@Autowired JavaMailSender + javax.mail.*)
             · httpmime  —— park 的 HttpsUtil 发 multipart 请求
             · ecs       —— system 的阿里云 ECS 服务器监控
             · cxf/axis  —— pay 的两套发票 webservice 客户端(两套并存,见 BOM 里的说明) -->
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-mail</artifactId>
        </dependency>
        <dependency>
            <groupId>org.apache.httpcomponents</groupId>
            <artifactId>httpmime</artifactId>
        </dependency>
        <!-- ⚠️ 与 httpclient 4.5.2 成对锁死 4.4.4:httpclient 4.5.2 的类带了 4.4.4 才有的
             @org.apache.http.annotation.ThreadSafe,被 Boot 管到 4.4.16 会编译不过。
             详见 BOM 里的说明。 -->
        <dependency>
            <groupId>org.apache.httpcomponents</groupId>
            <artifactId>httpcore</artifactId>
        </dependency>
        <dependency>
            <groupId>com.aliyun</groupId>
            <artifactId>aliyun-java-sdk-ecs</artifactId>
        </dependency>
        <dependency>
            <groupId>org.apache.cxf</groupId>
            <artifactId>cxf-rt-frontend-jaxws</artifactId>
        </dependency>
        <dependency>
            <groupId>org.apache.axis</groupId>
            <artifactId>axis</artifactId>
        </dependency>
        <dependency>
            <groupId>javax.xml</groupId>
            <artifactId>jaxrpc-api</artifactId>
        </dependency>

        <!-- 老 tk.mybatis 的 MyMapper 标记接口(provided,不进 Jar) -->
        <dependency>
            <groupId>tk.mybatis</groupId>
            <artifactId>mapper</artifactId>
        </dependency>

        <dependency>
            <groupId>org.projectlombok</groupId>
            <artifactId>lombok</artifactId>
            <scope>provided</scope>
        </dependency>
    </dependencies>

</project>