cxf-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Arik Gorelik <arikg...@gmail.com>
Subject Re: byte limit on response logging?
Date Wed, 24 Mar 2010 01:48:01 GMT
Thank you for the heads up. I am on windows, and I noticed this behavior in
2.2.5. On my linux server, I am also seeing this with 2.2.5. I will have to
try with CXF 2.2.7

Arik.

On Tue, Mar 23, 2010 at 6:13 PM, Daniel Kulp <dkulp@apache.org> wrote:

> On Tuesday 23 March 2010 9:07:11 pm Arik Gorelik wrote:
> > Hi Daniel,
> >
> > I am able to grab the response from the file, but I am noticing that the
> > temp files (cos435435345345354tmp) under temp/cxf-9745435 are not being
> > cleaned up for any kind of responses (success and failures). I am using
> CXF
> > 2.2.5, is that a known bug?
>
> There were some cases with 2.2.5 where the file got locked on Windows which
> caused this.  (deletes fine on Unix's)   I think it was fixed for 2.2.6,
> but
> 2.2.7 is now out as well and I would suggest trying that.
>
> Also, make sure YOU close any streams in the DataHandlers and such that are
> returned to the client.   If the streams aren't closed, we don't know you
> are
> done with them so they cannot really get cleaned up.
>
> Dan
>
> >
> > Arik.
> >
> > On Fri, Mar 19, 2010 at 8:11 PM, Arik Gorelik <arikgdev@gmail.com>
> wrote:
> > > Thank you Daniel. I'll try that. I think I finally figured it out after
> > > looking more at the cxf source.
> > >
> > > On Fri, Mar 19, 2010 at 8:01 PM, Daniel Kulp <dkulp@apache.org> wrote:
> > >> To keep memory use low, once a message gets above 64K, we start saving
> > >> it in a
> > >> temp file instead of in memory.   You can get the File object from the
> > >> CachedOutputStream and access it directly for logging if you want.
> > >>
> > >> Dan
> > >>
> > >> On Friday 19 March 2010 8:14:15 pm Arik Gorelik wrote:
> > >> > Hello,
> > >> >
> > >> > In my custom logging out interceptor I have the code in the onClose
> > >>
> > >> method
> > >>
> > >> > (in the LoggingCallback member class):
> > >> > **
> > >> > *public* *void* onClose(CachedOutputStream cos) {
> > >> >
> > >> > OutputStream os = cos.getOut();
> > >> >
> > >> > *if* (os *instanceof* ByteArrayOutputStream) {
> > >> > // do the logging from "os"
> > >> >
> > >> > Seems that when my data stream to log is more than 65kb
> > >> > the "os" instance is of type BufferedOutputStream, but when "os"
> > >>
> > >> contains
> > >>
> > >> > less
> > >> > than 65kb of data, it is of type "LoadingByteArrayOutputStream"
> which
> > >> > executes my
> > >> > custom code inside the if condition.
> > >> >
> > >> > I am guessing since I am on the 32-bit machine, that is why...
> > >> > Arik.
> > >> >
> > >> > On Fri, Mar 19, 2010 at 1:28 PM, Arik Gorelik <arikgdev@gmail.com>
> > >>
> > >> wrote:
> > >> > > Hello,
> > >> > >
> > >> > > I am using a custom version of the LoggerOutInterceptor (wrote
my
> > >> > > own Interceptor to log response) and I am seeing a strange
> behavior
> > >> > > where certain large response do not get logged properly. Is there
> a
> > >> > > reason
> > >>
> > >> for
> > >>
> > >> > > that?
> > >> > >
> > >> > > Arik.
> > >>
> > >>  --
> > >>
> > >> Daniel Kulp
> > >> dkulp@apache.org
> > >> http://dankulp.com/blog
>
> --
>  Daniel Kulp
> dkulp@apache.org
> http://dankulp.com/blog
>

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