# Maven LifecycleExecutionException



## tbar0711 (12. Okt 2009)

Hi Leute,

ich bekomme folgenden Fehler, wenn ich mein Maven-Projekt deploye:


```
[exec] [ERROR] BUILD ERROR
     [exec] [INFO] ------------------------------------------------------------------------
     [exec] [INFO] For all packaging other than war you need to configure the container you wishes to use.
     [exec] [INFO] ------------------------------------------------------------------------
     [exec] [INFO] Trace
     [exec] org.apache.maven.lifecycle.LifecycleExecutionException: For all packaging other than war you need to configure the container you wishes to use.
     [exec] 	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:584)
     [exec] 	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:513)
     [exec] 	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:483)
     [exec] 	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:331)
     [exec] 	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:292)
     [exec] 	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:142)
     [exec] 	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:336)
     [exec] 	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:129)
     [exec] 	at org.apache.maven.cli.MavenCli.main(MavenCli.java:301)
     [exec] 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
     [exec] 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
     [exec] 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
     [exec] 	at java.lang.reflect.Method.invoke(Method.java:597)
     [exec] 	at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
     [exec] 	at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
     [exec] 	at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
     [exec] 	at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
     [exec] Caused by: org.apache.maven.plugin.MojoExecutionException: For all packaging other than war you need to configure the container you wishes to use.
     [exec] 	at org.codehaus.cargo.maven2.AbstractCargoMojo.createNewContainer(AbstractCargoMojo.java:355)
     [exec] 	at org.codehaus.cargo.maven2.AbstractCargoMojo.createContainer(AbstractCargoMojo.java:320)
     [exec] 	at org.codehaus.cargo.maven2.AbstractDeployerMojo.doExecute(AbstractDeployerMojo.java:44)
     [exec] 	at org.codehaus.cargo.maven2.AbstractCargoMojo.execute(AbstractCargoMojo.java:243)
     [exec] 	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)
     [exec] 	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)
     [exec] 	... 16 more
     [exec] [INFO] ------------------------------------------------------------------------
```


Und hier ist meine POM:


[XML]
<?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/maven-v4_0_0.xsd">
	<modelVersion>4.0.0</modelVersion>
	<groupId>test</groupId>
	<artifactId>test</artifactId>
	<name>Test</name>
	<packaging>jar</packaging>
	<version>0.0.1-SNAPSHOT</version>
	<properties>
		<version.jboss-embedded>beta3.SP10</version.jboss-embedded>
	</properties>

	<dependencies>
		<dependency>
			<groupId>org.jboss.embedded</groupId>
			<artifactId>jboss-embedded-all</artifactId>
			<version>${version.jboss-embedded}</version>
			<exclusions>
				<exclusion>
					<groupId>org.jboss.embedded</groupId>
					<artifactId>jboss-embedded</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.jboss.microcontainer</groupId>
					<artifactId>jboss-deployers-client-spi</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.jboss.microcontainer</groupId>
					<artifactId>jboss-deployers-core-spi</artifactId>
				</exclusion>
			</exclusions>
		</dependency>
		<dependency>
			<groupId>org.jboss.embedded</groupId>
			<artifactId>jboss-embedded</artifactId>
			<version>${version.jboss-embedded}</version>
		</dependency>
		<dependency>
			<groupId>org.jboss.embedded</groupId>
			<artifactId>hibernate-all</artifactId>
			<version>${version.jboss-embedded}</version>
		</dependency>
		<dependency>
			<groupId>org.jboss.embedded</groupId>
			<artifactId>jboss-embedded-api</artifactId>
			<version>beta2</version>
		</dependency>
		<dependency>
			<groupId>org.jboss.embedded</groupId>
			<artifactId>thirdparty-all</artifactId>
			<version>${version.jboss-embedded}</version>
		</dependency>
		<dependency>
			<groupId>junit</groupId>
			<artifactId>junit</artifactId>
			<version>4.6</version>
		</dependency>
		<dependency>
			<groupId>de.kaufland.sko</groupId>
			<artifactId>sko-hibernate</artifactId>
			<version>3.6.0-SNAPSHOT</version>
			<exclusions>
				<exclusion>
					<groupId>commons-lang</groupId>
					<artifactId>commons-lang</artifactId>
				</exclusion>
				<exclusion>
					<groupId>javax.faces</groupId>
					<artifactId>jsf-api</artifactId>
				</exclusion>
				<exclusion>
					<groupId>javax.faces</groupId>
					<artifactId>jsf-impl</artifactId>
				</exclusion>
				<exclusion>
					<groupId>javax.servlet</groupId>
					<artifactId>jstl</artifactId>
				</exclusion>
			</exclusions>
		</dependency>
		<dependency>
			<groupId>javax.xml.bind</groupId>
			<artifactId>jaxb-api</artifactId>
			<version>2.1</version>
		</dependency>
		<dependency>
			<groupId>oracle</groupId>
			<artifactId>ojdbc14</artifactId>
			<version>10.2.0.3.0</version>
		</dependency>
	</dependencies>
	<build>
		<testResources>
			<testResource>
				<directory>src/test/resources</directory>
				<includes>
					<include>**/*</include>
				</includes>
			</testResource>
			<testResource>
				<directory>embedded-jboss-beta3.SP10/embedded-jboss-beta3.SP10/bootstrap</directory>
				<includes>
					<include>**/*</include>
				</includes>
			</testResource>
		</testResources>
		<plugins>
			<plugin>
				<artifactId>maven-compiler-plugin</artifactId>
				<configuration>
					<source>1.5</source>
					<target>1.5</target>
				</configuration>
			</plugin>
			<plugin>
				<artifactId>maven-ejb-plugin</artifactId>
				<configuration>
					<ejbVersion>3.0</ejbVersion>
					<archive>
						<manifest>
							<addClasspath>true</addClasspath>
						</manifest>
					</archive>
				</configuration>
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-surefire-plugin</artifactId>
				<configuration>
					<enableAssertions>false</enableAssertions>
					<argLine>-Dsun.lang.ClassLoader.allowArraySyntax=true</argLine>
				</configuration>
			</plugin>

		</plugins>
	</build>
	<reporting>
		<plugins>
			<plugin>
				<artifactId>maven-javadoc-plugin</artifactId>
			</plugin>
			<plugin>
				<artifactId>maven-surefire-plugin</artifactId>
			</plugin>
			<plugin>
				<artifactId>maven-clover-plugin</artifactId>
			</plugin>
		</plugins>
	</reporting>
</project>
[/XML]


Habt ihr eine Ahnung, was da schief läuft?

Grüße
T.


----------



## maki (12. Okt 2009)

[uote]wenn ich mein Maven-Projekt deploye:[/quote]
Du bekommst den Fehler bei [c]mvn deploy[/c] ?


----------



## tbar0711 (13. Okt 2009)

Ihr könnt diesen Post löschen. Ich weiss nicht mehr, was ich gemacht habe, aber der Fehler ist weg. Sorry

Grüße 
T.


----------

