RE: Proxying with Redirector

2011-02-11 Thread weltermann17
Hi, we actually never got the Redirector working with modes MODE_SERVER_* (MODE_CLIENT_* were ok). We have a pretty complex intranet (Central Europe, Brasil, China and more) and when using the Redirector remote servers always replied with "404". Requesting the same url with a simple ClientResourc

Suggestion: modify (B|N)ioUtils.getChannel|Stream|Reader

2011-02-01 Thread weltermann17
Hi, the methods mentioned above in 2.1snapshot-jse all use a similar approach: An extra thread is started that writes a representation to a pipe's sink and the pipe's source is returned. In a server environment where representations are not only served statically, but processed in one way or anoth

Should NioUtils.copy(FileChannel fileChannel, ...) close fileChannel at the end?

2011-01-31 Thread weltermann17
Hi, compared to other methods in B/NioUtils the method NioUtils.copy(FileChannel fileChannel, WritableByteChannel writableChannel) does not close the input channel at the end. Is this on purpose? (2.1jse-snapshot) We use a caching mechanism based on Directory and found far too many file handle

Re: Again: gwt2.1-snapshot references java.nio.ByteBuffer (IoBuffer.java)

2011-01-24 Thread weltermann17
Hi Thierry, a very good idea. Thanks a lot. Guido Schmidt. -- View this message in context: http://restlet-discuss.1400322.n2.nabble.com/Again-gwt2-1-snapshot-references-java-nio-ByteBuffer-IoBuffer-java-tp5946953p5954518.html Sent from the Restlet Discuss mailing list archive at Nabble.com. -

Re: Threads never close for ClientResource

2011-01-21 Thread weltermann17
Hi TK, we had the same problem with ClientResource called within request handling on an JSE 2.1-snapshot server. Especially, when calls were not answered correctly (remote server not started, network timeouts etc.) the calling server soon run out of threads and became unresponsive. I think that t

Again: gwt2.1-snapshot references java.nio.ByteBuffer (IoBuffer.java)

2011-01-21 Thread weltermann17
Hi, again the current gwt 2.1snapshot references java.nio. Guido Schmidt. [INFO] --- gwt-maven-plugin:2.1.0-1:compile (default) @ GEPclient --- [WARNING] Don't declare gwt-dev as a project dependency. This may introduce complex dependency conflicts [INFO] Compiling module de.man.mn.gep.GEPclient

Re: If POST is first method connection is not established

2011-01-17 Thread weltermann17
Hello Thierry, sorry for not being precise. This is the configuration I use: - Restlet 2.1 snapshot JSE - Application server A: server using Jetty, client using Apache HttpClient - Application server B: server using Jetty - both servers on Java 1.6.SR8.FP1 on AIX 5.3 After restarting all servers

If POST is first method connection is not established

2011-01-14 Thread weltermann17
Hi, when using a ClientResource inside GWT-JSE 2.1snap to request a POST from another GWT-JSE 2.1snap server using Apache HttpClient the request times out whenever the POST is the first call to the remote server. It seems that the underlying connection is not established. As soon as a HEAD or GET

gwt-2.1snap: org/restlet/client/engine/io/Drainer.java imports java.nio

2011-01-13 Thread weltermann17
Hello, just in case nobody noticed yet: The gwt-2.1snap contains a Drainer.java that cannot be compiled by gwt due to an import of java.nio. gwt reports an error and continues, but I'm not sure if this could become an issue. Guido Schmidt. -- View this message in context: http://restlet-discu

RE: Serialization example: NoSuchMethodError on Router.attach

2010-12-06 Thread weltermann17
Hi, the current implementation in IOUtils is public static final int BUFFER_SIZE = getProperty( "org.restlet.engine.io.bufferSize", 8192); This is executed only once, afaik at module loading time. A call to setProperty should therefore be done before anything of the RESTlet engine

RE: BufferOverflowException when response size exceeds 8192 bytes

2010-12-01 Thread weltermann17
Hello Thierry, looking at the code this should be "org.restlet.engine.io.buffer.size" , shouldn't it. Best regards, Guido Schmidt. -- View this message in context: http://restlet-discuss.1400322.n2.nabble.com/BufferOverflowException-when-response-size-exceeds-8192-bytes-tp5747099p5791206.html

2.1 JSE : RecipientInfo/Via chokes on ":" in token

2010-11-04 Thread weltermann17
Hello, a small yet annoying problem can occur when using Redirector in an environments with a proxy. The string "webproxy.ag.man.de:8000" cannot be added to the "Via" header (see stacktrace). Http 14.45 Via explicitly allows a "host : port" so maybe it is not the ":" that causes the error. As a

Re: Ask REST router for resource's URIs ???

2010-04-23 Thread weltermann17
Hello Thierry, to your side note: Because Router.getRoutes still returns RouteList one is forced to use the deprecated class Route. Do you have plans to add a .getTemplateRoutes returning a TemplateRouteList or to modify .getRoutes? Best regards, Guido Schmidt -- View this message in context:

gwt (2010-04-08): ClientResource broken

