You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ojb-user@db.apache.org by Edson Carlos Ericksson Richter <ed...@mgrinformatica.com.br> on 2006/02/08 17:45:57 UTC
Profiling OJB
Hi!
I'm running OJB under NetBeans 5.0 final with JDK 1.5.0_06 and NetBeans
Profiler 5.0, OJB 1.0.3.
I just run the app, and I see
RepositoryPersistor.readMetadataFromXML(org.xml.sar.InputSource, class)
is called twice, taking incredible 5561 ms for execution (a 2780ms per
call). It's number two for time startup problems in my app: the first
one is ClassHelper.getClass(String, boolean), who takes 9913 ms over
4520 invocations (so I think it's ok, about 2.1 ms per call).
My question isn't why so longer readMetadataFromXML, but why twice?
Any tips?
Richter
Re: Profiling OJB
Posted by Armin Waibel <ar...@apache.org>.
Hi,
Edson Carlos Ericksson Richter wrote:
> Hi!
>
> I'm running OJB under NetBeans 5.0 final with JDK 1.5.0_06 and NetBeans
> Profiler 5.0, OJB 1.0.3.
>
> I just run the app, and I see
> RepositoryPersistor.readMetadataFromXML(org.xml.sar.InputSource, class)
> is called twice, taking incredible 5561 ms for execution (a 2780ms per
> call). It's number two for time startup problems in my app: the first
> one is ClassHelper.getClass(String, boolean), who takes 9913 ms over
> 4520 invocations (so I think it's ok, about 2.1 ms per call).
>
> My question isn't why so longer readMetadataFromXML, but why twice?
>
It's because OJB once read the persistent object metadata
(RepositoryXmlHandler) and then the connection metadata mapping
(ConnectionDescriptorXmlHandler).
It would be possible to do this in one class (this was the case in older
OJB versions), but I separated this stuff to make things more clear
(servicing classes with nearly 1500 LOC isn't easy).
For OJB 1.x the complete metadata handling rework is on the roadmap.
If you could provide a faster metadata handling/reading or some
optimization for 1.0.x, please let me know.
regards,
Armin
> Any tips?
>
> Richter
>
>
>
> ------------------------------------------------------------------------
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
> For additional commands, e-mail: ojb-user-help@db.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org