3

我正在研究从 Oracle JDK 8 到 OpenJDK 12 的 JDK 迁移。我已经解决了构建时的所有问题。但我在构建过程中收到以下警告,

  1. 无法为 com.sun.xml.bind:jaxb-core:jar:2.2.11 构建父项目 2. com.sun.xml.bind:jaxb-core:jar:2.2.11 传递依赖项的 POM 无效(如果有) 将不可用
  2. 无法为 com.sun.xml.bind:jaxb-impl:jar:2.2.11 构建父项目
  3. com.sun.xml.bind:jaxb-impl:jar:2.2.11 的 POM 无效,传递依赖项(如果有)将不可用。

事件虽然我已将 JAXB jar 更新到 2.3.0,但我想知道它如何显示与 2.211 相关的版本。请分享你的想法。

我已将 JAXB jar 升级到最新版本。但这对解决问题没有帮助。

请参考下面给出的POM,

<?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">
<modelVersion>4.0.0</modelVersion>

<groupId>com.migration.app</groupId>
<artifactId>StudentManagement</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>jar</packaging>



<repositories>

    <repository>
        <id>jaxb-api-libs</id>
        <url>http://repo.maven.apache.org/maven2/</url>
    </repository>


    <repository>
        <id>liteda-jco-libs</id>
        <url>http://nexus.liteda.lt/content/groups/public/</url>
    </repository>
    <!-- repository> <id>vaadin-addons</id> 
    <url>http://maven.vaadin.com/vaadin-addons</url> 
        </repository -->
    <repository>
        <id>jenkins</id>
        <name>Jenkins Repository</name>
        <url>http://repo.jenkins-ci.org/releases</url>
        <snapshots>
            <enabled>false</enabled>
        </snapshots>
    </repository>
</repositories>

  <parent>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-parent</artifactId>
    <version>1.4.5.RELEASE</version>
    <relativePath /> <!-- lookup parent from repository -->
  </parent>

  <properties>
    <sap.jco.version>3.0.15</sap.jco.version>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <project.reporting.outputEncoding>UTF- 
    8</project.reporting.outputEncoding>
    <!-- <maven.compiler.source>12</maven.compiler.source> 
    <maven.compiler.target>12</maven.compiler.target> -->
    <java.version>12</java.version>
    <lib.directory>${project.build.directory}/lib</lib.directory>
    <native.lib.directory>${lib.directory}/${envClassifier} 
    </native.lib.directory>     
    <maven.compiler.source>12</maven.compiler.source>
    <maven.compiler.target>12</maven.compiler.target>
</properties>

<dependencyManagement>
    <dependencies>
        <!-- /////////////////////////////////////////////// -->
        <!-- Vaadin -->
        <!-- /////////////////////////////////////////////// -->
        <dependency>
            <groupId>com.vaadin</groupId>
            <artifactId>vaadin-bom</artifactId>
            <version>7.7.3</version>
            <type>pom</type>
            <scope>import</scope>
        </dependency>
    </dependencies>
</dependencyManagement>

