Formats '{k1:v1, k2:v2}' => 'time=... pid=... k1=v1 k2=v2'

        Output is lexically sorted, *except* the time and pid always
        come first, to assist with human scanning of the data.

def _fmt_structured(d):
        """Formats '{k1:v1, k2:v2}' => 'time=... pid=... k1=v1 k2=v2'

        Output is lexically sorted, *except* the time and pid always
        come first, to assist with human scanning of the data.
        """
        timeEntry = datetime.datetime.utcnow().strftime(
            "time=%Y-%m-%dT%H:%M:%S.%f-00")
        pidEntry = "pid=" + str(os.getpid())

        rest = sorted('='.join([str(k), str(v)])
                      for (k, v) in list(d.items()))

        return ' '.join([timeEntry, pidEntry] + rest)