DESCRIPTION

tmf: Always use background requests for the histogram

Since the current time range can be arbitrarily large (as big as
the full trace), we shouldn't use a foreground request. Those should
only be for event requests that are known to be capped in time/amount
of events.

This also has the nice side effect of always getting both histograms
to fill at the same time.

Change-Id: Ic60e0bc371fc71ee164bb99c2aeac38452858806
Signed-off-by: Braxton Mccarthy xxx@xxx.xxx


COMMENTS

author: Brenden Conley
date: 2013-04-16 12:28:40.000000000

Patch Set 1:

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

-------------------------------------
author: Brenden Conley
date: 2013-04-16 12:46:50.000000000

Patch Set 1: Verified

Build Successful 

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

-------------------------------------
author: Ricky Reeves
date: 2013-04-17 14:23:24.000000000

Patch Set 1: I would prefer that you didn't submit this

(2 inline comments)



Line:301, lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/tmf/ui/views/histogram/HistogramView.java -> This one should a foreground request since it's very small (one event). We want that it is executed right away and interrupts any background requests.

Line:619, lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/tmf/ui/views/histogram/HistogramView.java -> For reasonable small ranges it should be a foreground request to be able to interrupt an ongoing long background request (e.g full histogram, indexing). However, for very long request it might be better to have it as background request, because it would be interrupt able and current event selection that are wrapped in foreground request can execute.

I think with all the changes (partial histogram using requests, new scheduler vs old scheduler) we should discuss how to handle request overall. Maybe we need to change the scheduler again.

-------------------------------------
author: Braxton Mccarthy
date: 2013-04-17 20:33:36.000000000

Patch Set 1: (2 inline comments)



Line:301, lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/tmf/ui/views/histogram/HistogramView.java -> Good point, I just did a Replace All... This one could remain a foreground request.

Line:619, lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/tmf/ui/views/histogram/HistogramView.java -> The problem is how to define "reasonably small". The histogram has no control over the 'timeRange' it receives. Since the user can ask for any arbitrarily large time range here, this is why I switched it to a background request.

Foreground requests should be reserved for small, fixed number of events (like 1-event requests, or 100-200 to fill the events view, etc.)

I agree there could be some improvements made to the request scheduler too.

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