Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » Handling of very large model instances
Handling of very large model instances [message #410608] Mon, 02 July 2007 13:39 Go to next message
Robert Enyedi is currently offline Robert EnyediFriend
Messages: 68
Registered: July 2009
Member
Hi,

I'm investigating EMF's ability to deal with very large model instances
which as a whole might not fit in the memory.

My usage scenario is similar to this one: Container (1) -> (*) Component
(one container holding many components). I have only one container. A
small number of components do fit in the memory, however the container
with all its components might not. A crucial thing is that the
components can have cross references among themselves.

What I'm looking for is a way to work on this model instance
transparently and have EMF manage the XMI load/save of components. I did
not manage to find conclusive documentation on this usage scenario, so
I'm just guessing:

I suspect that I could make use of the
org.eclipse.emf.ecore.resource.Resource class and save the components in
separate XMI files. The container could also be saved in a separate XMI
file by using non-containment references to its components.

If I do this model instance split and I add all the XMI files to the
same EMF resource, would the memory problem be resolved? If not, would
switching to the EMFT Teneo serialization be of any help?

Regards,
Robert
Re: Handling of very large model instances [message #410631 is a reply to message #410608] Mon, 02 July 2007 16:50 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33142
Registered: July 2009
Senior Member
Robert,

You can certainly split things into many small resources, but keep in
mind that EMF will do nothing directly to swap things out of memory once
loaded. You'd have to explicitly call unload on the resource and you
could still have a giant list with however many proxies are needed to
make the list the right size. I'm not sure Teneo will directly help
with this, but if it's something that JPOX or Hibernate handles, then
probably it does. It's working asking on the EMFT newsgroup.


Robert Enyedi wrote:
> Hi,
>
> I'm investigating EMF's ability to deal with very large model
> instances which as a whole might not fit in the memory.
>
> My usage scenario is similar to this one: Container (1) -> (*)
> Component (one container holding many components). I have only one
> container. A small number of components do fit in the memory, however
> the container with all its components might not. A crucial thing is
> that the components can have cross references among themselves.
>
> What I'm looking for is a way to work on this model instance
> transparently and have EMF manage the XMI load/save of components. I
> did not manage to find conclusive documentation on this usage
> scenario, so I'm just guessing:
>
> I suspect that I could make use of the
> org.eclipse.emf.ecore.resource.Resource class and save the components
> in separate XMI files. The container could also be saved in a separate
> XMI file by using non-containment references to its components.
>
> If I do this model instance split and I add all the XMI files to the
> same EMF resource, would the memory problem be resolved? If not, would
> switching to the EMFT Teneo serialization be of any help?
>
> Regards,
> Robert


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: Handling of very large model instances [message #410646 is a reply to message #410631] Tue, 03 July 2007 06:04 Go to previous messageGo to next message
Robert Enyedi is currently offline Robert EnyediFriend
Messages: 68
Registered: July 2009
Member
Ed,

Thanks for the prompt answer. Things are looking good. The fact that the
proxies are in place helps a lot and the memory management itself can
and should be handled by a caching library. I will ask though on the
EMFT newsgroup if they do memory management by default, since Teneo is
definitely for very large models.

Regards,
Robert

Ed Merks wrote:
> Robert,
>
> You can certainly split things into many small resources, but keep in
> mind that EMF will do nothing directly to swap things out of memory once
> loaded. You'd have to explicitly call unload on the resource and you
> could still have a giant list with however many proxies are needed to
> make the list the right size. I'm not sure Teneo will directly help
> with this, but if it's something that JPOX or Hibernate handles, then
> probably it does. It's working asking on the EMFT newsgroup.
>
>
> Robert Enyedi wrote:
>> Hi,
>>
>> I'm investigating EMF's ability to deal with very large model
>> instances which as a whole might not fit in the memory.
>>
>> My usage scenario is similar to this one: Container (1) -> (*)
>> Component (one container holding many components). I have only one
>> container. A small number of components do fit in the memory, however
>> the container with all its components might not. A crucial thing is
>> that the components can have cross references among themselves.
>>
>> What I'm looking for is a way to work on this model instance
>> transparently and have EMF manage the XMI load/save of components. I
>> did not manage to find conclusive documentation on this usage
>> scenario, so I'm just guessing:
>>
>> I suspect that I could make use of the
>> org.eclipse.emf.ecore.resource.Resource class and save the components
>> in separate XMI files. The container could also be saved in a separate
>> XMI file by using non-containment references to its components.
>>
>> If I do this model instance split and I add all the XMI files to the
>> same EMF resource, would the memory problem be resolved? If not, would
>> switching to the EMFT Teneo serialization be of any help?
>>
>> Regards,
>> Robert
Re: Handling of very large model instances [message #1855543 is a reply to message #410646] Thu, 20 October 2022 06:15 Go to previous message
Rajesh Chandrasekar is currently offline Rajesh ChandrasekarFriend
Messages: 2
Registered: October 2022
Junior Member
Hi Team,

We are also facing the same issue when we load large xml file using Resource class. Did you find any solution for the above issue? If yes, could you please share with us.

Thanks in advance.
Previous Topic:CDO commit change procedure
Next Topic:Why is the Ecore iD attribute scoped to the resource?
Goto Forum:
  


Current Time: Sat Apr 27 03:37:30 GMT 2024

Powered by FUDForum. Page generated in 0.02883 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top