Skip to content

Conversation

lazertester
Copy link

I found it useful to filter the heap when troubleshooting memory issues. For instance /heap net.minecraft or /heap org.bukkit.

I found it useful to filter the heap when troubleshooting memory issues. For instance `/heap net.minecraft` or `/heap org.bukkit`.
@TuxCoding
Copy link
Owner

Great idea. Could you document the filter in the readme. Then it's ready to be merged.

}

List<BaseComponent[]> paginatedLines = new ArrayList<>();
try {
String reply = invokeDiagnosticCommand(HEAP_COMMAND, EMPTY_STRING);
for (String line : reply.split("\n")) {
paginatedLines.add(new ComponentBuilder(line).create());
if(filter == null || line.contains(filter)) {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
if(filter == null || line.contains(filter)) {
if (filter == null || line.contains(filter)) {

Missing space

@TuxCoding TuxCoding added the enhancement New feature or request label Jun 11, 2020
Base automatically changed from master to main January 20, 2021 08:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants