SpringServer parameters

2007-11-20 Thread Kevin Conaway
couldn't seem to find the link to create a new issue at: http://restlet.tigris.org/servlets/ProjectIssues Is there another way to create an issue in the tracker? Thanks, Kevin Conaway

Using FileRepresentation

2007-11-21 Thread Kevin Conaway
What is the proper way to use FileRepresentation inside Resource.getRepresentation(Variant)? I'd like to send the user a file if they browse to a certain URI. However, when I browse to that URI, it sends me the file, but the original it doesn't send a filename with it. Also, why must I set an

Re: SpringServer parameters

2007-11-26 Thread Kevin Conaway
, it is hosted by Tigris.org and we have little control on it. I've checked the configuration options and didn't find anything related. Best regards, Jerome -Message d'origine- De : Kevin Conaway [mailto:[EMAIL PROTECTED] Envoyé : mercredi 21 novembre 2007 16:32 À : discuss

Dynamic properties for Jetty connectors

2007-11-26 Thread Kevin Conaway
are either Strings, booleans or ints so doing a conversion would not be a huge issue. Sincerely, Kevin Conaway

Re: ConverterService architecture

2007-11-28 Thread Kevin Conaway
You could do it via reflection: import java.lang.reflect.*; public class ConverterService { public void convert(Object o) throws Exception{ for (Method m : getClass().getDeclaredMethods()) { if (m.getName().equals(handle)) { Class? paramType =

Re: ConverterService architecture

2007-11-29 Thread Kevin Conaway
you're not expecting). - Paul On Nov 28, 2007, at 3:12 PM, Kevin Conaway wrote: You could do it via reflection: import java.lang.reflect.*; public class ConverterService { public void convert(Object o) throws Exception{ for (Method m : getClass().getDeclaredMethods

Re: Lightweight alternative to Reference

2007-11-29 Thread Kevin Conaway
: Kevin Conaway kevin.conaway at gmail.com writes: Would it be possible add a new class called URI to facilitate building URIs to use in client calls? It can be cumbersome to either build the uri as a string by hand or use the heavy Reference class.I suggest adding a lightweight class called

Re: Lightweight alternative to Reference

2007-11-29 Thread Kevin Conaway
It could have methods starting with append like the StringBuilder class, and follow the Reference naming convention. For example it could have: - appendScheme(String scheme) - appendSchemeSpecificPart(String ssp) - appendFragment(String fragment) - appendHierarchicalPart(String ssp)

Re: Lightweight alternative to Reference

2007-11-29 Thread Kevin Conaway
Since URISyntaxException is checked, I see no reason why the ReferenceBuilder shouldn't throw a checked exception as well. I propose the following: ReferenceBuilder(Protocol, host, port, authority) // Convenience constructors ReferenceBuilder appendPath(String unencodedPath); ReferenceBuilder

Re: SocketException using PUT

2007-12-11 Thread Kevin Conaway
be done at a later point. Kevin On Dec 11, 2007 3:32 PM, Kevin Conaway [EMAIL PROTECTED] wrote: I'm experiencing a SocketException everytime I try to send a representation using PUT. The error I receive is: java.net.SocketException: socket closed

Multiple issues with PUT representations

2007-12-12 Thread Kevin Conaway
of bytes read. I've created the following issue and attached a patch/testcase to it: http://restlet.tigris.org/issues/show_bug.cgi?id=397 Sincerely, Kevin Conaway

Re: Limiting threads

2007-12-18 Thread Kevin Conaway
It appears to depend on the connector. The simple and jetty connectors support configuration of the thread count, the default connector, as of yet, does not. kevin On Dec 18, 2007 12:41 AM, Paul J. Lucas [EMAIL PROTECTED] wrote: Is it possible to limit the number of threads that Restlet

Re: ServerServlet broken by concurrency fix in 1.1M1

2007-12-28 Thread Kevin Conaway
I attached your patch to 368. setProtocols() could be renamed to addProtocols() with the protocols.clear() call removed. That communicates the intention a little better. On Dec 28, 2007 5:28 PM, Tim Peierls [EMAIL PROTECTED] wrote: I think it's easier to reason about the correctness when

Re: Request in checkSecret()

2008-01-04 Thread Kevin Conaway
Perhaps some kind of hook would be appropriate in authenticate(). Adding that kind of behavior to checkSecrets() feels bolted on to me because checkSecrets() now becomes check secrets, but maybe do some other stuff too Perhaps in authenticate(), if checkSecrets() is true, call

Re: Shutting down a server

2008-01-10 Thread Kevin Conaway
Bug the Simple developers. I am absolutely astonished that they don't provide a clean way to shut down their server. On Jan 10, 2008 2:59 AM, Paul J. Lucas [EMAIL PROTECTED] wrote: Well, I just tried calling System.exit(0) and nothing happens: the process doesn't exit. FYI: I'm using the

Re: Shutting down a server

2008-01-10 Thread Kevin Conaway
already. Apparently it requires some internal redesign, see this reply from Simple's author : http://sourceforge.net/mailarchive/message.php?msg_name=20061104190803.23377.qmail%40web36705.mail.mud.yahoo.com Best regards, Jerome 2008/1/10, Kevin Conaway [EMAIL PROTECTED]: Bug the Simple

Re: Restlet 1.1 M1 Spring Extension issue

2008-01-13 Thread Kevin Conaway
Did you modify the test case at all? I noticed the snippet you posted has the @Test annotation whereas the code in SVN trunk does not have that annotation. The test in the trunk runs fine. On Jan 13, 2008 1:36 AM, dev dev [EMAIL PROTECTED] wrote: Without looking at the Restlet code, i'm having

Re: PUT with no entity (architecture question)

2008-01-14 Thread Kevin Conaway
Are you overriding allowPut() in your Resource class? You need to do as such: @Override public boolean allowPut() { return true; } On Jan 13, 2008 10:20 PM, Rhett Sutphin [EMAIL PROTECTED] wrote: Hi, I'm designing implementing my first REST-style API. It's for an existing application.

Re: Directory

2008-01-14 Thread Kevin Conaway
, Valdis Rigdon [EMAIL PROTECTED] wrote: Yep, I've tried that. In walking through the code via a debugger, I see my APPLICATION_ZIP representation being built, but it's not the representation being returned -- the StringRepresentation is with the HTML contents. Valdis Kevin Conaway wrote

Re: PUT with no entity (architecture question)

2008-01-14 Thread Kevin Conaway
interpretation of the spec is that an entity is required for a PUT On Jan 14, 2008 10:14 AM, Rhett Sutphin [EMAIL PROTECTED] wrote: Hi Kevin, On Jan 14, 2008, at 8:38 AM, Kevin Conaway wrote: Are you overriding allowPut() in your Resource class? You need to do as such: @Override

Re: ant build error against the trunk

2008-01-18 Thread Kevin Conaway
Were there any other stack traces in the test case logs? I believe that the grizzly connector is still not complete On Jan 18, 2008 9:22 PM, dev dev [EMAIL PROTECTED] wrote: Got this error when running ant under restlet/build/ on Ubuntu 7. Please help. (Ant version 1.7). From

Re: SpringServer Parameters NOT WORKING (HELP!)

2008-02-05 Thread Kevin Conaway
How are you loading the spring config? On Feb 5, 2008 2:21 PM, dev dev [EMAIL PROTECTED] wrote: We have spent a bit of time on this and we cannot seem to find ways to get this to work for such a simple configuration. We are using version 1.1-M2. Simple method to start the server. public

Re: Failed during the build with the latest version from the trunk

2008-02-11 Thread Kevin Conaway
I also receive errors running the test case by itself in Eclipse. On Feb 11, 2008 8:51 AM, Jerome Louvel [EMAIL PROTECTED] wrote: Hi Stephan, There can be some differences (classpath) between running the Ant test cases from Eclipse compared to command line. I think people have the errors

Re: Failed during the build with the latest version from the trunk

2008-02-11 Thread Kevin Conaway
(for example) the entity is needed or anything else to request it from the response. I think this is a bug in the Restlet API. I will submit a bug report. best regards Stephan Kevin Conaway schrieb: I also receive errors running the test case by itself in Eclipse. On Feb 11, 2008

CLOSE_WAIT and FIN_WAIT_2

2008-02-14 Thread Kevin Conaway
When using the default connectors, Restlet does not seem to be properly closing connections. If I make a number of requests to a resource and run netstat, I will see a number of connections in the CLOSE_WAIT and FIN_WAIT_2 state. This tells me that something is not getting closed properly. Is

Re: CLOSE_WAIT and FIN_WAIT_2

2008-02-15 Thread Kevin Conaway
sockets after it handles them and that seemed to shift a different problem to the server in that there were some TIME_WAIT sockets lingering. On Fri, Feb 15, 2008 at 8:11 AM, Kevin Conaway [EMAIL PROTECTED] wrote: Hi Jerome, Thanks for getting back to me. I'll build from the latest trunk and let

Re: How to get Client IP address

2008-02-18 Thread Kevin Conaway
Which connector and version are you using? There was a recent issue about this: http://restlet.tigris.org/issues/show_bug.cgi?id=425 On Feb 18, 2008 3:12 AM, code dude [EMAIL PROTECTED] wrote: Hi All, I am trying to implement IP based authentication where a user is request is only allowed

Re: How to get Client IP address

2008-02-19 Thread Kevin Conaway
You should just be able to check the code out from svn, cd to the build directory and run ant On 2/19/08, code dude [EMAIL PROTECTED] wrote: Hi All, Thanks for quick reply could you tell us what kind of server connector are you using? And I am using http connector

Re: CLOSE_WAIT and FIN_WAIT_2

2008-02-22 Thread Kevin Conaway
Which is better: Having sockets on the client side in FIN_WAIT_2 and CLOSE_WAIT or Having sockets on the server side in TIME_WAIT On Tue, Feb 19, 2008 at 8:00 AM, Jerome Louvel [EMAIL PROTECTED] wrote: Hi Kevin, [...] If the client does consume the response entity, is he still

Re: Unable to pass parameter to a Resource -- restlet application deployed on tomcat

2008-02-23 Thread Kevin Conaway
This was noted in a recent issue: http://restlet.tigris.org/issues/show_bug.cgi?id=414 On Sat, Feb 23, 2008 at 12:37 PM, Thierry Boileau [EMAIL PROTECTED] wrote: Hello Nilesh, as stated by the URI specification, the query is a part of the resource identifier (the URI), and thus not part of

Re: Shut down a Restlet server using kill?

2008-03-07 Thread Kevin Conaway
You should just down a Restlet server like any other java application, either with QUIT on unix or Control-Break on Windows. That will allow the jvm to gracefully shutdown by running finalizers and shutdown hooks. Sincerely, Kevin Conaway On Thu, Mar 6, 2008 at 2:28 PM, Aaron Crow [EMAIL

Re: StreamClientCall and FH exhaustion

2008-03-17 Thread Kevin Conaway
Its my understanding that the socket can't be automatically closed by Restlet because the response entity body isn't ready until the caller decides to access it. If this is correct, I think its up the client to some how alert the Client or the Response that he is through with the entity On Mon,

Re: StreamClientCall and FH exhaustion

2008-03-22 Thread Kevin Conaway
pending: http://restlet.tigris.org/issues/show_bug.cgi?id=439 We hope to have that fixed in 1.1 M3 at the end of the month. Best regards, Jerome -Message d'origine- De : Kevin Conaway [mailto:[EMAIL PROTECTED] Envoyé : mardi 18 mars 2008 00:36 À : discuss@restlet.tigris.org

Re: StreamClientCall and FH exhaustion

2008-03-23 Thread Kevin Conaway
. Best regards, Jerome -Message d'origine- De : Kevin Conaway [mailto:[EMAIL PROTECTED] Envoyé : samedi 22 mars 2008 13:33 À : discuss@restlet.tigris.org Objet : Re: StreamClientCall and FH exhaustion Would it make sense to add an option to the Client or Request

Re: Submitting JSON object to Resource via a HTTP PUT

2008-03-24 Thread Kevin Conaway
Hi Ian, I believe you should override Resource.storeRepresentation() and override Resource.allowPut() - true instead of overriding Resource.put() As for your documentation concerns, I would explain that sending JSON is no different than sending any other text-based request entity. You should

Re: Submitting JSON object to Resource via a HTTP PUT

2008-03-24 Thread Kevin Conaway
, 2008 at 11:18 AM, Ian Clarke [EMAIL PROTECTED] wrote: On Mon, Mar 24, 2008 at 10:07 AM, Kevin Conaway [EMAIL PROTECTED] wrote: I believe you should override Resource.storeRepresentation() and override Resource.allowPut() - true instead of overriding Resource.put() I don't think

Re: StreamClientCall and FH exhaustion

2008-03-24 Thread Kevin Conaway
, Kevin Conaway [EMAIL PROTECTED] wrote: Jerome, I think you misunderstood me. I was suggesting it might be useful to allow the client to tell Restlet to read and store the response entity to be consumed later. If the response entity is read right away and stored, there would be no need

Re: StreamClientCall and FH exhaustion

2008-03-25 Thread Kevin Conaway
of the input stream should actually close the socket input stream and as a consequence the socket. Do you obtain results that suggest it isn't happening like this? Best regards, Jerome -Message d'origine- De : Kevin Conaway [mailto:[EMAIL PROTECTED] Envoyé : lundi 24 mars 2008 18:47 À

Re: StreamClientCall and FH exhaustion

2008-03-25 Thread Kevin Conaway
(more getContentLength() refactoring). Added complete() handling on SimpleCall as well. Best regards, Jerome -Message d'origine- De : Kevin Conaway [mailto:[EMAIL PROTECTED] Envoyé : mardi 25 mars 2008 21:18 À : discuss@restlet.tigris.org Objet : Re: StreamClientCall and FH

Re: How do I switch off log output?

2008-04-08 Thread Kevin Conaway
So the solution to the confusion surrounding the various log frameworks in use by Restlet and its components isanother log framework? :) As much as I'm against using one of the bridge frameworks for logging, it might make sense for Restlet seeing as how the various components all could (and

Re: Downloading Audio file using Restlet

2008-04-14 Thread Kevin Conaway
You should return a FileRepresentation or a StreamRepresentation with the data and the appropriate media type. I think MediaType.AUDIO_WAV would work On Mon, Apr 14, 2008 at 5:19 PM, Nilesh Vyas [EMAIL PROTECTED] wrote: Hi All, I am in the process of writing an application which reads a voice

Re: What about : RESTlet in official Maven Repository ?

2008-05-14 Thread Kevin Conaway
Their automatic process could be an option but it requires us to give them an SSH access to our server which we are reluctant to do for security reasons mainly. I believe that you can also have your project sync'd over SVN. If you have the maven repository also be an SVN repository, I

Re: Restlet causing JVM crashes

2008-06-09 Thread Kevin Conaway
Hi Mark, I had the same problem as you. I tweaked some lines of code in that class and recompiled and the issue went away. It feels like a bug in the JVM because the error is happening when Hotspot decides to recompile the class. I never did figure out what was causing it. I had posted to

Re: Help: IE chunked-http problem

2008-06-09 Thread Kevin Conaway
Ralf, can you open a ticket for this? Perhaps we're not setting the correct header combination or IE requires a strange one to parse chunked encodings. On Fri, Jun 6, 2008 at 11:47 AM, Ralf Bommersbach [EMAIL PROTECTED] wrote: Ok thanks that helped a lot! I use now the jetty server-connector

Re: Hanging on ServerSocket.accept()

2008-07-04 Thread Kevin Conaway
Next time the server blocks, send a thread dump to the list. I'd like to see what's hanging. Cheers, Kevin On Thu, Jul 3, 2008 at 2:38 PM, Paul J. Lucas [EMAIL PROTECTED] wrote: When launching my application, perhaps 1/10 times, the underlying web server gets stuck in ServerSocket.accept().

Re: Hanging on ServerSocket.accept()

2008-07-10 Thread Kevin Conaway
Please attach a thread dump to your bug report. On Thu, Jul 10, 2008 at 4:27 AM, Jerome Louvel [EMAIL PROTECTED] wrote: Hi Paul, Thanks for the details, this needs to be looked at more closely. Could you enter a bug report? http://www.restlet.org/community/issues Best regards, Jerome

Re: Hanging on ServerSocket.accept()

2008-07-11 Thread Kevin Conaway
/show_bug.cgi?id=528 I have no clue for now, any help is welcome. Best regards, Jerome -- *De :* Kevin Conaway [mailto:[EMAIL PROTECTED] *Envoyé :* jeudi 10 juillet 2008 14:50 *À :* discuss@restlet.tigris.org *Objet :* Re: Hanging on ServerSocket.accept() Please

Re: Restlet causing JVM crashes

2008-07-21 Thread Kevin Conaway
versions. Mark On Tue, Jun 10, 2008 at 12:12 AM, Kevin Conaway [EMAIL PROTECTED] wrote: Hi Mark, I had the same problem as you. I tweaked some lines of code in that class and recompiled and the issue went away. It feels like a bug in the JVM because the error is happening when Hotspot

Re: ExecutorService (Was: 1.1m4 release notes)

2008-07-29 Thread Kevin Conaway
Whichever way you end up going, can you make sure to pass the ExecutorService a ThreadFactory which names Thread appropriately? Having descriptive thread names is extremely helpful when using jconsole or viewing thread dumps. Thanks, Kevin On Tue, Jul 29, 2008 at 8:17 PM, Tim Peierls [EMAIL

Re: Sockets not closed with restlet dev

2008-07-29 Thread Kevin Conaway
Hi Remi Can you run netstat to show what state the sockets are in? If they are in TIME_WAIT, they will eventually get recollected by the server. Otherwise, are you consuming and closing the request/response entities? Kevin On Tue, Jul 29, 2008 at 10:43 AM, Rémi Dewitte [EMAIL PROTECTED]wrote:

Re: release() method - doesn't appear to release connections?

2008-08-11 Thread Kevin Conaway
Can you post a thread dump of the system when the code is blocked? Which client + server connectors were you using when this issue occurred? On Wed, Aug 6, 2008 at 10:41 PM, Eric Lui [EMAIL PROTECTED] wrote: I'm new to the world of Restlet, but i'm finding it a really expressive framework.

Using OPTIONS to describe a Resource

2008-09-25 Thread Kevin Conaway
What are peoples thoughts on using the OPTIONS method to describe what types of input a resource can handle? The HTTP spec says: The OPTIONS method represents a request for information about the communication options available on the request/response chain identified by the Request-URI

Re: Is ByteUtils.toString(Reader) needlessly slow?

2008-10-07 Thread Kevin Conaway
I don't know of a reason why it doesn't do buffered reads. I do know that the Reader interface is designed for working with characters whereas the InputStream interface is designed for working with bytes. Can you recompile with an implementation that does buffered reads and see if that solves

Re: Spring Engine

2008-10-17 Thread Kevin Conaway
connectors to use? Best regards, Jérôme Louvel -- Restlet ~ Founder and Lead developer ~ http://www.restlet.org Noelios Technologies ~ Co-founder ~ http://www.noelios.com -- *De :* Kevin Conaway [mailto:[EMAIL PROTECTED] *Envoyé :* mercredi 15 octobre 2008 18:44 *À

Protocol should determine confidentiality of Request

2008-10-21 Thread Kevin Conaway
When making a Client call, I think it would be helpful to set the confidential attribute on the Request for the user based on the Protocol. I.e., if I'm using the HTTPS protocol, I shouldn't have to remember to set the confidential attribute to true on every Request. I'm not where the best place

Re: Restlet Spring and Guards

2008-10-21 Thread Kevin Conaway
Both the Application class and SpringRouter classes are instances of Restlet so I don't believe you need an Application instance. Wherever you have injected your SpringRouter, simply inject your Guard class with the SpringRouter as the next property. Kevin On Mon, Oct 20, 2008 at 8:19 AM,

Re: Protocol should determine confidentiality of Request

2008-10-22 Thread Kevin Conaway
Technologies ~ Co-founder ~ http://www.noelios.com -- *De :* Kevin Conaway [mailto:[EMAIL PROTECTED] *Envoyé :* mardi 21 octobre 2008 23:16 *À :* discuss@restlet.tigris.org *Objet :* Re: Protocol should determine confidentiality of Request In Restlet-619, I added SSL

Re: Protocol should determine confidentiality of Request

2008-10-22 Thread Kevin Conaway
an exception or return forbidden status) if a request that is supposed to be confidential isn't. There is an analogue in the Servlet world that is used similarly. On Wed, Oct 22, 2008 at 8:30 AM, Kevin Conaway [EMAIL PROTECTED]wrote: Is the confidential property on the Request (or Message) even

Re: Restlet 1.1.0 released!

2008-10-28 Thread Kevin Conaway
://www.restlet.org/ Direct contributors: - Aaron Crow - Aaron Roberts - Adam Harris - Bruce Lee - Diego Ballve - Erik Beeson - Jérôme Bernard - Kevin Conaway - Richard Hoberman - Tim Peierls In addition, we have significantly expanded our documentationhttp

Issue 694

2009-01-18 Thread Kevin Conaway
for the issue. Sincerely, Kevin Conaway -- http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447dsMessageId=1033021

Re: Issue 694

2009-01-19 Thread Kevin Conaway
by the internal client connector. I've attached a patch for the issue. Sincerely, Kevin Conaway -- http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447dsMessageId=1034012 -- http

Re: Issue 694

2009-01-19 Thread Kevin Conaway
, Kevin Conaway -- http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447dsMessageId=1034012 http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447dsMessageId=1034012

Re: Issue 694

2009-01-20 Thread Kevin Conaway
Noelios Technologies ~ Co-founder ~ http://www.noelios.com -- *De :* Kevin Conaway [mailto:kevin.cona...@gmail.com] *Envoyé :* lundi 19 janvier 2009 14:59 *À :* discuss@restlet.tigris.org *Objet :* Re: Issue 694 Is it possible to give permissions to reopen

Re: Restlet 1.2 M1 released

2009-01-23 Thread Kevin Conaway
Congrats Jerome, Thierry and everyone else. On Fri, Jan 23, 2009 at 2:24 PM, Jerome Louvel jerome.lou...@noelios.comwrote: Hi all, Here it is, the first 1.2 milestone! All the details in our blog: http://blog.noelios.com/2009/01/23/restlet-12-m1-released/ Best regards, Jérôme Louvel --

Engine configuration

2009-02-25 Thread Kevin Conaway
Are there any plans to change the way the default Engine is configured? As of now, there is no easy way to configure the default Engine from Spring using simple setters for the ClientHelpers, ServerHelpers, etc. Would it be acceptable to add the various *Helper classes as overloaded constructor

Re: Spring Engine

2009-02-28 Thread Kevin Conaway
, authenticators and converters). Best regards, Jerome Louvel -- Restlet ~ Founder and Lead developer ~ http://www.restlet.org Noelios Technologies ~ Co-founder ~ http://www.noelios.com -- *De :* Kevin Conaway [mailto:kevin.cona...@gmail.com] *Envoyé :* vendredi 20

Re: Spring Engine

2009-03-02 Thread Kevin Conaway
-founder ~ http://www.noelios.com -- *De :* Kevin Conaway [mailto:kevin.cona...@gmail.com] *Envoyé :* vendredi 20 février 2009 01:01 *À :* discuss@restlet.tigris.org *Objet :* Re: Spring Engine Hi Jerome, What is the status of the engine refactoring? On Fri

Re: Spring + Restlet 1.2-SNAPSHOT, NullPointerException

2009-04-08 Thread Kevin Conaway
Hi Jerome, There is a bug specifically with the SpringFinder class. The parent Finder was refactored such that it now checks to see that the targetClass property is an instance of Handler. Previous versions of the class did not depend on targetClass to be non-null. Since the SpringFinder only