1

私はジェンキンスサーバーによって構築されたmavenプロジェクトに取り組んでいます。うまくいきました。しかし、ビルド プラグイン (完全な依存関係) を使用していて、javaversion を 1.6 に変更したため、問題が発生しました。

[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 22.278s
[INFO] Finished at: Wed Oct 02 07:32:07 CEST 2013
[INFO] Final Memory: 17M/141M
[INFO] ------------------------------------------------------------------------
[JENKINS] Archiving /var/lib/jenkins/workspace/MavenTest/pom.xml to MavenTest/MavenTest/0.0.1-SNAPSHOT/MavenTest-0.0.1-SNAPSHOT.pom
[JENKINS] Archiving /var/lib/jenkins/workspace/MavenTest/target/MavenTest-0.0.1-SNAPSHOT.jar to MavenTest/MavenTest/0.0.1-SNAPSHOT/MavenTest-0.0.1-SNAPSHOT.jar
[JENKINS] Archiving /var/lib/jenkins/workspace/MavenTest/target/MavenTest-0.0.1-SNAPSHOT-jar-with-dependencies.jar to MavenTest/MavenTest/0.0.1-SNAPSHOT/MavenTest-0.0.1-SNAPSHOT-jar-with-dependencies.jar
channel stopped
FATAL: hudson.maven.MavenBuild.pickArtifactManager()Ljenkins/model/ArtifactManager;
java.lang.NoSuchMethodError: hudson.maven.MavenBuild.pickArtifactManager()Ljenkins/model/ArtifactManager;
    at hudson.maven.MavenBuild$ProxyImpl.performArchiving(MavenBuild.java:455)
    at hudson.maven.MavenModuleSetBuild$MavenModuleSetBuildExecution.doRun(MavenModuleSetBuild.java:815)
    at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:567)
    at hudson.model.Run.execute(Run.java:1604)
    at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:506)
    at hudson.model.ResourceController.execute(ResourceController.java:88)
    at hudson.model.Executor.run(Executor.java:246)

これは私のポンです:

<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>MavenTest</groupId>
    <artifactId>MavenTest</artifactId>
    <version>0.0.1-SNAPSHOT</version>
    <packaging>jar</packaging>

    <name>MavenTest</name>
    <url>http://maven.apache.org</url>

    <properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    </properties>
    <build>
        <plugins>
            <plugin>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>3.1</version>
                <configuration>
                    <source>1.6</source>
                    <target>1.6</target>
                </configuration>
            </plugin>
            <plugin>
                <artifactId>maven-assembly-plugin</artifactId>
                <configuration>
                    <archive>
                        <manifest>
                            <mainClass>my.maven.example.Main</mainClass>
                        </manifest>
                    </archive>
                    <descriptorRefs>
                        <descriptorRef>jar-with-dependencies</descriptorRef>
                    </descriptorRefs>
                </configuration>
                <executions>
                    <execution>
                        <id>make-assembly</id> <!-- this is used for inheritance merges -->
                        <phase>package</phase> <!-- bind to the packaging phase -->
                        <goals>
                            <goal>single</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>
    <dependencies>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>3.8.1</version>
            <scope>test</scope>
        </dependency>
    </dependencies>
</project>

どうすればこれを修正できますか?

//編集:ubuntu 12.04のジェンキン、ネイティブインストール。

4

1 に答える 1