Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » Faster Loading EMF Models from XML
Faster Loading EMF Models from XML [message #425980] Mon, 15 December 2008 10:58 Go to next message
Stefan Sommer is currently offline Stefan SommerFriend
Messages: 9
Registered: July 2009
Junior Member
We are using EMF as our modeling framework in the client part with a lot
of success! Now we come into the tuning development phase, we would like
to speed up the loading of huge XML models (>5MB). We also use a DOM
implementation (Dom4j) in the server part for the same XML models, and the
loading time is significant better (twice faster). Is there a way to
improve the loading behaviour in EMF for XMLs?

I already tried the options (like OPTION_USE_PARSER_POOL from XmlResource)
without any observable advancement. I also tries the BinaryResource with
the same result.

thankz for your help

Stef
Re: Faster Loading EMF Models from XML [message #426052 is a reply to message #425980] Mon, 15 December 2008 12:48 Go to previous message
Ed Merks is currently offline Ed MerksFriend
Messages: 30882
Registered: July 2009
Senior Member
This is a multi-part message in MIME format.
--------------010107080007050400070702
Content-Type: text/plain; charset=ISO-8859-15; format=flowed
Content-Transfer-Encoding: 7bit

Stefan,

Comments below.

Stefan Sommer wrote:
> We are using EMF as our modeling framework in the client part with a
> lot of success! Now we come into the tuning development phase, we
> would like to speed up the loading of huge XML models (>5MB).
I wouldn't consider this to be huge.
> We also use a DOM implementation (Dom4j) in the server part for the
> same XML models, and the loading time is significant better (twice
> faster). Is there a way to improve the loading behaviour in EMF for XMLs?
It really depends an awful lot on the details of the model itself.
I.e., are there a lot of non-containment references. A long long time
ago I "wasted" a Christmas on major parsing improvements---the handler
was 5 times faster though of course the SAX cost is fixed---but despite
bitter complaints about performance, no one at my company seemed the
least bit interested in solutions, neither providing them nor consuming
ones I provided.

https://bugs.eclipse.org/bugs/show_bug.cgi?id=51210

>
> I already tried the options (like OPTION_USE_PARSER_POOL from
> XmlResource) without any observable advancement. I also tries the
> BinaryResource with the same result.
The pool just helps with the fixed but large cost of creating a parser.

I doubt you used binary resource impl without a noticeable improvement
in performance. If that's the case, you really need to do some
measurements to find where your actual bottleneck might be because
binary resource impl definitely loads 8 times faster (from memory),
saves 5 times faster (to member), and is 1/3 the size (so I'd expect it
to load to member and flush from memory 3 times faster on top of the
other numbers).

You've done all the things in? Most involve reducing fixed overhead
initialization costs and hence are more important for speeding the
loading of many small files rather than a small number of large files.

http://www.eclipse.org/modeling/emf/docs/performance/EMFPerf ormanceTips.html

Have you done any measurements at all to know where you might tune
performance? At my old company, the people complaining about
performance specialized a method in XMLHandler and it turned out 50% of
the loading time was spent in that method, which in the base code was
just a fast hash map lookup.

Is your model based on XML Schema? You might try the "Data Type
Converters" option to generated a specialized loader implementation...
(I wonder if it still works.)
>
> thankz for your help
>
> Stef
>
>

--------------010107080007050400070702
Content-Type: text/html; charset=ISO-8859-15
Content-Transfer-Encoding: 8bit

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-15"
http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Stefan,<br>
<br>
Comments below.<br>
<br>
Stefan Sommer wrote:
<blockquote
cite="mid:86e4dcc26c95e72d562df98efdc62b7a$1@www.eclipse.org"
type="cite">We are using EMF as our modeling framework in the client
part with a lot of success! Now we come into the tuning development
phase, we would like to speed up the loading of huge XML models
(&gt;5MB). </blockquote>
I wouldn't consider this to be huge.<br>
<blockquote
cite="mid:86e4dcc26c95e72d562df98efdc62b7a$1@www.eclipse.org"
type="cite">We also use a DOM implementation (Dom4j) in the server
part for the same XML models, and the loading time is significant
better (twice faster). Is there a way to improve the loading behaviour
in EMF for XMLs?
<br>
</blockquote>
It really depends an awful lot on the details of the model itself.
Previous Topic:Creating EMap Entries
Next Topic:using UUID for/in HREF
Goto Forum:
  


Current Time: Tue Feb 18 01:09:44 GMT 2020

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

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

Back to the top