NutzCN Logo
问答 nutzboot 生成的Maven项目 无法导入 starter-mongo
发布于 2309天前 作者 Java 1639 次浏览 复制 上一个帖子 下一个帖子
标签:
<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.quailai</groupId>
    <artifactId>crawl-taodinggs</artifactId>
    <version>1.0-SNAPSHOT</version>
    <!--<packaging>war</packaging>-->
    <properties>
        <nutzboot.version>2.2.2</nutzboot.version>
        <log4j-version>2.11.0</log4j-version>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    </properties>
    <profiles>
        <!--开发环境-->
        <profile>
            <id>dev</id>
            <activation>
                <activeByDefault>true</activeByDefault>
            </activation>
            <properties>
                <env>dev</env>
            </properties>
        </profile>
        <!--生产环境-->
        <profile>
            <id>prod</id>
            <properties>
                <env>prod</env>
            </properties>
        </profile>
    </profiles>
    <dependencyManagement>
        <dependencies>
            <dependency>
                <groupId>org.nutz</groupId>
                <artifactId>nutzboot-parent</artifactId>
                <version>${nutzboot.version}</version>
                <type>pom</type>
                <scope>import</scope>
            </dependency>
        </dependencies>
    </dependencyManagement>
    <dependencies>
        <dependency>
            <groupId>org.nutz</groupId>
            <artifactId>nutzboot-starter-swagger</artifactId>
        </dependency>
       <dependency>
            <groupId>org.nutz</groupId>
            <artifactId>nutzboot-starter-nutz-mvc</artifactId>
        </dependency>
       <dependency>
            <groupId>org.nutz</groupId>
            <artifactId>nutzboot-starter-nutz-dao</artifactId>
           <exclusions>
               <exclusion>
                   <groupId>com.alibaba</groupId>
                   <artifactId>druid</artifactId>
               </exclusion>
           </exclusions>
        </dependency>
       <dependency>
            <groupId>org.nutz</groupId>
            <artifactId>nutzboot-starter-jdbc</artifactId>
           <exclusions>
               <exclusion>
                   <groupId>com.alibaba</groupId>
                   <artifactId>druid</artifactId>
               </exclusion>
           </exclusions>
        </dependency>
       <dependency>
            <groupId>org.nutz</groupId>
            <artifactId>nutzboot-starter-quartz</artifactId>
        </dependency>
        <dependency>
            <groupId>org.nutz</groupId>
            <artifactId>nutzboot-starter-mongo</artifactId>
        </dependency>
        <dependency>
            <groupId>org.nutz</groupId>
            <artifactId>nutzboot-servlet3</artifactId>
        </dependency>
        <dependency>
            <groupId>com.zaxxer</groupId>
            <artifactId>HikariCP</artifactId>
            <version>3.2.0</version>
        </dependency>
        <dependency>
            <groupId>org.apache.logging.log4j</groupId>
            <artifactId>log4j-web</artifactId>
            <version>${log4j-version}</version>
        </dependency>
        <dependency>
            <groupId>org.apache.logging.log4j</groupId>
            <artifactId>log4j-slf4j-impl</artifactId>
            <version>${log4j-version}</version>
        </dependency>
        <dependency>
            <groupId>org.apache.logging.log4j</groupId>
            <artifactId>log4j-jcl</artifactId>
            <version>${log4j-version}</version>
        </dependency>
        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-api</artifactId>
            <version>1.7.25</version>
        </dependency>
        <dependency>
            <groupId>org.mariadb.jdbc</groupId>
            <artifactId>mariadb-java-client</artifactId>
            <version>2.0.3</version>
        </dependency>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <scope>test</scope>
        </dependency>
        <dependency>
             <groupId>org.slf4j</groupId>
             <artifactId>slf4j-log4j12</artifactId>
        </dependency>
        <dependency>
            <groupId>us.codecraft</groupId>
            <artifactId>webmagic-core</artifactId>
            <version>0.7.3</version>
        </dependency>
        <dependency>
            <groupId>us.codecraft</groupId>
            <artifactId>webmagic-extension</artifactId>
            <version>0.7.3</version>
        </dependency>
    </dependencies>
    <repositories>
        <repository>
            <id>nutz</id>
            <url>http://jfrog.nutz.cn/artifactory/libs-release</url>
        </repository>
        <repository>
            <id>nutz-snapshots</id>
            <url>http://jfrog.nutz.cn/artifactory/snapshots</url>
            <snapshots>
                <enabled>true</enabled>
                <updatePolicy>always</updatePolicy>
            </snapshots>
            <releases>
                <enabled>false</enabled>
            </releases>
        </repository>
    </repositories>
    <pluginRepositories>
        <pluginRepository>
            <id>nutz-snapshots</id>
            <url>http://jfrog.nutz.cn/artifactory/snapshots</url>
            <snapshots>
                <enabled>true</enabled>
                <updatePolicy>always</updatePolicy>
            </snapshots>
            <releases>
                <enabled>false</enabled>
            </releases>
        </pluginRepository>
    </pluginRepositories>
    <build>
        <!--<finalName>${name}${version}</finalName>-->
        <sourceDirectory>src/main/java</sourceDirectory>
        <resources>
            <resource>
                <directory>src/main/resources/${env}</directory>
                <includes>
                    <include>**</include>
                </includes>
                <filtering>true</filtering>
            </resource>
        </resources>
        <plugins>
            <plugin>
                <groupId>org.nutz.boot</groupId>
                <artifactId>nutzboot-maven-plugin</artifactId>
                <version>${nutzboot.version}</version>
                <executions>
                    <execution>
                        <phase>
                            package
                        </phase>
                        <goals>
                            <goal>shade</goal>
                            <goal>war</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
                    <createDependencyReducedPom>false</createDependencyReducedPom>
                </configuration>
            </plugin>
            <plugin>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>3.7.0</version>
                <configuration>
                    <source>1.8</source>
                    <target>1.8</target>
                    <compilerArgs>
                        <arg>-parameters</arg>
                    </compilerArgs>
                    <useIncrementalCompilation>false</useIncrementalCompilation>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
                <version>2.10.3</version>
                <configuration>
                    <additionalparam>-Xdoclint:none</additionalparam>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.nutz.boot</groupId>
                <artifactId>nutzboot-maven-plugin</artifactId>
                <version>${nutzboot.version}</version>
            </plugin>
        </plugins>
    </build>
</project>

4 回复

是报错还是干啥?

报错,下载不到包

下不到什么包?starter-mongo? 应该是starter-mongodb 吧

额,包名错了不知道是生成错误还是我不小心改错了。。。

添加回复
请先登陆
回到顶部