[balooctl] Monitor also for state changes
ClosedPublic

Authored by poboiko on Oct 4 2018, 1:01 PM.

Details

Summary

Right now balooctl monitor connects only to the fileindexer DBus interface, and monitors only for files indexing.
This patch makes monitor to connect also to the scheduler interface to stateChanged(int state) signal, and notify about updates.

FIXED-IN: 5.52

Test Plan
  1. Run balooctl monitor
  2. In different terminal session, run balooctl stop && balooctl start
  3. Monitor now says what exactly baloo is doing right now

Diff Detail

Repository
R293 Baloo
Branch
monitor-state (branched from master)
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 3487
Build 3505: arc lint + arc unit
poboiko created this revision.Oct 4 2018, 1:01 PM
Restricted Application added projects: Frameworks, Baloo. · View Herald TranscriptOct 4 2018, 1:01 PM
Restricted Application added a subscriber: kde-frameworks-devel. · View Herald Transcript
poboiko requested review of this revision.Oct 4 2018, 1:01 PM
bruns added a subscriber: bruns.Oct 4 2018, 3:39 PM

Looks sane in general. Can you extend the summary a bit, e.g. "Connect to the scheduler DBus interface to ...."? Thx

poboiko retitled this revision from [balooctl] Monitor also for index changes to [balooctl] Monitor also for state changes.Oct 5 2018, 7:25 AM
poboiko edited the summary of this revision. (Show Details)
ngraham accepted this revision.Oct 5 2018, 11:13 PM
ngraham added a subscriber: ngraham.

Works for me and the code looks sane. Looks like this fixes https://bugs.kde.org/show_bug.cgi?id=364858, so can you add BUG: 364858 and FIXED-IN: 5.52 to the summary section and also make the changes that @bruns requested? Thanks!

Also, please don't commit this until after Frameworks 5.51 has been tagged (which is tomorrow). This is the kind of change that we should have a month to test out ourselves before releasing it to customers.

This revision is now accepted and ready to land.Oct 5 2018, 11:13 PM

Works for me and the code looks sane. Looks like this fixes https://bugs.kde.org/show_bug.cgi?id=364858, so can you add BUG: 364858 and FIXED-IN: 5.52 to the summary section and also make the changes that @bruns requested? Thanks!

Weird, bug 364858 should be fine as it is - user asks for a way to display files Baloo is currently processing, but that's exactly what monitor does (even without this patch).

Also, please don't commit this until after Frameworks 5.51 has been tagged (which is tomorrow). This is the kind of change that we should have a month to test out ourselves before releasing it to customers.

Sure, totally agree!

poboiko edited the summary of this revision. (Show Details)Oct 6 2018, 10:16 AM
bruns added a comment.Oct 6 2018, 10:26 AM

Works for me and the code looks sane. Looks like this fixes https://bugs.kde.org/show_bug.cgi?id=364858, so can you add BUG: 364858 and FIXED-IN: 5.52 to the summary section and also make the changes that @bruns requested? Thanks!

Weird, bug 364858 should be fine as it is - user asks for a way to display files Baloo is currently processing, but that's exactly what monitor does (even without this patch).

I think 364858 is not affected by this, but is still broken.

The monitor command watches for changes of the filename, but misses to fetch currentFile on startup. When the indexer "hangs", we never get a signal.

poboiko closed this revision.Oct 8 2018, 10:12 PM