Trim console output before processing it in console document#2462
Trim console output before processing it in console document#2462trancexpress wants to merge 1 commit intoeclipse-platform:masterfrom
Conversation
| applyStreamOutput(pendingCopy, sizeHint); | ||
| } | ||
| checkFinished(); | ||
| checkBufferSize(); // needs partitions synchronized |
There was a problem hiding this comment.
Proper trimming is done here. The above change just reduces the output that will be processed by the document / underlying widget.
debug/org.eclipse.ui.console/src/org/eclipse/ui/internal/console/IOConsolePartitioner.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Pull request overview
This PR aims to prevent Eclipse UI freezes when processing extremely large console output by trimming pending console output in IOConsolePartitioner.QueueProcessingJob.processPendingPartitions() before applying it to the console document, when a console limit (water marks) is configured.
Changes:
- Adds logic in
processPendingPartitions()to trim pending partitions based on the consolehighWaterMarkbefore callingapplyStreamOutput(...).
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
debug/org.eclipse.ui.console/src/org/eclipse/ui/internal/console/IOConsolePartitioner.java
Outdated
Show resolved
Hide resolved
debug/org.eclipse.ui.console/src/org/eclipse/ui/internal/console/IOConsolePartitioner.java
Show resolved
Hide resolved
|
Fails on Linux: |
|
Lets apply this one in a separate issue, its causing fails: |
|
Fail on Linux is: |
d7abd9c to
5c2fefa
Compare
|
@iloveeclipse please check this one as well, it should solve the console UI freezes if the console limit is set (together with the line trim PR which you merged). |
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 1 out of 1 changed files in this pull request and generated 1 comment.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
debug/org.eclipse.ui.console/src/org/eclipse/ui/internal/console/IOConsolePartitioner.java
Show resolved
Hide resolved
debug/org.eclipse.ui.console/src/org/eclipse/ui/internal/console/IOConsolePartitioner.java
Outdated
Show resolved
Hide resolved
When processing large amounts of console output of a process, its possible that the Eclipse UI will freeze. E.g. on Linux, very long lines (> 1 million symbols) result in such freezes. Using the console limit preference doesn't help preventing this freeze, despite limitting the contents seen in the console. This change adjusts IOConsolePartitioner.QueueProcessingJob.processPendingPartitions() to trim pending console output before setting this output in the console document, if a console limit is set in the Eclipse preferences. See: eclipse-platform#2283
When processing large amounts of console output of a process, its possible that the Eclipse UI will freeze.
E.g. on Linux, very long lines (> 1 million symbols) result in such freezes.
Using the console limit preference doesn't help preventing this freeze, despite limitting the contents seen in the console.
This change adjusts
IOConsolePartitioner.QueueProcessingJob.processPendingPartitions()to trim pending console output before setting this output in the console document, if a console limit is set in the Eclipse preferences.See: #2283