Determining mdworker status

Originator:robnapier
Number:rdar://15177626 Date Originated:08-Oct-2013 02:08 PM
Status:Open Resolved:
Product:OS X Product Version:
Classification: Reproducible:
 
We provide a product that includes an inventory of software installed on managed Macs. In order to determine the current applications installed, we use "system_profiler SPApplicationsDataType" to request the application list from Spotlight.

We are unable to determine whether the results of system_profiler are up-to-date. In particular, we are unable to determine whether mdworker has completed its first pass. This leads to excessively short lists when mdworker is still processing, which in turn leads our automated system to attempt to install dozens of packages that are already installed.

Spotlight is able to determine this status in order to display the little dot in the magnifying glass search icon. We are trying to determine the same status. Alternatively, we would like a different way to determine the currently installed packages without undo impact on the filesystem (i.e. rescanning it as mdworker is already doing).

Steps to Reproduce:
STEPS TO REPRODUCE
mdutil -E /
system_profiler SPApplicationsDataType

Comments


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!