Daniel Dekany wrote:
> I edit a ~1MB DocBook 5 XML. Me many others have a good habbit of
> often unconsciously pressing Ctrl+S. That will block me in work for
> several seconds; very inconvenient. I wonder what takes so long. Could
> this process be optimized somewhat? From the footer messages I
> conclude it's not even the validation, and writing out 1MB of XML,
> even indented and like, couldn't possibly take so long. (Ideally,
> saving should happen in parallel with editing, but certainly that
> would requite copy-on-write capability on the in-memory document
> representation.)
> 

Using default options: indentation, references to char. entities, etc,
saving a 2,274,219 bytes long DocBook 4 document takes less than 600ms
on my Linux laptop (having a slow disk drive like most laptops).

The problem seems specific to DocBook 5, and more precisely to
indentation when the document being saved conforms to a RELAX NG Schema.
If you turn indentation off, you should be able to save your document in
no time (less than 50ms).

This is clearly a problem, but we currently don't see how to improve the
performance[*] of XXE in this case and we currently do not plan to save
documents in a background thread.

---
[*] Of determining the ``type'' of the element being indented, which is
different from validation and which is a complex problem to solve in the
case of RELAX NG.





Reply via email to