james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gabor Kincses <npure2...@yahoo.com>
Subject Re: Efficiency and Profiling
Date Thu, 13 Jan 2005 04:06:33 GMT

--- Serge Knystautas <sergek@lokitech.com> wrote:

> Gabor Kincses wrote:
> > Are there any pointers to profiling results?
> 
> I'm not sure what you mean.  Pure throughput
> records, or where things 
> are slow, or what?

Was hoping that somebody has profiled James and has
identified some of the hot spots and put them into a
todo list of some sort.

> > In particular how efficient is the following code
> > snippet from MimeMessageInputStreamSource.java:
> > 
> >    while ((b = in.read()) != -1) {
> >        out.write(b);
> >    }
> 
> That's bad in terms of the number of method calls it
> is generating and 
> should be done as reading a block of bytes at a
> time.

I'll try to replace the above with a more meaningful
blocking read and see if that makes any difference.  I
guess I should also see what a profiler turns up.

Thanks,
Gabor

> > Here "out" is a BufferedOutputStream, but "in"
> appears
> > to be a SequenceInputStream on non-buffered
> > FilterInputStream derivates.
> 
> There probably isn't a lot that can be done about
> the source and target, 
> and it's hard to make a black and white judgement
> without context.
> 
> -- 
> Serge Knystautas
> Lokitech >> software . strategy . design >>
> http://www.lokitech.com
> p. 301.656.5501
> e. sergek@lokitech.com
> 


=====
Gabor Kincses
Running Mandrake Linux 10.0


		
__________________________________ 
Do you Yahoo!? 
Yahoo! Mail - 250MB free storage. Do more. Manage less. 
http://info.mail.yahoo.com/mail_250

---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org


Mime
View raw message