DESCRIPTION

Use threads in open experiment/trace for long init operations

Change-Id: I49c9d8fbf04a83b2b7d3c36acbc52c1daa831998


COMMENTS

author: Brenden Conley
date: 2012-11-23 16:20:21.000000000

Patch Set 1:

Build Started https://hudson.eclipse.org/sandbox/job/linuxtools/639/ 

-------------------------------------
author: Brenden Conley
date: 2012-11-23 16:37:50.000000000

Patch Set 1: Verified

Build Successful 

https://hudson.eclipse.org/sandbox/job/linuxtools/639/ : SUCCESS

-------------------------------------
author: Braxton Mccarthy
date: 2012-11-23 17:58:27.000000000

Patch Set 1: Verified

(1 inline comment)

There doesn't seem to be any regression.

Although I only managed to hit the "Init_error" case. What actions would hit the "Error" one?

Line:4, lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/internal/tmf/ui/project/handlers/messages.properties -> I would keep "Perhaps it was moved or deleted?" in the error message, since it's the main cause of this error (you import a trace, delete/move it manually on disk, then try to open it again).

-------------------------------------
author: Ricky Reeves
date: 2012-11-26 13:44:10.000000000

Patch Set 1: (1 inline comment)

No, we don't have any automated regression tests. But it's part of our manual tests.

The Error case is triggered by Eclipse specific excpetion e.g. when handling resources (CoreException). This can happen if e.g. a resource is not in the file system, however, Eclipse has still references to it.

Line:4, lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/internal/tmf/ui/project/handlers/messages.properties -> I don't agree with that. This message should specify where it failed. The actual exception should indicate the cause why it failed. If a trace implementation (e.g. CtfTrace) doesn't indicate it correctly if trace doesn't exist (moved or deleted) then this implementation has to to be fixed.

-------------------------------------
author: Luciana Barry
date: 2012-11-26 15:59:06.000000000

Patch Set 1: (1 inline comment)



Line:121, lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/internal/tmf/ui/project/handlers/OpenTraceHandler.java -> Could you do "final TmfTraceElement traceElement = fTrace.getElementUnderTraceFolder()" like you have done in OpenExperimentHandler?

-------------------------------------
author: Luciana Barry
date: 2012-11-26 16:18:03.000000000

Patch Set 1: (3 inline comments)



Line:194, lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/internal/tmf/ui/project/handlers/OpenExperimentHandler.java -> We might need to dispose the experiment here

Line:194, lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/internal/tmf/ui/project/handlers/OpenTraceHandler.java -> Can you add comment similar to the one in OpenExperimentHandler about editor disposing the trace

Line:197, lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/internal/tmf/ui/project/handlers/OpenTraceHandler.java -> We might need to dispose the trace here

-------------------------------------
author: Ricky Reeves
date: 2012-11-26 17:11:30.000000000

Patch Set 1: (4 inline comments)

New patch will fix the comments

Line:194, lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/internal/tmf/ui/project/handlers/OpenExperimentHandler.java -> Yes, we have to dispose the experiment. The same is true for other error cases above.

Line:121, lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/internal/tmf/ui/project/handlers/OpenTraceHandler.java -> Done

Line:194, lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/internal/tmf/ui/project/handlers/OpenTraceHandler.java -> Done

Line:197, lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/internal/tmf/ui/project/handlers/OpenTraceHandler.java -> Yes, we have to dispose the trace here. The same is true for other error cases above.

-------------------------------------
