Problem with deployment in production server

14 views
Skip to first unread message

jose.aguera

unread,
Nov 4, 2009, 10:21:01 AM11/4/09
to gwt-multipage
Hi all,

I'm using gwt-multipage, and I have work properly in hosted mode.
However, when I have tried to deploy my project in tomcat server,
entrypoints are not loaded. I have try with Jetty and I have the same
problem. The problem is with gwt-multipage, since when I remove gwt-
multipage configuration and packages, it works. Curiously, everything
works with eclipse, the problem only raise, when I try to deploy my
project in a production server. Besides, I don't get any error
message, so debugging is quite difficult. Maybe I have to write
something in my web.xml to have gwt-multipage working?

thank you very much

jose

Claudius Hauptmann

unread,
Nov 4, 2009, 10:52:27 AM11/4/09
to gwt-multipage
Hi Jose,

I tryed to reproduce the problem. It workes fine on my computer.
Perhaps your app is deployed to a different subfolder in your
production environment than in eclipse. Is that possible? Could you
please check that?

Thank you,
Claudius

jose.aguera

unread,
Nov 4, 2009, 11:39:21 AM11/4/09
to gwt-multipage
Hi Claudius,

I'm using the war folder generated by GWT, so the folder structure
should be the same. However, I just to realize that when I run my
project in eclipse, embedded jetty server, which is installed with GWT
plugin, use the gwt.xml file that is in my src folder, and not de
gwt.xml file that is in WEB-INF/classes/[path-of-my-project]

I will try to know exactly what is wrong, it seem that it is some
interaction with gwt-multipage, but maybe I'm wrong :-(

thank very much anyway

jose

On Nov 4, 10:52 am, Claudius Hauptmann

WebSavvy

unread,
Nov 4, 2009, 1:28:40 PM11/4/09
to gwt-multipage
I am having similar problem when deploying to Tomcat or Websphere. I
found it is because the regular expression I am using to match the URL
pattern of each entry point. I made now a change to add into account
the servlet-context, but now it works on Tomcat and Websphere but not
GWT Hotsted browser!

Claudius Hauptmann

unread,
Nov 4, 2009, 3:14:46 PM11/4/09
to gwt-multipage
Hi,

thank you, I got the problem! Thank you that you are even so using gwt-
multipage and help making it better! Id didn't run into this yet, but
perhaps the EntryPointFactoryImplGenerator can be fixed with
GWT.getModuleBaseURL() in line 77:

http://code.google.com/p/gwt-multipage/source/browse/trunk/gwt-multipage/src/main/java/com/claudiushauptmann/gwt/multipage/rebind/EntryPointFactoryImplGenerator.java#77

http://google-web-toolkit.googlecode.com/svn/javadoc/1.6/com/google/gwt/core/client/GWT.html#getModuleBaseURL%28%29

I'm very busy until the end of this week, but I will try to fix this
on Monday and make a new beta release. When you've got a solution
please post it here!

Thank you,
Claudius

jose.aguera

unread,
Nov 4, 2009, 11:21:01 PM11/4/09
to gwt-multipage
Yes, I think that it is the same problem. I realize that If I deploy
my application in tomcat ROOT folder it works properly, for production
server and also in eclipse hosted mode. However, if I try to use other
folder in webapps directory, I have to change MultipageRegular
expressions and web.xml to have my application working in production
server, but hosted mode doesn't work, because it seems that hosted
mode always works like a ROOT application.

thank very much guys for your time, it has been very useful for me.
I'm happy to help to do gwt-multipage, even better :-)

best

jose

Claudius Hauptmann

unread,
Nov 9, 2009, 9:10:05 AM11/9/09
to gwt-multipage
Hi,

I need your help. I'm looking for a solution to get the context-root
of the web application on the client side (JavaScript).

The best solution I found is to take the GWT.getModuleBaseURL()
http://localhost:8888/com.claudiushauptmann.gwt.multipage.sample.MultipageSample/
and remove the part after second slash from the right side
com.claudiushauptmann.gwt.multipage.sample.MultipageSample/
which will result in
http://localhost:8888/
and compare this plus the regex to Window.Location.getHref()
http://localhost:8888/MultipageSample.html
But this solution assumes that the folder containing the compiled code
of the module
(com.claudiushauptmann.gwt.multipage.sample.MultipageSample) is placed
within the root folder of the application!

What do you think? I hope there is a better solution! I'm waiting for
your feedback.

GWT.getModuleBaseURL():
http://localhost:8888/com.claudiushauptmann.gwt.multipage.sample.MultipageSample/

GWT.getHostPageBaseURL():
http://localhost:8888/

Window.Location.getPath():
/MultipageSample.html

Window.Location.getHref():
http://localhost:8888/MultipageSample.html

http://google-web-toolkit.googlecode.com/svn/javadoc/1.6/com/google/gwt/core/client/GWT.html
http://google-web-toolkit.googlecode.com/svn/javadoc/1.6/com/google/gwt/user/client/Window.Location.html

Thank you,
Claudius
Reply all
Reply to author
Forward
0 new messages