Gmail Calendar Documents Reader Web more »
Recently Visited Groups | Help | Sign in
Google Groups Home
how to deploy gwt apps to tomcat
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  6 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Freak.2k  
View profile  
(5 users)  More options Aug 9 2006, 12:09 pm
From: "Freak.2k" <Freak...@gmx.net>
Date: Wed, 09 Aug 2006 09:09:05 -0700
Local: Wed, Aug 9 2006 12:09 pm
Subject: how to deploy gwt apps to tomcat
Hello,

how do I deploy my gwt application to the tomcat server?
found nothing...

greetz from germany


    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
ash  
View profile  
(4 users)  More options Aug 9 2006, 7:09 pm
From: "ash" <ash...@gmail.com>
Date: Wed, 09 Aug 2006 23:09:05 -0000
Local: Wed, Aug 9 2006 7:09 pm
Subject: Re: how to deploy gwt apps to tomcat
mate,

if your question is how to i build a non-trivial gwt web application
archive (ie. war) that can be deployed into tomcat then consider
looking at:
1. (from http://juls.googlecode.com/svn/trunk/build.xml)

        <target name="build" depends="compile, compileJs">
                <antcall target="buildLibs" />
                <antcall target="buildWar" />
        </target>

        <target name="buildWar" depends="buildLibs">
                <antcall target="cleanDebug" />
                <mkdir dir="${milestone.dir}" />

                <copy todir="${build.dir}/tmp.web-inf-lib" flatten="true">
                        <fileset dir="${cm-assemblies.lib.dir}"
excludes="**/*-javadocs.jar">
                                <include name="gems-gwt-user/gems-gwt-rpc-1.0.21.jar"/>
                                <include name="gems/gems-svc-api.jar"/>
                                <include name="gems/gems-server.jar"/>
                                <include name="log4j/log4j-1.2.8.jar"/>
                                <include name="commons-fileupload/commons-fileupload-1.1-RC2.jar"/>
                                <include name="commons-io/commons-io-1.2.jar"/>
                                <include name="commons-lang/commons-lang-2.1-RC8.jar"/>
                        </fileset>
                </copy>

                <war warfile="${milestone.dir}/${war.name}" webxml="${web.xml}">
                        <fileset dir="${webapp.dir}" />
                        <lib dir="${build.dir}/tmp.web-inf-lib" />
                        <lib dir="${libs.dir}" />
                </war>
                <delete includeEmptyDirs="true" failonerror="false">
                        <fileset dir="${build.dir}/tmp.web-inf-lib" />
                </delete>
        </target>

    <target name="compileJs" depends="compile, cleanForJs">
        <copy todir="${webapp.dir}/${gwt-xml-ep.name}">
                        <fileset dir="${gem-appl-public.dir}" includes="**/*"/>
        </copy>
        <java classpathref="js.build.classpath"
                classname="com.google.gwt.dev.GWTCompiler"
                fork="true">
                <arg value="-out"/>
                <arg value="${webapp.dir}"/>
                <arg value="${gwt-xml-ep.name}"/>
                <!--
                        Every now and then you will need uncomment the following to be
able
                        to debug FF in Venkman to remove a gwt-user-lib bug that only
                        manifests itself in non IE browsers.
                    <arg value="-style"/>
                    <arg value="DETAILED"/>
                -->
        </java>
        <move todir="${webapp.dir}">
                        <fileset dir="${webapp.dir}/${gwt-xml-ep.name}">
                                <include name="jump.css"/>
                                <include name="images/**" />
                        </fileset>
        </move>
    </target>

alternatively, if your question is how to i deploy a jee application
into tomcat, then tomcat versions will play a roll here. i have two
examples based on tomcat 5.5.9 release:

approach 1.
1. first take a look at my server.xml. u will notice that there is
bugger all in here:
http://juls.googlecode.com/svn/trunk/dist/jakarta-tomcat-5.5.9/conf/s...
2. i mounted my application into tomcat's root context. that means my
application does not need a root context to get signalled. Take a look
at my ROOT.xml:
http://juls.googlecode.com/svn/trunk/dist/jakarta-tomcat-5.5.9/conf/C...

you will notice that my non-debug context has the following docBase
value: docBase="${catalina.home}/../bin/juls.war"
this means that on tomcat boot, it will extract juls.war from the
specified location into tomcat's ${catalina.home}/webapps folder if it
as not already been extracted

approach 2.
If i change the docBase value (which i do to debug the server code) to
docBase="${catalina.home}/../../webapp", then it will use my source
rather than a built package.

rgds ash
http://www.gworks.com.au/

self help sources:
1. http://javaongems.org/ -> http://code.google.com/p/javaongems/
2. http://code.google.com/p/gems-gwt-user/
3. http://code.google.com/p/juls/


    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Freak.2k  
View profile  
(2 users)  More options Aug 10 2006, 1:53 am
From: "Freak.2k" <Freak...@gmx.net>
Date: Wed, 09 Aug 2006 22:53:33 -0700
Local: Thurs, Aug 10 2006 1:53 am
Subject: Re: how to deploy gwt apps to tomcat
thanks...
this sounds a bit difficult....
but whats the default way to deploy gwt applications?

    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
jsaar  
View profile  
(5 users)  More options Aug 10 2006, 6:04 am
From: "jsaar" <duddelfud...@googlemail.com>
Date: Thu, 10 Aug 2006 10:04:54 -0000
Local: Thurs, Aug 10 2006 6:04 am
Subject: Re: how to deploy gwt apps to tomcat
in a nutshell:

Normally there are 2 parts:

- client-part
- server-part

I think in most cases tomcat is used as webserver.
there the root for deploying is in:

<path-to-tomcat-host>/webapps/<application-dir>/

there should be a dir for the html/js things ... let us call it
"hellogwt"
so you get the following structure

./hellogwt
./WEB_INF
./WEB_INF/lib
./WEB_INF/classes

where lib and classes are the places for all that is needed for the
Servlet

All that should be put into file <application-dir>.war
and this file should be copied to the webapps-dir.

A Tomcat with an enhanced management can be found at:
http://centaurus.sourceforge.net/home.html

Centaurus-Platform makes tomcat very much easyier ...


    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Scott Blum  
View profile  
(5 users)  More options Aug 13 2006, 12:27 pm
From: "Scott Blum" <sco...@google.com>
Date: Sun, 13 Aug 2006 12:27:13 -0400
Local: Sun, Aug 13 2006 12:27 pm
Subject: Re: how to deploy gwt apps to tomcat

Hi Freak.2k,

Probably the easiest way to describe it is with an example.  I've attached a
WARed DynaTable from 1.1.0.

If the attachment doesn't come through on the group, here is a listing of
the contents:

6F6A5A9C0EDF42E8688A1AC27524F2C9.cache.html
6F6A5A9C0EDF42E8688A1AC27524F2C9.cache.xml
A5E915C34D8C45AFDB60EFAF90493A8A.cache.html
A5E915C34D8C45AFDB60EFAF90493A8A.cache.xml
AC539BDC02597A92D78FB2AA82370482.cache.html
AC539BDC02597A92D78FB2AA82370482.cache.xml
com.google.gwt.sample.dynatable.DynaTable.nocache.html
DynaTable.css
DynaTable.html
E35E3C7B95E0E54D5DFDB4856FA435FF.cache.html
E35E3C7B95E0E54D5DFDB4856FA435FF.cache.xml
gwt.js
history.html
tree_closed.gif
tree_open.gif
tree_white.gif
WEB-INF/
WEB-INF/lib/
WEB-INF/lib/DynaTable.jar
WEB-INF/lib/gwt-servlet.jar
WEB-INF/web.xml

All the stuff in the top level directory is simply the compiler output
folder.  WEB-INF/lib contains gwt-servlet.jar and a DynaTable.jar produced
by running a DynaTable.ant.xml produced by projectCreator.  Here's the
web.xml:

<?xml version="1.0" encoding="UTF-8"?>
<web-app>
        <servlet>
                <servlet-name>SchoolCalendarService</servlet-name>
                <servlet-class>
com.google.gwt.sample.dynatable.server.SchoolCalendarServiceImpl
</servlet-class>
        </servlet>
        <servlet-mapping>
                <servlet-name>SchoolCalendarService</servlet-name>
                <url-pattern>/calendar</url-pattern>
        </servlet-mapping>
</web-app>

Finally, I made two minor tweaks to the DynaTable source code:

SchoolCalendarWidget(39): target.setServiceEntryPoint(GWT.getModuleBaseURL()
+ "calendar");
DynaTable.gwt.xml(3): <servlet path='/calendar' class='
com.google.gwt.sample.dynatable.server.SchoolCalendarServiceImpl'/>

The serviceEntryPoint change is necessary to get the path correct when
deployed to Tomcat, and the gwt.xml change makes hosted mode work correctly
with the entry point change.

Hope this helps,
Scott

On 8/10/06, Freak.2k <Freak...@gmx.net> wrote:

  DynaTable.war
490K Download

    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
sharad sinha  
View profile  
(4 users)  More options Aug 13 2006, 2:04 pm
From: "sharad sinha" <sharad.si...@gmail.com>
Date: Sun, 13 Aug 2006 11:04:52 -0700
Local: Sun, Aug 13 2006 2:04 pm
Subject: Re: how to deploy gwt apps to tomcat
Hi Freak,

If i undestood properly, These are the basic primitive steps needed to
get ur GWT app runnng on a stand-alone Tomcat.

1. Put the gwt released jars in ur project classpath. Compile ur
project and copy the classes to tomcat WEB-INF / classes folder.
2. Run <urAppName>-compile.cmd file, it will generate the javascript
from ur java source, needed to be deployed in tomcat.
    Obviously this cmd file should contain the proper path of ur
project src, classes and all the referenced jars including gwt jars.
3. This cmd file emits lots of .cache, html and xml files in www /
xyz.123.bla.bla.html folder (ur module name).Copy all these files
    in tomcat parallel to WEB-INF directory. Map ur servlet in web.xml
file, this mapping should coincide with service entry point u
    have specified in ur gwt app rpc calls to the servlet.
4. Now start ur tomcat and run ur application like a normal web
application. Its done.


    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »

Create a group - Google Groups - Google Home - Terms of Service - Privacy Policy
©2010 Google