Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 316455 - [LTTng] State system minor improvements
Summary: [LTTng] State system minor improvements
Status: CLOSED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: LinuxTools (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows Vista
: P3 minor (vote)
Target Milestone: ---   Edit
Assignee: Alvaro Sanchez-Leon CLA
QA Contact: Francois Chouinard CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 301632
  Show dependency tree
 
Reported: 2010-06-10 08:40 EDT by Alvaro Sanchez-Leon CLA
Modified: 2022-01-13 14:53 EST (History)
0 users

See Also:


Attachments
proposed patch (20.22 KB, patch)
2010-09-02 15:02 EDT, Marc Dumais CLA
no flags Details | Diff
Updated patch, following review comments (22.78 KB, patch)
2010-09-21 14:32 EDT, Marc Dumais CLA
no flags Details | Diff
Updated patch, following rebase to latest of TRUNK as of 2010-10-13 (21.64 KB, patch)
2010-10-13 08:40 EDT, Marc Dumais CLA
no flags Details | Diff
Updated patch, following rebase to latest of TRUNK as of 2010-10-14 (38.59 KB, application/octet-stream)
2010-10-14 09:57 EDT, Marc Dumais CLA
fchouinard: iplog+
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Alvaro Sanchez-Leon CLA 2010-06-10 08:40:34 EDT
This Bug is a reminder to implement the following couple of small tasks

1) SyntheticEventProvider.java, replace the current three sub-request of trace level time ranges, for one sub-request of coalesced time ranges.

2) in the StateExperimentManger.java, optimise the dispatching of events to its corresponding trace by a comparing the trace references vs String path+name, (note, comparing references may not be trivial if trace clones are implemented as part of the solution)
Comment 1 Marc Dumais CLA 2010-09-02 15:02:22 EDT
Created attachment 178090 [details]
proposed patch

This patch tries to fix both parts of this bug report:
1) It replaces the multiple (one per trace) requests in LttngSyntheticEventProvider.java by one request of coalesced time ranges.  

2) Optimises the dispatching of events to its corresponding trace in StateExperimentManager.java by using the trace reference directly in the map as key.


 
Legal Message: I, Marc Dumais, declare that I developed attached code from scratch, without referencing any 3rd party materials except material licensed under the EPL. {I am authorized by my employer to make this contribution under the EPL.}
Comment 2 Alvaro Sanchez-Leon CLA 2010-09-13 13:58:17 EDT
The functionality is good and doing as expected, 
I have the following comments for the patch.

1) Remove unused import in LttngBaseEventRequest e.g. "ctrl-shift o"
import org.eclipse.linuxtools.lttng.state.trace.IStateTraceManager;

2) LttngBaseEventRequest, 
the "traceToTraceState" Map is used in LttngBaseEventRequest but via an extended inner instance  in LttngSyntheticEventProvider, 
    so it should be moved to and built in the LttngSyntheticEventProvider loop replacing traces[] and traceModels[] arrays, this instance shall then be used by any subsequent requests and only updated once per experiment selection.

3) LtttngSyntheticEventProvider 
	a) Map<IStateTraceManager, LttngBaseEventRequest> fEventProviderRequests
	The key is still in use but not the values i.e. single coalesced request, 
	this shall be replaced by a List<IStateTraceManager>
	
	b)	LttngBaseEventRequest subRequest
	   The syntheticAckIndicator does not seem to be needed any longer
	private LttngSyntheticEvent syntheticAckIndicator = null;
Comment 3 Marc Dumais CLA 2010-09-21 14:32:19 EDT
Created attachment 179334 [details]
Updated patch, following review comments

Hi Alvaro,

Thanks for the comments.  Find attached an updated patch, taking your comments into consideration.

Thanks,

Marc
Comment 4 Marc Dumais CLA 2010-10-13 08:40:00 EDT
Created attachment 180760 [details]
Updated patch, following rebase to latest of TRUNK as of 2010-10-13
Comment 5 Marc Dumais CLA 2010-10-14 09:57:53 EDT
Created attachment 180879 [details]
Updated patch, following rebase to latest of TRUNK as of 2010-10-14

Let's try this again :)
Comment 6 Francois Chouinard CLA 2010-10-14 11:38:06 EDT
Comment on attachment 180879 [details]
Updated patch, following rebase to latest of TRUNK as of 2010-10-14

Patch committed in Helios and Indigo
Comment 7 Francois Chouinard CLA 2010-10-14 11:38:26 EDT
Done.
Comment 8 Francois Chouinard CLA 2011-07-22 14:38:59 EDT
Delivered with 0.7