• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: deployment problem
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: deployment problem


  • Subject: Re: deployment problem
  • From: "M.Y. Tjoe" <email@hidden>
  • Date: Fri, 14 Nov 2008 15:00:14 +1100



Hi Lachlan,


Thanks for your reply. 


(just a note that the womaven-dev list is more aimed at feature
development planning and discussions surrounding that rather than a
user-list per se - so your audience here will be quite small. i.e.,
can be counted on one hand I'd say.... so I'm tempted to cc woproject-
dev instead :)

Thanks for the advice. I'll do it from now on. ^v^


I got a hello world Maven WebObjects app which build successfully
(in command line) but the war file is not deployed properly on tomcat.

How did you create the project?



using command line:

mvn archetype:generate -DarchetypeArtifactId=woapplication-archetype \
		-DarchetypeGroupId=org.objectstyle.woproject.maven2 \
		-DarchetypeVersion=2.0.16 \
		-DarchetypeRepository=http://webobjects.mdimension.com/maven2/releases


What's your pom file look like?

<?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>ris.its.uow.edu.au</groupId>
<artifactId>testMaven</artifactId>
    <packaging>woapplication</packaging>
    <version>1.0-SNAPSHOT</version>
<name>testMaven WebObjects App</name>
<url>http://maven.apache.org</url>
    <properties>
<woversion>5.4.3</woversion>
</properties>
    <build>
<finalName>testMaven</finalName>
<plugins>
<!-- maven-wolifecycle-plugin -->
            <plugin>
<groupId>org.objectstyle.woproject.maven2</groupId>
<artifactId>maven-wolifecycle-plugin</artifactId>
<version>2.0.16-SNAPSHOT</version>
<extensions>true</extensions>
                <configuration>
                    <readPatternsets>true</readPatternsets>
                </configuration>
</plugin>
            <!-- maven-war-plugin -->
            <plugin>
<artifactId>maven-war-plugin</artifactId>
<version>2.0</version>
<configuration>
<archiveClasses>true</archiveClasses>
</configuration>
</plugin>
            
            
            <!-- cargo-maven2-plugin -->
            <plugin>
                <groupId>org.codehaus.cargo</groupId>
                <artifactId>cargo-maven2-plugin</artifactId>
                <configuration>

                    <!-- Container configuration -->
                    <container>
                        <containerId>tomcat5x</containerId>
                        <home>/usr/local/apache-tomcat-6.0.16</home>
                    </container>

                    <!-- Configuration to use with the container -->

                    <configuration>
                        <type>existing</type>
                        <home>/usr/local/apache-tomcat-6.0.16</home>
                    <!--    
                        <properties>
                            <cargo.servlet.port>8081</cargo.servlet.port>
                        </properties>
                    -->    
                    </configuration>

                    <!-- Deployer configuration -->
                    <deployer>
                        <type>installed</type>
                        <deployables>
                            <deployable>
                                <groupId>ris.its.uow.edu.au</groupId>
                                <artifactId>testMaven</artifactId>
                                <type>war</type>
                                -->
                            </deployable>
                        </deployables>
                    </deployer>

                </configuration>
             </plugin>
            
        </plugins>
</build>
<dependencies>
<dependency>
<groupId>com.webobjects</groupId>
<artifactId>JavaFoundation</artifactId>
<version>${woversion}</version>
</dependency>
<dependency>
<groupId>com.webobjects</groupId>
<artifactId>JavaWebObjects</artifactId>
<version>${woversion}</version>
</dependency>
<dependency>
<groupId>com.webobjects</groupId>
<artifactId>JavaEOAccess</artifactId>
<version>${woversion}</version>
</dependency>
        <dependency>
<groupId>com.webobjects</groupId>
<artifactId>JavaWOJSPServlet</artifactId>
<version>${woversion}</version>
</dependency>
        <dependency>
<groupId>wonder.common</groupId>
<artifactId>ERExtensions</artifactId>
<version>5.4.0</version>
</dependency>
    </dependencies>
   
</project>



When look at the expanded war, it looks like it is not package
correctly with right structure:
What structure does it have?
Is the Properties file in there but just in the wrong place?


The Properties file could be in the wrong directory but it is definitely there
The Properties file is under WEB-INF/classes/, please see screenshot below:





The catalina log gives following error.

"Main bundle 'Properties' file can't be read.  Did you run as a Java
Application instead of a WOApplication in WOLips?"

So I tired changing <packaging>war</packaging> to
<packaging>woapplication<packaging>, then I got following structure
which seems to have more contents in it.

Henrique or Daryl will probably be more familiar with building wars -
but building as woapplication won't give you a war.

Did you refer to this page?
http://wiki.objectstyle.org/confluence/display/WOL/Packaging+WO+Applications+as+true+WAR+with+Maven

Yes I am using this reference (without step 1, 2 & jetty-plugin).



Regards,
Harvey



 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: deployment problem
      • From: Henrique Prange <email@hidden>
    • Re: deployment problem --> maven + war
      • From: Lachlan Deck <email@hidden>
  • Prev by Date: Re: Moving over an app to Linux and I get this error..
  • Next by Date: Re: deployment problem --> maven + war
  • Previous by thread: Re: Moving over an app to Linux and I get this error..
  • Next by thread: Re: deployment problem --> maven + war
  • Index(es):
    • Date
    • Thread