LT-22122: Word Export performance improvement #2#398
Conversation
There was data in a DocFragment that was only needed by the fragment that was going to write to the docx file. We now moved that data to a MasterDocFragment and only have a Body in the regular DocFragment. Regular DocFragments are frequently created and discarded. Not having them open a memory stream saves a significant amount of time. Combined with the performance improvements in commit e1943fb, export times are now 30% to 50% of previous times. Change-Id: I9ec6fa92709d3562c9331ec30c4c2920a71468b4
aror92
left a comment
There was a problem hiding this comment.
Reviewed 2 of 2 files at r1, all commit messages.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @mark-sil)
Src/xWorks/LcmWordGenerator.cs line 944 at r1 (raw file):
public void Flush() { WordFragment.MemStr.Flush();
Do we want a Flush method like this for the MasterDocFragment class?
aror92
left a comment
There was a problem hiding this comment.
This is a really nice change & exciting performance improvement
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @mark-sil)
mark-sil
left a comment
There was a problem hiding this comment.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @aror92)
Src/xWorks/LcmWordGenerator.cs line 944 at r1 (raw file):
Previously, aror92 (Ariel Ror.) wrote…
Do we want a Flush method like this for the MasterDocFragment class?
If there is a need for it then we can add it at that time. This Flush method is never being called on what is now the MasterDocFragment, so I didn’t see a reason to add it.
aror92
left a comment
There was a problem hiding this comment.
Reviewable status:
complete! all files reviewed, all discussions resolved (waiting on @mark-sil)
There was data in a DocFragment that was only needed by the fragment that was going to write to the docx file. We now moved that data to a MasterDocFragment and only have a Body in the regular DocFragment. Regular DocFragments are frequently created and discarded. Not having them open a memory stream saves a significant amount of time. Combined with the performance improvements in commit e1943fb, export times are now 30% to 50% of previous times.
Change-Id: I9ec6fa92709d3562c9331ec30c4c2920a71468b4
This change is