eclipse-platform / eclipse.platform.ui

Eclipse Platform
https://projects.eclipse.org/projects/eclipse.platform
Eclipse Public License 2.0
81 stars 188 forks source link

Eclipse dump #1593

Open elsazac opened 9 months ago

elsazac commented 9 months ago

Suggestion

From a fresh installation and clean workspace:

And would like to be able to

I get some information from About Eclipse->configuration tab but those are launch time information not runtime

Community

merks commented 9 months ago

I'm not sure if you are talking about a self-dump or a dump of something launched from the IDE. Problems are generally logged and visible in the Error Log view. There is optional freeze monitoring (Window -> Preferences -> General -> UI Freeze Monitoring) that logs information about when the UI thread is block.

Thread dumps can be collected externally.

https://wiki.eclipse.org/How_to_report_a_deadlock

I'm not sure a memory dump is possible or what tool would be able to read it to provide useful information.

elsazac commented 9 months ago

I'm not sure if you are talking about a self-dump or a dump of something launched from the IDE. Problems are generally logged and visible in the Error Log view. There is optional freeze monitoring (Window -> Preferences -> General -> UI Freeze Monitoring) that logs information about when the UI thread is block.

Thread dumps can be collected externally.

https://wiki.eclipse.org/How_to_report_a_deadlock

I'm not sure a memory dump is possible or what tool would be able to read it to provide useful information.

@merks I am talking about a self dump. instead of looking for issues in error log, thread dumps etc. separately it would be handy if we get everything in a single dump. Also I can ask my customers to collect all these informations using a single click if they get into problems.

for eg, Semuru java produces a java dump which provides rich set of JVM internal details. Refs: https://www.ibm.com/docs/en/semeru-runtime-ce-z/11?topic=dumps-java-dump

iloveeclipse commented 9 months ago

Application gets into issues : crash / freeze / Exception ... Have a menu option or a toolbar named dump

If Eclipse is crashed or hangs, no Eclipse menu / toolbar will work. So are you requesting an additional application that would be installed next to Eclipse?

elsazac commented 9 months ago

If Eclipse is crashed or hangs, no Eclipse menu / toolbar will work. So are you requesting an additional application that would be installed next to Eclipse?

It's not an additional application. if eclipse crashes we can enable vm shut down hook (https://docs.oracle.com/javase/8/docs/api/java/lang/Runtime.html#addShutdownHook-java.lang.Thread-) that can collect the required data. if the UI freezes or hangs similar thing can be done by a non UI thread. And these behaviours may be controlled using user preferences.

BeckerWdf commented 9 months ago

SAP's ABAP Development Tools (ADT) does have suche a feature. Let me show you how this looks like.

We have a Menu Entry Help > "Collect Support Information...". A user can trigger this once he encountered a problem in our product or when our support colleagues ask them to do so while handling a support ticket.

This looks like this:

image image image

This generated a ZIP file. This contains e.g.:

You can try out our implementation by simply taking a plain eclipse and install our ADT via the https://tools.hana.ondemand.com/latest update site. See: https://tools.eu1.hana.ondemand.com/#abap

See:

Screenshot 2024-01-31 at 08 26 29

This will also install the "SAP Support Tools":

image

You don't need an ABAP server to test the support collector.

This is already build in a way that it's independent from our product "ADT". Product specific information can be provided via implementing extension points. Via this way we for example also add a trace of the communication that happens between the ADT (eclipse client) and our ABAP server. Eclipse platform specific stuff (like adding the error log to the zip file) are implemented directly.

So it should be relatively easy for us to contribute this to the Eclipse project. And we are willing to do so.

BeckerWdf commented 9 months ago

Application gets into issues : crash / freeze / Exception ... Have a menu option or a toolbar named dump

If Eclipse is crashed or hangs, no Eclipse menu / toolbar will work. So are you requesting an additional application that would be installed next to Eclipse?

With SAP's implementation of that we can also collect information from a hanging eclipse installation - even though this is not possible by simply pressing a button.

elsazac commented 9 months ago

With SAP's implementation of that we can also collect information from a hanging eclipse installation - even though this is not possible by simply pressing a button.

Thanks @BeckerWdf for sharing the feature, this fits my use case perfectly. With or without a controlling button, as long as we are able to capture the valuable diagnostic data, my objective is met.

BeckerWdf commented 9 months ago

Thanks @BeckerWdf for sharing the feature, this fits my use case perfectly. With or without a controlling button, as long as we are able to capture the valuable diagnostic data, my objective is met.

This is done via the command line then. From our documentation:

In rare situations, in which the IDE is frozen, it may still be possible to create a support file using the command line. Proceed as follows (the path to your eclipse installation may vary):

Windows: Open a terminal or command prompt Run the following command: "c:\path\to\eclipse\eclipse.exe" -application com.sap.ide.support.StandaloneInformationCollector -data @none