cxf-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dan Diephouse" <>
Subject Re: heads up: rename abstractcachedoutputstream?
Date Tue, 12 Jun 2007 04:55:35 GMT
Now if only I could get the last two failing tests to pass ... :-)

Seeing that this changes the low level stuff a bit - here's a copy of the
patch if anyone wants to view it (apologies for the System.out.printlns):

It all works except for the HTTPConduit 401 test and the Validation test.
Here's the commit message I have written:

Refactoring of the low level IO layer inside CXF.

Remove the dependence on flush() being called ONCE and only once
inside CXF. Ensure that the RM and Logging layers correctly do
their work on close() instead of flush().

Transports now directly write to the stream. The RM layer and logging
interceptors correct detect when a cached stream is not being used
and act accordingly. This is much more robust as I/O transformations
are a very valid use case an many people will want to switch the
underlying streams. We also shouldn't force transport writers to
use CachedOutputStream.

Rename AbstractCachedOutputStream to CachedOutputStream and make
it a non-abstract class. This cuts down on the number of CachedOutputStream
classes laying around! There are now two extended implementations of
COS as well:
1. WriteOnCloseOutputStream. This caches the message until the outputstream
is closed. This is needed for the RM scenarios where we are caching the
until the CreateSequence is done. We don't want to open the connection until
all of this is done. (I think we could probably reset this output stream
as soon as the createsequence is finished though)
2. CacheAndWriteOutputStream. This caches the message while it is written
to the underlying stream at the same time. Useful for logging.

Update the DataBinding code to have JAXB write directly to the OutputStream
whenever possible. This gives a great performance improvement for some

Refactor the JAXB code so we don't have so many data readers/writers.

- Dan

On 6/11/07, Liu, Jervis <> wrote:
> Hi Dan, good to see you start to look into this. A quick search through
> our code base shows that there are 9 classes extend from
> AbstractCachedOutputStream, changing AbstractCachedOutputStream to
> CachedOutputStream should make it possible to use CachedOutputStream
> directly in some cases thus reduce unnecessary sub-classes of
> AbstractCachedOutputStream.
> Cheers,
> Jervis
> > -----Original Message-----
> > From: Dan Diephouse []
> > Sent: 2007?6?12? 3:00
> > To:
> > Subject: heads up: rename abstractcachedoutputstream?
> >
> >
> > I've been doing some low level refactoring of the IO layer to
> > clean things
> > up a bit. I'd like to rename AbstractCachedOutputStream to just
> > CachedOutputStream as it can be used standalone. Anyone have
> > any objections?
> > Don't want to break a lot of code this late in the process....
> > Thanks,
> > - Dan
> >
> > --
> > Dan Diephouse
> > Envoi Solutions
> > |
> >
> ----------------------------
> IONA Technologies PLC (registered in Ireland)
> Registered Number: 171387
> Registered Address: The IONA Building, Shelbourne Road, Dublin 4, Ireland

Dan Diephouse
Envoi Solutions |

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message