DESCRIPTION

Bug 448058: Replace RSE by org.eclipse.remote

Change-Id: I9ee1b7e572839d66a5bacff8468e7da4dae235b4
Signed-off-by: Kaiya Mercado xxx@xxx.xxx


COMMENTS

author: Kaiya Mercado
date: 2014-10-28 13:07:03.000000000

Uploaded patch set 3.

-------------------------------------
author: Brenden Conley
date: 2014-10-28 13:07:09.000000000

Patch Set 3:

Build Started https://hudson.eclipse.org/linuxtools/job/linuxtools-gerrit/9240/

-------------------------------------
author: Brenden Conley
date: 2014-10-28 13:45:11.000000000

Patch Set 3: Verified+1

Build Successful 

https://hudson.eclipse.org/linuxtools/job/linuxtools-gerrit/9240/ : SUCCESS

-------------------------------------
author: Ricky Reeves
date: 2014-10-29 18:41:04.000000000

Patch Set 3: Code-Review-1

(15 comments)

Line:304, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/model/impl/TargetNodeComponent.java -> could that be done as a job instead of regular thread. By doing that we would have progress feedback event if it's just a running progress bar?

Line:311, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/model/impl/TargetNodeComponent.java -> It would be good to open a dialog to notify the user. Right now it's just log in the error log and the user won't know easily about the error. (When using RSE as backend we would have probably 2 error boxes, though. Should be acceptable)

Line:30, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/remote/InputReader.java -> should use a constant

Line:72, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/remote/RemoteSystemProxy.java -> I guess this code is because the connection could be opened by using the preference dialog.

Line:143, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/ControlView.java -> space before =
I saw that in many places. I won't put a comment at all the places (right now). Please update it everywhere.

Line:152, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/ControlView.java -> This opens the dialog to enter the password for the secure storage. This happens during startup of Eclipse when the Control View was open previously and has at least one connection. I would like to avoid that because users won't want to enter a password at every startup.

Line:322, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/handlers/ImportHandler.java -> space around /

Line:323, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/handlers/ImportHandler.java -> space beforfe =
space around *

Line:91, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/remote/CommandShell.java -> this seems to works fine for the build-in SSH. However, using RSE as backend there are problems with the change. For example, process.waitFor() always returns 0 even if the command fails.

Another problem is that the stdout.getOutput() below contains other sub-strings than the acutal command output (e.g. Last Login ...)

These 2 problems (result always 0 and additional output) was the reason why in the original code we had to sandwich the command with an echo command (markup). Also, we were able to get result from the command line output (follow member fReturnValue).

With this current version of the change it's not possible to use RSE as backend.

Line:98, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/remote/CommandShell.java -> This workaround is only needed when using RSE as backend. I glad that this is not needed for Build-in SSH.

Line:77, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/handlers/NewConnectionHandler.java -> RSE used is creating a job with progress bar during connection. It would be nice to have some progress feedback for the user during connection.

Line:217, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/dialogs/NewConnectionDialog.java -> Would it be useful to show for each connections the IRemoteService in comes from? Separate Column maybe? They should be also grouped together.

Line:223, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/dialogs/NewConnectionDialog.java -> private

Line:237, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/dialogs/NewConnectionDialog.java -> private

Line:243, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/dialogs/NewConnectionDialog.java -> private

-------------------------------------
author: Kaiya Mercado
date: 2014-10-31 10:25:03.000000000

Patch Set 3:

(15 comments)

Line:304, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/model/impl/TargetNodeComponent.java -> Done

Line:311, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/model/impl/TargetNodeComponent.java -> By using a job the error is reported by the framework in a message dialog.

Line:30, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/remote/InputReader.java -> The variable buffer must hold a different object for each instance of InputReader, so it cannot be static.
Or did you mean that 1024 should be a constant?

Line:72, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/remote/RemoteSystemProxy.java -> Connections are shared between LTTng control and other Linux Tools, therefore automatically closing a connection is somewhat unfriendly, however for now I'd also be ok with doing this.
For a perfect solution we need to work on the org.eclipse.remote API to be able to count usage of a connection. With that, we could more safely automatically close connections that are not used elsewhere.

Line:143, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/ControlView.java -> Done

Line:152, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/ControlView.java -> This is actually a bug in the JSch implementation, I have created https://bugs.eclipse.org/bugs/show_bug.cgi?id=449306

Line:322, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/handlers/ImportHandler.java -> Done

Line:323, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/handlers/ImportHandler.java -> Done

Line:91, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/remote/CommandShell.java -> Ok, I have redone the trick with echo for RSE.

Line:98, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/remote/CommandShell.java -> I have limited the workaround to the RSE backend.

Line:77, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/handlers/NewConnectionHandler.java -> Done

Line:217, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/dialogs/NewConnectionDialog.java -> Done

Line:223, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/dialogs/NewConnectionDialog.java -> Done

Line:237, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/dialogs/NewConnectionDialog.java -> Done

Line:243, lttng/org.eclipse.linuxtools.lttng2.control.ui/src/org/eclipse/linuxtools/internal/lttng2/control/ui/views/dialogs/NewConnectionDialog.java -> Done

-------------------------------------
author: Gerrit Code Review
date: 2014-11-17 16:54:03.000000000

The change could not be merged due to a path conflict.

Please rebase the change locally and upload the rebased commit for review.

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