Hello,

I think there are severals problems. In the web.xml file there is no 
link with the "context-application.xml " file.
The FirstStepsApplication defines only a Router as a root Restlet. That 
means that all incoming requests will be routed to nothing.
I just wonder, why do you need Spring?
Anyway, if you want more docs about the integration with Spring you can 
follow the link to the "user guide" in this page 
http://www.restlet.org/documentation/1.1/. Then you can choose the 
documentation of the "Spring" extension or go directly to  
"http://wiki.restlet.org/docs_1.1/13-restlet/28-restlet/70-restlet.html";

Best regards,
Thierry Boileau
--
Restlet ~ Core developer ~ http://www.restlet.org
Noelios Technologies ~ Co-founder ~ http://www.noelios.com 
> Hello, 
> I have a problem with restlet libraries and drives. 
>
> I configured the file web.xml: 
>
>    <context-param>
>       <param-name>org.restlet.application</param-name>
>       <param-value>
>          firstSteps.FirstStepsApplication
>       </param-value>
>    </context-param>
>
>    <!-- Restlet adapter -->
>    <servlet>
>       <servlet-name>RestletServlet</servlet-name>
>       <servlet-class>
>          com.noelios.restlet.ext.servlet.ServerServlet
>       </servlet-class>
>    </servlet>
>
>    <!-- Catch all requests -->
>    <servlet-mapping>
>       <servlet-name>RestletServlet</servlet-name>
>       <url-pattern>/*</url-pattern>
>    </servlet-mapping>
>
> And the context-application.xml 
> <?xml version="1.0" encoding="UTF-8"?>
> <beans xmlns="http://www.springframework.org/schema/beans";
>     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
>     xmlns:util="http://www.springframework.org/schema/util";
>     xsi:schemaLocation="http://www.springframework.org/schema/beans 
> http://www.springframework.org/schema/beans/spring-beans.xsd
>     http://www.springframework.org/schema/util 
> http://www.springframework.org/schema/util/spring-util-2.5.xsd";>
>
>     <bean name="exampleResource"
>         class="prova.ExampleResource" scope="prototype" />
>
>       <bean name="root" class="org.restlet.ext.spring.SpringRouter">
>               <property name="attachments" ref="resourceMap" />
>       </bean>
>
>       <bean id="resourceMap" class="java.util.HashMap">
>               <constructor-arg>
>                       <map>
>                               <entry key="/order">
>                                       <ref bean="exampleResource" />
>                               </entry>
>
>                       </map>
>               </constructor-arg>
>       </bean>
>
>
>     <bean id="exampleApplication"
>         class="firstSteps.FirstStepsApplication">
>     </bean>
>
> firstStepsApplication is:
> public class FirstStepsApplication extends Application {
>     public FirstStepsApplication(){}
>    public FirstStepsApplication(Context parentContext) {
>       super(parentContext);
>    }
>
>    /**
>     * Creates a root Restlet that will receive all incoming calls.
>     */
>    @Override
>    public synchronized Restlet createRoot() {
>       // Create a router Restlet that routes each call to a
>       // new instance of HelloWorldResource.
>        // Create the order handler
>
>
>
>         return new Router();
>    }
> }
>
> The response is: The server has not found anything matching the request URI
> you know what's wrong?
>
> Thank You!
> Marko
>
> ------------------------------------------------------
> http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447&dsMessageId=982819
>

------------------------------------------------------
http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447&dsMessageId=982925

Reply via email to