You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jcs-users@jakarta.apache.org by Gary Machol <ga...@retalix.com> on 2005/01/26 07:09:41 UTC

RE: Time to draw data from the JCS on WSAD

Thanks Aaron,

The logger is not the problem, because I am using the same log4j.properties file, and I do not change the level from Production run to test runs.
Same for the cache.ccf file, I am using the same.  There is no auxiliary caching, and the JCS is not configured to write to the disk.

However, when I look at my Windows Task Manager, running my unit tester, I see that the I/O Read Bytes and the I/O Other Bytes figures both go through the roof when I am drawing my single object from the cache.  Although, I have noticed that to "Put" 1000 objects is very fast, the "Get" of a single object is what takes the long time and causes the I/O Bytes figures to be so high.  Maybe the put is asynchronous.

The main difference between the two types of runs is that the production run being on a live server, and the Unit Test is done with no server being in the air.  I suspect that the JVM that controls the unit test is for some reason sending the cache to the disk, rather than memory, even though the JCS is not configured to do so; whereas when the server is in the air, all of the data is in memory, as it should be.

Any help would be appreciated.

Thanks in advance,
Gary Machol

-----Original Message-----
From: Aaron Smuts [mailto:asmuts@yahoo.com]
Sent: Tuesday, January 25, 2005 8:43 PM
To: turbine-jcs-user@jakarta.apache.org
Subject: Re: Time to draw data from the JCS


It depends on the configuration.  If your unit test
has the log level for JCS set to debug, then it will
be much much slower.  If your unit tests is configured
to use a disk cache and the production test is not,
then the times could be affected, but not by that
much. . . .  Under all conditions that I've seen,
except for some 1.3 vm's on linux, JCS should operate
at under or around 2 times the speed of a hashtable. 
The JCS unit tests enforce that JCS be under 2.5 times
a hashtable for sequential key puts.  On 1.4 vm's it
exceeds this requirement by far.

I suspect that it is logging that is making the
difference between your production and test times.  

Aaron  


 
> > I am using the JCS cache, and I have a question:
> > I have noticed that if I put a reasonable number
> of
> > items into the cache, say 1000, and I draw a
> single
> > item from the cache, then depending on the point
> > from where I initiate the draw, the draw takes a
> > different amount of time.
> > 
> > For example, I have a stateless session bean, that
> > gets to the cache through a cache framework that
> we
> > have built.  The time taken to draw the items is
> > always 0 milliseconds, or in other words, below
> the
> > clock's resolution.
> > However, I have a unit tester that is a simple
> java
> > class.  For the same draw from this java class,
> the
> > time taken varies from between 300 milliseconds to
> > 500 milliseconds.  
> > 
> > Do you have any idea why there is such a
> difference?
> >  Any help you could provide would be appreciated. 
> > Thanks in advance,

---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-jcs-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-jcs-user-help@jakarta.apache.org