DESCRIPTION

ctf: Aggregate lost events in the Events table (bug 408373)

Generate lost events when the name of the CTF event is lost event

Change-Id: I0a7905cfa9145a9f60438c3dee92106201b90042
Signed-off-by: Kelsie Blackwell xxx@xxx.xxx
Signed-off-by: Braxton Mccarthy xxx@xxx.xxx
Signed-off-by: Liana Berg xxx@xxx.xxx


COMMENTS

author: Liana Berg
date: 2013-08-07 19:27:24.000000000

Uploaded patch set 2.

-------------------------------------
author: Brenden Conley
date: 2013-08-07 19:27:31.000000000

Patch Set 2:

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

-------------------------------------
author: Brenden Conley
date: 2013-08-07 19:47:45.000000000

Patch Set 2: Verified+1

Build Successful 

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

-------------------------------------
author: Ivy Mitchell
date: 2013-08-09 19:09:28.000000000

Patch Set 2: Code-Review+1

Looks good

-------------------------------------
author: Braxton Mccarthy
date: 2013-08-09 19:44:03.000000000

Patch Set 2: Code-Review-1

(8 comments)

Comment'ed.

Seeing all the stuff it affects, I'm not sure if we wouldn't be better with a CtfTmfLostEvent instead... at least we could still use CtfTmfEvent everywhere.

Line:105, lttng/org.eclipse.linuxtools.tmf.core.tests/src/org/eclipse/linuxtools/tmf/core/tests/ctfadaptor/CtfTmfTraceTest.java -> Just replace the declaration with ITmfEvent instead.

Applies to other changes in this file too

Line:69, lttng/org.eclipse.linuxtools.tmf.core/src/org/eclipse/linuxtools/tmf/core/event/TmfLostEvent.java -> are type and content useful here?

I'd argue that source and reference are useless too (I think they're useless in TmfEvent too, but that's another story...)

Also timestamp is redundant with the timerange parameter. It could call super(..., timerange.getStart(),...) to populate the timestamp field.

Line:68, lttng/org.eclipse.linuxtools.tmf.core.tests/src/org/eclipse/linuxtools/tmf/core/tests/ctfadaptor/CtfTmfEventTest.java -> getCurrentEvent() can be a lost event now. This should be either checked for, or more simply, fixture could be declared as a ITmfEvent

Line:177, lttng/org.eclipse.linuxtools.tmf.core.tests/src/org/eclipse/linuxtools/tmf/core/tests/ctfadaptor/CtfIteratorTest.java -> change the declaration instead

Line:107, lttng/org.eclipse.linuxtools.ctf.core/src/org/eclipse/linuxtools/internal/ctf/core/event/EventDeclaration.java -> Instead of returning a new EventDeclaration object everytime, couldn't you use only one static instance of the object (look up the singleton pattern)?

Line:79, lttng/org.eclipse.linuxtools.tmf.core/src/org/eclipse/linuxtools/tmf/core/ctfadaptor/CtfTmfEventFactory.java -> Check that these fields exist and are of the right type (aka, do an instanceof check) before doing those cats.

Line:143, lttng/org.eclipse.linuxtools.tmf.core/src/org/eclipse/linuxtools/tmf/core/ctfadaptor/CtfIterator.java -> We can save on the cyclomatic complexity here, by keeping it all in the instanceof check:

  if (event instanceof CtfTmfEvent) {
    CtfTmfEvent curEvent = (CtfTmfEvent) event;
    curTimestamp = currentEvent.getTimestamp()..... etc.

Line:147, lttng/org.eclipse.linuxtools.tmf.core/src/org/eclipse/linuxtools/tmf/core/ctfadaptor/CtfIterator.java -> if (event

-------------------------------------
author: Braxton Mccarthy
date: 2013-08-15 06:12:49.000000000

Abandoned

We're going back to master after all... new version at https://git.eclipse.org/r/#/c/15491/

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