[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: ozone & modularity



On Tue, 06 Feb 2001, Conny Krappatsch wrote:
> On Tue, 6 Feb 2001 03:07:34 +0100
> Andreas Monitzer <a@blackbox.net> wrote:
> > On Monday, February 5, 2001, at 05:05 PM, Falko Braeutigam wrote:
> > 
> > > 200 RMI calls per mouse click are indeed to slow. This issue has been
> > discussed 
> > > several times here on the list. In my opinion the Lightweight Objects
> > (see 
> > > http://ozone-db.org/ozone-users/11-2000/msg00141.html ff.) are the
> > best 
> > > approach 
> > > to display database objects in the GUI (tree, list, etc.) 
> > 
> > I've now implemented it (took me two days of debugging %-( ), but the
> > problem is still there:
> > Reading the list takes forever, but display is now ok.
> > 
> > I integrated some simple profiling code, and the results are the
> > following:
> > 
> > 92 objects
> > Time to read object from database: 0.4-0.8 sec (= 1.25-2.5 obj per sec)
> > Time for further processing: 0.05 sec
> > Total time: 77 sec
> > 
> > Which is rather slow for a 300MHz G3. A regular database would get about
> > 1000 entries per sec, not 2...
> 
> Sounds like your'e querying your objects one by one (get member of object
> 1, get member of object 2,...) from the client side. This is of course
> slow (like Falko said, discussed multiple times), because each Ozone
> object access from client side is a RMI (each inluding the overhead added
> by Ozone for e.g. the transactional environement).
> 
> If you query a relational database (I think this is what you mean with a
> 'regular' database) you don't do it like that. Mostly you have _one_ query
> and get a set of entries matching the query. You get your result with only
> _one_ database call.
> 
> This is somewhat similar to the Lightweight Objects approach discussed in
> <http://ozone-db.org/ozone-users/11-2000/msg00141.html>. You really should
> read this mail and the discussion that followed.

I perfectly agree ;)

However, besides a better, ozone-friendly design there seems to be another
problem in your test Andreas. What do you mean by "read object from the
database"? Just one call to the database? Then 0.4-0.8s are way to slow
for a simple database roundtrip. You should get values around 3ms or 0.003s!
What ozone version do you use? Please checkout latest CVS.


Falko
-- 
______________________________________________________________________
Falko Braeutigam                              mailto:falko@smb-tec.com
SMB GmbH                                        http://www.smb-tec.com