JSP Problem: GWT and GXT modules in the same WAR

GWT Designer allows you to quickly create the modules, composites, panels, remote services and other elements that comprise Google Web Tookit applications.

Moderators: Konstantin.Scheglov, gnebling, Alexander.Mitin, jwren, Eric Clayberg

JSP Problem: GWT and GXT modules in the same WAR

Postby iceage » Thu Feb 11, 2010 4:23 pm

Versions: current GWTD 7.3build, GWT 2.0.1 and GXT 2.1.1


Hey Java friends,

I am just testing around with the GWTD. In the following problem scenario are two GWT modules within one Dynamic Web Project:

MyModuleGWT (a standard GWT module)
host file: MyModuleGWT.jsp

MyModuleExtGWT (a Module configured by GWTD to use GXT: "Configure for using ExtGWT (GXT)")
host file: MyModuleExtGWT.jsp

To make GXT module run with GWTD, it was necessary to manually add MyModuleExtGWT.jsp to the welcome-file-list of web.xml and to add the following line to the MyModuleExtGWT.jsp file itself:
<link type="text/css" rel="stylesheet" href="ExtGWT/css/gxt-all.css"/>

If jsp host file is not added to web.xml's welcome-file-list, the following error is shown (using GWTD with GXT module):
Code: Select all
GXT requires not just gxt.jar, but also set of resources, such as CSS files, images, etc. You should use "Configure for using GXT" action on your GWT module. GWT Designer was not able to find "gxt-.css" file.


Even the normal GWT module (MyModuleGWT) is throwing the error in this scenario.
After adding the MyModuleExtGWT.jsp to the welcome-file-list, both modules are running fine again.


Is there a problem with JSP host files? Why is the module MyModuleGWT affect which is NOT configured to use GXT (only uses pure GWT)?
iceage
 
Posts: 1
Joined: Thu Feb 11, 2010 3:36 pm

Re: JSP Problem: GWT and GXT modules in the same WAR

Postby Eric Clayberg » Fri Feb 12, 2010 5:48 am

1. We validate the presence of GXT resources, if the GXT jar is in the classpath. We've added added an additional check in the latest v7.3 build that not just the gxt.jar is in the classpath, but also the GXT module is imported.

2. Without a welcome file, we use the default HTML file with same name as the module, not the JSP file.
Eric Clayberg
Software Engineering Manager
Google
http://code.google.com/webtoolkit/download.html

Author: "Eclipse Plug-ins"
http://www.qualityeclipse.com
Eric Clayberg
Moderator
 
Posts: 4503
Joined: Tue Sep 30, 2003 6:39 am
Location: Boston, MA USA


Return to GWT Designer

Who is online

Users browsing this forum: No registered users and 1 guest