Sriram C | 1 Sep 2010 02:10

RE: JAXRS, Transactional Resources managed by Spring

Jerome,
I am running with 2.0.RC2. I am not sure that there is a memory leak.
However I have noticed that the service resource objects are not immediately
cleaned up after a request has been fulfilled - they seem to linger around
even after the request has been fulfilled. They seem to be getting garbage
collected eventually since the peak memory usage doesn't exceed 0.8 GB out
of a total of 3 GB. Is there any way I can configure or tune either Spring
or Restlet or JVM settings for the resources to be gc'd immediately after
the response is sent to the requestor? This will result in more efficient
memory usage. 

This works fine for my current peak usage of ~200 requests a minute but I am
afraid that this might be a bottleneck/performance impediment if I were to
grow past my current usage.

Any thoughts or ideas to address this issue would be highly appreciated.
Sriram
--

-- 
View this message in context: http://restlet-discuss.1400322.n2.nabble.com/JAXRS-Transactional-Resources-managed-by-Spring-tp5224091p5484973.html
Sent from the Restlet Discuss mailing list archive at Nabble.com.

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

Alois Cochard | 1 Sep 2010 08:03
Picon
Gravatar

Re: Bad handling of InputStream inside servlet container (ie: Tomcat)

Hello Jerome,


Thanks a lot for the fast fixing !

You guys rocks, really :)

Bonne continuation,

Alois Cochard
http://www.twitter.com/aloiscochard

On 28 August 2010 18:24, Jerome Louvel <jerome.louvel <at> noelios.com> wrote:
Hi Alois,

FYI, I've just fixed this in SVN trunk by wrapping both input and output Servlet stream to prevent them from being closed by Restlet.

Best regards,
Jerome
--
Restlet ~ Founder and Technical Lead ~ http://www.restlet.o​rg
Noelios Technologies ~ http://www.noelios.com




-----Message d'origine-----
De : Thierry Boileau [mailto:thierry.boileau <at> noelios.com]
Envoyé : vendredi 20 août 2010 11:16
À : discuss <at> restlet.tigris.org
Objet : RE: Bad handling of InputStream inside servlet container (ie: Tomcat)

Hell Alois,

thanks for your report that makes sense. I've entered an issue for that point : http://restlet.tigris.org/issues/show_bug.cgi?id=1162.

Best regards,
Thierry Boileau

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

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

Thierry Boileau | 1 Sep 2010 10:02
Picon

Re: Re: Optional authentication and ClientInfo.getAuthenticated()

Hello Esteban,

you can check request.getClientInfo().isAuthenticated

Best regards,
Thierry Boileau



For now, I am checking if it is authenticated or not to my application with
this line of code.

           if (request.getClientInfo().getUser() == null) {
              // Not authenticated
              .....
           }

This is correct?
Best regards.
Esteban
--
View this message in context: http://restlet-discuss.1400322.n2.nabble.com/Optional-authentication-and-ClientInfo-getAuthenticated-tp5381324p5469730.html
Sent from the Restlet Discuss mailing list archive at Nabble.com.

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

Thierry Boileau | 1 Sep 2010 11:00

RE: Jackson Dependencies

Hello Doug,

>Why return 405 instead of 500 in a case like this, though?
Well, this is a good question. 405 status may sound a little bit unappropriate because the resource is
described as able to handle POST requests, but the lack of json converter make it unavailable to do so. I've
entered an RFE: http://restlet.tigris.org/issues/show_bug.cgi?id=1172.

Best regards,
Thierry Boileau

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

Thierry Boileau | 1 Sep 2010 11:50

RE: Hang when calling setStatus with CLIENT_ERROR_BAD_REQUEST

Hello,

Nothing special should happen, at first look. Could you provide a sample test case?

Best regards,
Thierry Boileau

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

Thierry Boileau | 1 Sep 2010 12:07

RE: 405 on unsupported media type

Hello,

thansk Avi, I've completed the issue 1172 (http://restlet.tigris.org/issues/show_bug.cgi?id=1172).

Best regards,
Thierry Boileau

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

Thierry Boileau | 1 Sep 2010 12:17

RE: Ideal restlet_GWT configuration ? how to retrieve json with the GWT edition of restlet ?

Hello Ben,

from the client side, you can specify the accepted media types, by setting the HTTP "accept" header.
A Restlet client resource can do this as follow (explained in the wiki [1]) : cr.get(MediaType.APPLICATION_JSON).write(System.out);

or by updating its client data:
cr.getClientInfo().getAcceptedMediaTypes().add(new
Preference<MediaType>(MediaType.APPLICATION_JSON));

If the client is not able to update the accept header, there is a workaround, you can add a parameter to the
query part of the resource's uri:
http://server/path/to/resource?media=json

If this does not work, please let us know, this is a bug.

Best regards,
Thierry Boileau

[1] http://wiki.restlet.​org/docs_2.0/13-rest​let/21-restlet/318-r​estlet/303-restlet.h​tml

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

Thierry Boileau | 1 Sep 2010 14:54

RE: Android client : how to add cookies ?

Hello Pierre-Yves,

>The JacksonRepresentation should not return null when not being able to parse a JSON stream, it should
throw an exception. Otherwise, how can we handle errors ?

I've entered an issue for that topic.
http://restlet.tigris.org/issues/show_bug.cgi?id=1173

>I'll post a bug report on the Jackson framework page.
Thanks for reporting this issue.

Best regards,
Thierry Boileau

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

Richard Brewster | 1 Sep 2010 17:22
Favicon

How to configure HttpClientHelper global parameters?

I have read this:

http://www.restlet.org/documentation/2.0/jse/ext/org/restlet/ext/httpclient/HttpClientHelper.html

But, after a lot of searching, I have found no examples how this is actually
configured.

Secondly, I want to use the org.apache.httpcomponents httpclient for
ClientResouce connector.  I put the jars in my classpath.  How can I tell
that they are actually used?  I need some logging enabled, but where to
configure that?

I am using Restlet 2.0.0 JEE version with the Servlet and Spring extensions,
deploying to Tomcat.

Thanks,

Richard
--

-- 
View this message in context: http://restlet-discuss.1400322.n2.nabble.com/How-to-configure-HttpClientHelper-global-parameters-tp5487535p5487535.html
Sent from the Restlet Discuss mailing list archive at Nabble.com.

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

Thierry Boileau | 1 Sep 2010 17:44

RE: How to configure HttpClientHelper global parameters?

Hello Richard,

the answer is located in the user guide, in the chapter called "connectors": http://wiki.restlet.org/docs_2.0/13-restlet/37-restlet.html.

Regarding the configuration of the logging, you can have a look here: http://wiki.restlet.org/docs_2.0/13-restlet/101-restlet.html

Best regards,
Thierry Boileau

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


Gmane