[Tracker] tracker-store status messages and tracker-status



Currently, the output of tracker-status is something like this:

Store:
  â     Journal replay        - Idle

Miners:
  â     Flickr                - Not authenticated
  â     File System           - Idle
  â     Applications          - Idle


The "Store" section shows a single "Journal replay" element with status
"Idle" in the example above. The "Journal replay" element name comes
directly from tracker-status, while the "Idle" status value comes from
tracker-store via dbus along with the progress value (the tick
represents 100% here). This means that all status values received from
tracker-store via dbus will be linked to "Journal replay", but this is
not ok. For example, when requesting a backup and then a restore, the
restore operation involves several things (like the tarball extraction),
not only the journal replay.

So I'm planning to modify tracker-status and tracker-store so that not
everything falls under the "Journal replay" section. I will keep the
"Idle" message as is, as it is widely used in functional tests to check
if the store is idle, but would like to change all the other status
messages so that we get outputs like these (not given in any special
order):

  â     Idle
  1%    Restoring backup - Extracting
  1%    Restoring backup - Journal replay
  1%    Initializing - Journal replay
  1%    Initializing - Recreating indexes
  1%    Changing locale - Recreating indexes

(Note that this doesn't mean to show all these lines together in
tracker-status output, each line is just the 'same' single store status
at a different time).

The idea is to have the whole "Restoring backup - Extracting" message
reported by tracker-store. The first part of the message would be the
operation being done, while the message after the dash would be the
specific part of the operation being done.

Of course we could split these two things in different fields reported
by dbus, and align the output nicely w.r.t the Miners status but that
would mean changing the specs of the dbus status reports... If we really
want the tracker-status output aligned to the Miners status, we could
just process the received tracker-store status line looking for the dash
and insert additional white-spaces before the dash when printing it, so
that we could for example have:

Store:
  1%    Initializing          - Recreating indexes

Miners:
  â     Flickr                - Not authenticated
  â     File System           - Idle
  â     Applications          - Idle

Not sure how localization would work here anyway. Currently we're
translating the "Journal replay" message in tracker-status, but not
really the "Idle" status value in tracker-store, AFAIK.

Comments?

-- 
Aleksander




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]