Re: Internal storage of nodes
Martin Matula <[email protected]> Tue, 12 Oct 2004 22:55:59 +0200
| Newsgroups | gmane.comp.java.netbeans.modules.mdr.devel |
|---|---|
| Message-ID | <[email protected]> |
Brian, if you are using repository in a usual way (with memory/b-tree storage), DeferredObjects should never be used, externalObjects should always be null, so getExternal should take no time. All the objects in the storage are subclasses of StorableBaseObject. MdrStorage.getObject() reads object from the storage based on its MOFID. refAllOfType call delegates to StorableClass.allObjects(true), which creates a lazy collection over a storage index (we store a separate index in the storage that maps a class to all of its instances). Hopefuly this helps. I am still not sure if I understand what exactly you need. Martin Brian Topping wrote: >Hi Martin, > >I'd like to use this in a tool that I have already built that uses the >MDRepository interface. The storage would would be transient memory storage >only. > >In the end, my primary goal is not really a focus on the storage, but an >effort to get to the source of where nodes come from in an extant model, such >as when a collection is returned from a refAllOfType call. It seems like >these collections always go through getExternal, but I realize I might be >looking in the very wrong place for things ;-) > >Thanks! > >Brian > > > >>-----Original Message----- >>From: Martin Matula [mailto:[email protected]] >>Sent: Tuesday, October 12, 2004 3:55 PM >>To: [email protected] >>Subject: Re: [mdr-dev] Internal storage of nodes >> >> >>Hi Brian, >>in what context do you want to measure this? Are you using MDR as a >>standalone tool or do you refer to its usage in JavaCore module? >>Martin >> >>Brian Topping wrote: >> >> >> >>>Hi list, >>> >>>I'm experimenting with some code in NBR and was wondering if >>> >>> >>I could confirm >> >> >>>some of my findings or get some alternate suggestions. >>> >>>I'm trying to find bottleneck points in the code for objects >>> >>> >>in a repository. >> >> >>>I'd like to add some experimental code to audit them as they >>> >>> >>go in or out of >> >> >>>storage. It seems like persistent storage of objects is all >>> >>> >>done by mofID >> >> >>>via DeferredObjects, is that so? Then it seems that >>>registerExternal/removeExternal/getExternal in MdrStorage >>> >>> >>are going to be >> >> >>>bottlenecks, that I should be able to audit everything that >>> >>> >>is created or >> >> >>>read from there. >>> >>>If this isn't the case, is there some minimal set of points >>> >>> >>that I can >> >> >>>intercept where objects in the repository are sent after >>> >>> >>they are created? >> >> >>>Thanks! >>> >>>Brian >>> >>> >>> >>> >> >> > > >