Hello! I am trying to create the application, which uses the server and routers, defined in the context of the Spring application. The main context looks like below:
<?xml version="1.0" encoding="UTF-8"?>
<beans
xmlns="http://www.springframework.org/schema/beans"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
http://www.springframework.org/schema/context
http://www.springframework.org/schema/context/spring-context-2.5.xsd">
<context:property-placeholder location="file:etc/config.properties"/>
<bean
id="top"
class="org.restlet.ext.spring.SpringComponent">
<property
name="server">
<bean
class="org.restlet.ext.spring.SpringServer">
<constructor-arg
value="http" />
<constructor-arg
value="3000" />
</bean>
</property>
<property
name="defaultTarget"
ref="root" />
</bean>
<import
resource="classpath:/spring/applicationContext-router.xml" />
</beans>
Everything looks good and the server is starting up well, I am able to connect
to the server and invoke the REST requests and they are working fine from the
Java client.
But I've found if I connect to the server using telnet like this:
#> telnet localhost 3000
the connection is being closed after 1 or 2 seconds. Looks like there is some
timeout for reading from a socket? I tried to debug the code and currently I
guess the problem is somewhere in the simple.http.connect.Connection class
from org.simpleframework.simple package. This package seems to be the
dependency of the com.noelios.restlet.ext.simple package.
Can somebody please advice, what can cause such a weird problem and how to fix
it? May be I am doing something in a wrong way?
Thank you in advance!
--
Eugene Dzhurinsky
------------------------------------------------------
http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447&dsMessageId=1001374
pgpX79Z2aWh6R.pgp
Description: PGP signature

