Yeah, something like that is what I thought this was probably about,
and hence why I said "You shouldn't need to mess with those files
though, unless you are doing something atypical in the shell".  Trying
to replace the GwtShellServlet is definitely atypical.

I am not sure how to help with changing the context, nor how to change
the mapping of the shell servlet.  But, I know this has come up in
several other projects that use Spring and redirect things through the
shell servlet.  You might check the GWT-SL (gwt server library)
project, as there is some info there about it.

I think in general though, those projects just use noserver and don't
try to configure the embedded Tomcat (I don't personally like that
approach, but that is usually what they do I think).  You can still
run the shell with noserver, you just lose the ability to run
gwttestcase based tests, and get auto refresh of everything, etc.


On Oct 18, 5:53 pm, Malte <[EMAIL PROTECTED]> wrote:
> It's a litte bit more complicated. I am running spring in the embedded
> tomcat server and call the gwt shell servlet over the
> DispatcherServlet from spring, because the default servlet-mapping /*
> for the gwt shell servlet doesn't let me call any other servlet. When
> I am now calling the gwt shell servlet from the spring context, the
> gwt shell servlet is not able to find the gwt.rpc file in the .gwt-tmp/
> shell directory. I don't know exactly why, but I think it is when I am
> calling the gwt shell servlet from inside spring the servlet context
> changed to the tomcat/webapps/ROOT directory. That why I have to copy
> the gwt.rpc file to this directory. When someone can tell me how I can
> change the context back to the default directory or how I can
> configure the servlet-mapping so that I can call spring besides the
> gwt shell servlet I would be happy ;)
>
> Some configurations:
>
>   <servlet>
>     <servlet-name>spring</servlet-name>
>     <servlet-class>org.springframework.web.servlet.DispatcherServlet</
> servlet-class>
>     <load-on-startup>1</load-on-startup>
>   </servlet>
>   <servlet>
>     <servlet-name>shell</servlet-name>
>     <servlet-class>com.google.gwt.dev.shell.GWTShellServlet</servlet-
> class>
>   </servlet>
>   <servlet-mapping>
>     <servlet-name>spring</servlet-name>
>     <url-pattern>/*</url-pattern>
>   </servlet-mapping>
>   <!--inserted by gwt-maven-->
>   <servlet-mapping>
>     <servlet-name>shell</servlet-name>
>     <url-pattern>/</url-pattern>
>
> Problem is then the shell has the /* mapping everything is handled by
> this servlet, cause all other mappings will overwritten by this. So I
> let all servlet calls handled by spring. Folling configuration will
> handle that:
>
>    <bean id="gwtShellController"
> class="org.springframework.web.servlet.mvc.ServletForwardingController">
>         <property name="servletName">
>                 <value>shell</value>
>         </property>
>    </bean>
>
>    <bean id="urlMapping"
> class="org.springframework.web.servlet.handler.SimpleUrlHandlerMapping">
>         <property name="mappings">
>                 <props>
>                         <prop key="/*/user.rpc">userController</prop>
>                         <prop key="/*">gwtShellController</prop>
>                 </props>
>         </property>
>     </bean>
>
> My main goal is to run everything in the hosted browser with the
> embedded tomcat server, without calling a jetty instance.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"gwt-maven" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/gwt-maven?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to