I saw a lot of article about integrating GWT RPC and Spring

What do you thing (for begginers) this apporach is not ok ?

In the web xml the application context is loaded via

<context-param>
                <param-name>contextConfigLocation</param-name>
                <param-value>/WEB-INF/applicationContext.xml</param-value>
</context-param>
<servlet>
                <servlet-name>context</servlet-name>
                
<servlet-class>org.springframework.web.context.ContextLoaderServlet</
servlet-class>
                <load-on-startup>1</load-on-startup>
</servlet>

Ok the a regular service is created
DummyService,DummyServiceAsynch,DummyServiceImpl

DummyServiceImpl extends RemoteServiceServlet

SomeSpringBean someSpringBean;

public void init() throws ServletException {
 super.init();

ApplicationContext appContext =
WebApplicationContextUtils.getRequiredWebApplicationContext
(getServletContext());
someSpringBean = (SomeSpringBean) appContext.getBean
("someSpringBean");

}


So in this way i have on server side "kind of injected" a spring bean
i defined in appContext.xml


I w8 your opinion !

Thx
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" 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/Google-Web-Toolkit?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to