DESCRIPTION

lttng: Add support for creating a live session in Control view

Change-Id: Ifb31933f8a93437cf976cef71b53cfa5d1f4ec8f
Signed-off-by: Alivia Ritter xxx@xxx.xxx


COMMENTS

author: Kaeden Tapia
date: 2014-03-27 14:57:49.000000000

Uploaded patch set 3.

-------------------------------------
author: Kaeden Tapia
date: 2014-03-27 15:04:33.000000000

Patch Set 3:

"I haven't reviewed the code, but I did try the patches. Looks ok, as far as session create, but if you try to import a trace from a live session, it's the batch import wizard that opens instead of the window to import the trace."

This is because a live trace is a "streaming" trace and we only have the network url or data url to figure out where the traces are. So for example, if we have net://127.0.0.1 we would need to have logic that detects that this is local and in the folder /home/username/lttng-traces/hostname/tracepath. This would also be an enhancement for "normal" mode traces and could be done in a future patch.

-------------------------------------
author: Brenden Conley
date: 2014-03-27 15:35:52.000000000

Patch Set 3:

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

-------------------------------------
author: Annalise Jimenez
date: 2014-03-27 15:54:40.000000000

Patch Set 3: Code-Review-1

You may want to give a warning for now, before opening the batch import wizard, telling the user he is doing a live session and how to get to his trace (it's actually in ~/lttng-traces/<username>/ and I was looking in lttng-traces/ as usual)

-------------------------------------
author: Brenden Conley
date: 2014-03-27 16:20:01.000000000

Patch Set 3: Verified+1

Build Successful 

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

-------------------------------------
author: Kaeden Tapia
date: 2014-03-27 19:14:54.000000000

Patch Set 3:

"You may want to give a warning for now, before opening the batch import wizard, telling the user he is doing a live session and how to get to his trace (it's actually in ~/lttng-traces/<username>/ and I was looking in lttng-traces/ as usual)"

It's probably ~/lttng-traces/<username> for you because hostname == username for you. for me it's emalape-laptopmodel.

We don't really know where the traces will be. One can start relayd and make it output to a different folder, for example:
lttng-relayd -o /home/emalape/live-output

Then when the live session is created, it will write the trace to:
/home/emalape/live-output/emalape-laptopmodel/mysession

The control view currently doesn't know about anything about the relayd process, it could be a previously spawned relayd or an automatically started relayd at session creation time. In any case, we don't know which parameters were used to spawn it so the traces could be anywhere.

We could guess the path and open the non-batch import but then the user can't change directory if it's wrong. We could open the batch import and used the guessed path as the default directory when the user adds directories but it's not a very big improvement is it? About the warning, I'm not sure what to put and how. Do you mean a dialog message before opening the batch import? I'm afraid the message can't be very helpful since it has to be stay a bit vague, like "You are importing a trace generated by a streamed session. By default the traces will be outputed to ~/lttng-traces/hostname/sessionname but the location can vary".

Let me know what you think.

-------------------------------------
author: Annalise Jimenez
date: 2014-03-28 15:50:23.000000000

Patch Set 3:

I understand that the control cannot know where the trace is, but neither do some of the users ;-) And as a user, I was a bit surprised to see the batch import wizard when I clicked import. Because I did a live trace without knowing what I was doing :D

If you just add a warning before opening the batch import wizard, just to remind the user he's been doing a live trace session and the trace might be anywhere and add a link to the live tracing documentation, that would be a big help (with a checkbox saying "don't remind me anymore" for instance).

My two cents and last comment on the subject. Do it or don't.

-------------------------------------
author: Ricky Reeves
date: 2014-03-28 19:20:50.000000000

Patch Set 3:

This behaviour is not only for live traces and also it is not a new behaviour. The Batch Import Wizard is also opened for network traces for the same reason that Marc-Andre pointed out. This is documented in the LTTng User Guide, chapter "Importing Network Traces to a Tracing Project".

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