Question to all about visual webapps and Restlet

2007-04-10 Thread Jeff Walter
Hey All, Little philosophical/architectural question here... I'd like to know how many other people are using Restlet to build visual web applications, and how they feel about aggregating resource data on their pages? Let's take a simple example: We have a Resource for a thread on a forum: htt

Re: Reference not resolving

2007-04-10 Thread Justin C . van Vorst
Actually, Reference seems to have some odd behavior in general when constructed with baseRef. Depending on the construction one may end up with null values, odd values, wrong URIs, NullPointerExceptions, and infinite loops resulting in StackOverflowErrors. Here are my test cases: Reference host =

Basic Auth & Post -- Works the second time but not the first

2007-04-10 Thread Alex Milowski
I've been experiencing trouble with the basic auth implementation in that when I add a guard, the basic auth challenge is issue but the response does seem to be handled properly. What happens is that the brower (e.g. Firefox) pops the dialog for the authentication information but the POST doesn't

Re: Classpath or config?

2007-04-10 Thread Justin C . van Vorst
Classpath. Add teh following: com.noelios.restlet.ext.httpclient_3.1.jar org.apache.commons.httpclient.jar

RE: Reference not resolving

2007-04-10 Thread Jerome Louvel
Hi Justin, Thanks for reporting this. The getTargetRef() does a normalization which may not always be desired. Instead, there is the getIdentifier() method that should be used by the HTTP client connectors. We will look into fixing this ASAP. Best regards, Jerome > -Message d'origine

RE: Tracking exact amount of bytes transferred

2007-04-10 Thread Jerome Louvel
Hi Jeff, What you ask for it difficult, especially because we rely on pluggable HTTP connectors that don't commonly provide this type of information. In Restlet 1.1, we will add new connectors (one based on Grizzly NIO) that will let us have a direct control on the socket actions. At this point w

Reference not resolving

2007-04-10 Thread Justin C . van Vorst
When contructing a Reference using new Reference(baseRef, "relative-path"), a call to toString() returns just the relative part. It looks like the intended way to get the full URI is Reference.getTargetRef().toString(). Unfortunately HttpClientHelper:149 calls request.getResourceRef().toString()

Re: Tracking exact amount of bytes transferred

2007-04-10 Thread Jeff Walter
Hey Jerome, Thanks for your response. This is the way I would have liked to solve this problem (I also like the CountFilter idea), but unfortunately I need a little bit more accurate information. I did a simple test with a Directory and transferred some files, and I notice the log is written be

Re: Classpath or config?

2007-04-10 Thread Thierry Boileau
Hello Donald, this is a good remark. Your classpath need to be updated with some other jars. The Restlet framework is composed of 3 parts : restlet API, NRE implementation of this API and some extensions. Some of them are called "connectors" because they are responsible of linking two componen

Re: TemplateRepresentation

2007-04-10 Thread Sean Landis
Hi Jerome, Thanks for the clarification. I figured there must be some intent regarding the naming choices and I wanted to be sure it wasn't required. Regardless, I will rename my class to follow the conventions. Sean

Classpath or config?

2007-04-10 Thread Donald Strong
Hi, I am just setting up Restlet at home. (Restlet-1.0rc6.zip) I am just playing around at the moment and I have converted SimpleClient.java into a Junit test. I have com.noelios.restlet.jar and org.restlet.jar in my classpath but get this warning. (Using jre1.5.0_10). 10/04/2007 23:47:58 com.

Re: How to use the javamail connector?

2007-04-10 Thread Thierry Boileau
Hello Matthieu, just the time to send my post and I see your mail! :) Thanks for your experience, it shows clearly the kinds of issues that could happen with JBoss (and its system of classloaders). This maybe solved with a finest configuration of isolation in JBoss... And thanks again for point

Re: How to use the javamail connector?

2007-04-10 Thread Matthieu Hug
Jerome Louvel noelios.com> writes: > > > Hi Matthieu, > > Some thoughts: > > 1) Would it be possible that you have two applications/WARs/EARs deployed to > the same JBoss instance? > > 2) Maybe you have some older Restlet JARs in a JBoss common or shared > directory? > > 3) When you und

Re: TemplateRepresentation

2007-04-10 Thread Jerome Louvel
Hi Sean, FreeMarker and Velocity extension have their own package names, so the TemplateRepresentation class name isn't ambiguous if your consider the package name. However, the org.restlet.resource package contains many types of representations (XmlRepresentation, DomRepresentation, etc.) so

Re: Tracking exact amount of bytes transferred

2007-04-10 Thread Jerome Louvel
Hi Jeff, The approach I'm using is to rely on the access log information. The default format record the bytes returned. You could customize your log format to add the bytes received too. Then, you can use a tool such as http://www.analog.cx/ to generate reports. Another approach would be to

RE: How to use the javamail connector?

2007-04-10 Thread Jerome Louvel
Hi Matthieu, Some thoughts: 1) Would it be possible that you have two applications/WARs/EARs deployed to the same JBoss instance? 2) Maybe you have some older Restlet JARs in a JBoss common or shared directory? 3) When you undeploy your WAR/EAR and relaunch JBoss do your error messages go aw