On Fri, Dec 30, 2005 at 05:21:22PM +0100, Ugo Cei wrote: > Il giorno 30/dic/05, alle ore 16:09, Sylvain Wallez ha scritto: > > >>>I don't understand why you need a ThreadLocal. Isn't a class > >>>member good enough? > >> > >>How would a class member work with multiple threads? > > > >I see. This is because the HttpSource is referenced by the > >HttpSourceValidity, right? Now the serialization problem shows that > >it may not the right approach. Hmm.... what about using an common > >class used both by the source and validity classes to hold the > >common information? > > I was assuming that by "class member" you meant a static class > variable. That's where my doubts about multithreading arose. > > >>This works for file: URLs but fails for http: URLs, which was > >>totally unexpected to me and the cause of much frustration. > > > >Weird. Don't we get an exception of some kind on 404? > > For a file: source we get a ResourceNotFoundException, but for an > http: source we get a ProcessingException that wraps an IOException. > > >Indeed. My impression is that this work is concentrated it two main > >locations: the http source for incoming streams, and the pipeline > >engine for outgoing streams where we must better handle etags and > >last-modified headers. > > Right. > > I'm going on vacation in a few minutes, and I don't think I'll be > able to contribute much to this discussion or code in the next days, > but I'll catch up when I'm back if this thread goes on.
Resurrecting this important thread ... I tried your patch today. Nice. http://issues.apache.org/jira/browse/COCOON-1726 However i am not expert enough to comment on the implementation. All that i can say is: please. -David