2010-04-09 Thread weltermann17
Hello, the latest snapshot seems to have a problem with a simple HTTP GET: JsonResponse.handle() (see below) never gets called. On the server side the GET is never received. Switching back to rc2 resolves the issue. My scenario: public class SearchModel extends BaseModel { @Override

RE: Redirector.MODE_SERVER_OUTBOUND broken in snapshot

2010-03-29 Thread weltermann17
Hello Thierry, I tested the latest snapshot with Jetty and Grizzly using our slightly more complicated scenarios (redirection with local "RepresentationDirectoryCache") and everything works fine. Thanks for the excellent support. Best regards, Guido Schmidt -- View this message in context: htt

RE: Redirector.MODE_SERVER_OUTBOUND broken in snapshot

2010-03-26 Thread weltermann17
Hello Thierry, thanks for this quick response. I just tested with the latest snapshot and yes, when using the default http connector it works now. But when switching to Jetty there is still a stack overflow: INFO: Redirecting via client dispatcher to: http://10.128.60.177:8085/corporatedirectorywe

Redirector.MODE_SERVER_OUTBOUND broken in snapshot

2010-03-26 Thread weltermann17
Hello, in the current snapshot (20100325) Redirector.MODE_SERVER_OUTBOUND seems to be broken. To reproduce it I modified example Part10 to use this mode, added HTTP to the component's client protocols and switched the target to an internal server to avoid proxy issues. With any server I tried I re

Re: Why is the default http server so much faster than Jetty and Grizzly?

2010-03-25 Thread weltermann17
Reading the documentation as always helps: Switching the internal type for Jetty to BlockingChannelConnector (type=2) improves the performance dramatically: Results: troughput in megabytes per second (MB/sec) Internal/Default Jetty

Why is the default http server so much faster than Jetty and Grizzly?

2010-03-22 Thread weltermann17
Hello, as we come close to productive deployment I benchmarked some specific performance scenarios: Part of our solution serves huge files (100-500MB) in a 90% LAN, 10% WAN environment. Because these files can come from different (re-)sources they are filtered by a "RepresentationDirectoryCache" (

Re: 2.0snapshot Encoder.setMinimumSize broken

2009-12-15 Thread weltermann17
Hello, sorry for being so unspecific. I use a SE component with Jetty, the client is using the GWT edition. I tested with current versions of FF, Safari and Chrome. If the issue occurs they all show one or two characters missing at the end of a json string. Maybe with this small test case it beco

2.0snapshot Encoder.setMinimumSize broken

2009-12-14 Thread weltermann17
Hello, I used setMinimumSize to not gzip if everything fits into a mtu. In the current snapshot (not in m6) this cuts off the last two characters eg. of a json string when strings are short (below 400 bytes). This does not seem to be related to the size parameter, I tried with 100, 1000, 1 alw

Re: CacheDirective.maxAge(int) adds a quoted string to http headers

2009-12-08 Thread weltermann17
Hi Thierry, thanks for fixing this so quickly. I'll have a look at my scenarios when it's in the latest snapshot. Is there by any chance already a scheduled date for this? Regards, Guido Schmidt. -- View this message in context: http://n2.nabble.com/CacheDirective-maxAge-int-adds-a-quoted-str

CacheDirective.maxAge(int) adds a quoted string to http headers

2009-12-07 Thread weltermann17
Hi, thanks for making the CacheDirective stuff available, now. When setting max-age via the new mechanisms a line as follows is added: Cache-Control:max-age="3600" I'm absolutely no http expert. But with respect to RFC2616 14.6 "age values are non-negative integers". Can it be confirmed than ev

RE: 2.0snap GWT getEntity().getText() works again

2009-09-30 Thread weltermann17
Hi Jerome, getStream() is correctly only called once in the Restlet GWT stream-handling. It was an error in my debugging code. I called response.getEntity().getText() more than once. As the underlying representation on GWT always is an InputRepresentation the problem is more inside the getText met

RE: 2.0snap GWT getEntity().getText() works again

2009-09-30 Thread weltermann17
Hi Jerome, I will have a look at the double calling of getStream(). After browsing for just a few minutes I withdraw my question: Content-Length with encoding gzip seems to be a source for numerous disputes and incompatibilities. Not stating the length header is probably the more robust and ther

RE: 2.0m4/snap GWT cannot be used at all

2009-09-30 Thread weltermann17
Hi Jerome, yes, it's still there: eg. Window.alert(myValidReference.getTargetRef().toString()) will show the correct value in compiled mode and throw an uncaught exception in hosted mode on the console of the GWT hosting application due to IllegalAccessError on StringBuilder.append(StringBuilder).

RE: 2.0snap GWT getEntity().getText() works again

2009-09-29 Thread weltermann17
Hi Jerome, I could see that in M5 a check for Editon equals GWT was added and already thought that this would be a temporary fix only as it breaks the contract for InputRepresentation.getStream(). Reading the docs for getStream and isTransient makes it quite clear why a call to getStream().avail

Re: 2.0snap GWT getEntity().getText() works again

2009-09-25 Thread weltermann17
Hi, actually to make it work a second fix must be applied (sorry, forgot about it in the first post): In org.restlet.representation.InputRepresentation: @Override public InputStream getStream() throws IOException { final InputStream result = this.stream; setStream(null);

2.0snap GWT getEntity().getText() works again

2009-09-25 Thread weltermann17
Hi, I found another small (but fatal) issue in the GWT enum classes: In com.google.gwt.emul.java.io.InputStream the member "text" should become protected: protected String text; In com.google.gwt.emul.java.io.StringBufferInputStream: remove: protected String text; modify: public Strin

2.0snap GWT Client.handle works again

2009-09-24 Thread weltermann17
Hi, I found a subtle small bug in google.gwt.emul.java.uti.concurrent.CopyOnWriteArrayList: public CopyOnWriteArrayList(Collection c) { super(); this.list = new ArrayList(); this.list.addAll(list); } It should be: this.list.addAll(c); This caused Engine.

2.0m4/snap GWT cannot be used at all

2009-09-23 Thread weltermann17
Hi, several posts have raised the issue that the current GWT edition cannot be used anymore. Calling a Client.get works only in hosted but not in compiled mode. Using Reference.getTargetRef fails in hosted mode with a "IllegalAccessError" exception due to a call to StringBuilder.append(StringBui