You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@poi.apache.org by bu...@apache.org on 2017/01/05 09:43:33 UTC

[Bug 60417] autoSizeColumn(int i) swallows interrupted exception and resets interrupted flag

https://bz.apache.org/bugzilla/show_bug.cgi?id=60417

Javen O'Neal <on...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Depends on|                            |58896

--- Comment #1 from Javen O'Neal <on...@apache.org> ---
Auto-sizing columns is one of the slowest functions in POI relative to what
users expect (auto-sizing is nearly instantaneous in Excel even for large
workbooks). Bug 58896 and past discussion on the dev@ mailing list discuss ways
to improve the speed of calculating the best-fit-width for a column.

Merged cells and rich text severely slow down the auto-size calculations
(though our implementation of auto-sizing may not be much faster for plain
text).

If the problem resides in java.awt.font.TextLayout, maybe one way we could
side-step this problem is by rewriting auto-sizing without TextLayout.

POI does very little with threads or interruptions, so you're probably right
that the interruption isn't originating from POI code. The only thing in POI
that gets close to this is creating ThreadLocal variables in LocaleUtil and a
few other locations. A quick grep didn't reveal an usages of Thread or
interrupt outside of our test suite for unencrypted HSSF workbooks.


Referenced Bugs:

https://bz.apache.org/bugzilla/show_bug.cgi?id=58896
[Bug 58896] autoSizeColumn() is extremely slow if worksheet contains merged
cells
-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org