From: Matthew B. <mat...@ou...> - 2006-03-06 14:22:36
|
Matthew Buckett wrote: > Jon Maber wrote: > >>Matthew Buckett wrote: > >>>I'm probably going to take a profiler to it so I can get some proper >>>numbers and ideas about where exactly the problem lies but was wondering >>>if anyone else has any ideas. >>> >>> >>> >> >>First thing would be to see if the delay is in the Java execution or the >>database query. You could just try the various queries in the pgadmin >>query tool and look at execution time and the execution plan. > > > It's all Java as I am running on a database with 30 resources at the > moment and looking at the statistics outputted by the logging in > SoftCache most of the lookups hit the cache. Ok here was the gotcha. The logging from SoftCache only tracks PrimaryKey hits/missed so although my stats were looking good it wasn't tracking the missed indexkey lookups. I'll add some logging to SoftCache so it also tracks the ratio of IndexKey lookups and logs them separately. The reason I had terrible performance was that I hadn't implemented matchesKey in Resource so it was going to the database every time. -- -- Matthew Buckett, VLE Developer -- Learning Technologies Group, Oxford University Computing Services -- Tel: +44 (0)1865 283660 http://www.oucs.ox.ac.uk/ltg/ |