<dependencies>
    <!-- /////////////////////////////////////////////// -->
    <!-- SAP J/CO API -->
    <!-- /////////////////////////////////////////////// -->
    <dependency>
        <groupId>org.hibersap</groupId>
        <artifactId>sapjco3</artifactId>
        <version>${sap.jco.version}</version>           
    </dependency>
    <!-- /////////////////////////////////////////////// -->
    <!-- Java Mail -->
    <!-- /////////////////////////////////////////////// -->
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-mail</artifactId>
        <version>1.5.3.RELEASE</version>
    </dependency>


    <!-- /////////////////////////////////////////////// -->
    <!-- Vaadin -->
    <!-- /////////////////////////////////////////////// -->
    <dependency>
        <groupId>com.vaadin</groupId>
        <artifactId>vaadin-spring-boot-starter</artifactId>
        <version>1.1.0</version>
    </dependency>
    <dependency>
        <groupId>com.vaadin</groupId>
        <artifactId>vaadin-spring</artifactId>
        <version>1.1.0</version>
    </dependency>


    <dependency>
        <groupId>com.vaadin</groupId>
        <artifactId>vaadin-themes</artifactId>
    </dependency>
    <dependency>
        <groupId>com.google.guava</groupId>
        <artifactId>guava</artifactId>
        <version>19.0-rc2</version>
    </dependency>
    <dependency>
        <groupId>com.vaadin</groupId>
        <artifactId>vaadin-treegrid</artifactId>
        <version>0.7.3</version>
    </dependency>
    <dependency>
        <groupId>org.vaadin.spring.extensions</groupId>
        <artifactId>vaadin-spring-ext-core</artifactId>
        <version>0.0.7.RELEASE</version>
    </dependency>
    <dependency>
        <groupId>org.vaadin.spring.extensions</groupId>
        <artifactId>vaadin-spring-ext-boot</artifactId>
        <version>0.0.7.RELEASE</version>
    </dependency>
    <dependency>
        <groupId>org.vaadin.spring.extensions</groupId>
        <artifactId>vaadin-spring-ext-security</artifactId>
        <version>0.0.7.RELEASE</version>
    </dependency>
    <dependency>
        <groupId>org.vaadin.spring.addons</groupId>
        <artifactId>vaadin-spring-addon-eventbus</artifactId>
        <version>0.0.7.RELEASE</version>
    </dependency>

    <!-- /////////////////////////////////////////////// -->
    <!-- Spring + Camel -->
    <!-- /////////////////////////////////////////////// -->
    <!-- <dependency> <groupId>org.springframework.cloud</groupId> 
    <artifactId>spring-cloud-config-server</artifactId> 
        <version>1.1.3.RELEASE</version> </dependency> -->
    <dependency>
        <groupId>org.apache.camel</groupId>
        <artifactId>camel-spring-boot-starter</artifactId>
        <version>2.18.0</version>
    </dependency>
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-data-jpa</artifactId>
    </dependency>
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-data-rest</artifactId>
    </dependency>
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-hateoas</artifactId>
    </dependency>
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-actuator</artifactId>
    </dependency>

    <!-- /////////////////////////////////////////////// -->
    <!-- Utils -->
    <!-- /////////////////////////////////////////////// -->
    <dependency>
        <groupId>org.projectlombok</groupId>
        <artifactId>lombok</artifactId>
        <version>1.18.8</version>
    </dependency>
    <dependency>
        <groupId>org.apache.commons</groupId>
        <artifactId>commons-lang3</artifactId>
        <version>3.5</version>
    </dependency>
    <dependency>
        <groupId>org.vaadin</groupId>
        <artifactId>viritin</artifactId>
        <version>1.61</version>
    </dependency>
    <dependency>
        <groupId>com.google.zxing</groupId>
        <artifactId>core</artifactId>
        <version>3.3.0</version>
    </dependency>
    <dependency>
        <groupId>net.sourceforge.htmlunit</groupId>
        <artifactId>htmlunit</artifactId>
    </dependency>
    <!-- /////////////////////////////////////////////// -->
    <!-- Database drivers -->
    <!-- /////////////////////////////////////////////// -->
    <dependency>
        <groupId>mysql</groupId>
        <artifactId>mysql-connector-java</artifactId>
    </dependency>
    <!-- /////////////////////////////////////////////// -->
    <!-- Windows Service -->
    <!-- /////////////////////////////////////////////// -->
    <dependency>
        <groupId>commons-daemon</groupId>
        <artifactId>commons-daemon</artifactId>
        <version>1.0.15</version>
    </dependency>
    <dependency>
        <groupId>com.sun.winsw</groupId>
        <artifactId>winsw</artifactId>
        <version>1.18</version>
        <classifier>bin</classifier>
        <type>exe</type>
        <scope>provided</scope>
    </dependency>
    <!-- /////////////////////////////////////////////// -->
    <!-- Test -->
    <!-- /////////////////////////////////////////////// -->
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-test</artifactId>
        <scope>test</scope>
    </dependency>
    <dependency>
        <groupId>org.springframework.restdocs</groupId>
        <artifactId>spring-restdocs-mockmvc</artifactId>
        <scope>test</scope>
    </dependency>

    <dependency>
        <groupId>org.apache.commons</groupId>
        <artifactId>commons-exec</artifactId>
        <version>1.3</version>
    </dependency>

    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-context</artifactId>
    </dependency>

    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-context-support</artifactId>
    </dependency>
    <dependency>
        <groupId>javax.mail</groupId>
        <artifactId>mail</artifactId>
        <version>1.4.3</version>
    </dependency>
    <dependency>
        <groupId>org.freemarker</groupId>
        <artifactId>freemarker</artifactId>
        <version>2.3.23</version>
    </dependency>
    <dependency>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-dependency-plugin</artifactId>
        <version>3.0.1</version>
        <type>maven-plugin</type>
    </dependency>

    <dependency>
        <groupId>javax.xml.bind</groupId>
        <artifactId>jaxb-api</artifactId>
        <version>2.3.0</version>
    </dependency>

    <dependency>
        <groupId>com.sun.xml.bind</groupId>
        <artifactId>jaxb-impl</artifactId>
        <version>2.3.0</version>
    </dependency>

    <dependency>
        <groupId>com.sun.xml.bind</groupId>
        <artifactId>jaxb-core</artifactId>
        <version>2.3.0</version>
    </dependency>

    <dependency>
        <groupId>javax.activation</groupId>
        <artifactId>javax.activation-api</artifactId>
        <version>1.2.0</version>
    </dependency>

</dependencies>

<build>
    <resources>
        <resource>
            <directory>src/main/resources</directory>
        </resource>
        <resource>
            <directory>src/main/webapp</directory>
        </resource>
    </resources>
    <plugins>
        <plugin>
            <groupId>com.vaadin</groupId>
            <artifactId>vaadin-maven-plugin</artifactId>
            <version>8.4.5</version>
            <executions>
                <execution>
                    <goals>
                        <goal>update-theme</goal>
                        <goal>compile-theme</goal>
                        <!-- <goal>clean</goal> <goal>resources</goal> 
                            <goal>update-widgetset</goal> 
                            <goal>compile</goal> -->
                    </goals>
                </execution>
            </executions>
        </plugin>

        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-resources-plugin</artifactId>
            <executions>
                <execution>
                    <id>copy-resources</id>
                    <phase>process-resources</phase>
                    <goals>
                        <goal>copy-resources</goal>
                    </goals>
                    <configuration>
                        <outputDirectory>${dist.dir}</outputDirectory>
                        <resources>
                            <resource>
                                <directory>src/main/dist</directory>
                                <filtering>true</filtering>
                            </resource>
                        </resources>
                    </configuration>
                </execution>
            </executions>
        </plugin>

        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-assembly-plugin</artifactId>
            <configuration>
                <descriptors>
                    <descriptor>src/main/assembly/unix.xml</descriptor>
                    <descriptor>src/main/assembly/windows.xml</descriptor>
                </descriptors>
            </configuration>
            <executions>
                <execution>
                    <id>assembly</id>
                    <phase>package</phase>
                    <goals>
                        <goal>single</goal>
                    </goals>
                </execution>
            </executions>
        </plugin>

    </plugins>
</build>


</project>
4

0 回答 0