Qpid
  1. Qpid
  2. QPID-4084

Qpid logger should you milliseconds in when outputing formatted timestamps

    Details

    • Type: Improvement Improvement
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 0.12, 0.13, 0.14, 0.15, 0.16
    • Fix Version/s: 0.19
    • Component/s: None
    • Labels:
      None

      Description

      Here is the discussion:
      http://qpid.2158936.n2.nabble.com/Milliseconds-in-log-messages-td7578787.html

      I suppose boost::posix_time::to_iso_extended_string(ptime) function can be used, for example:

      using namespace boost::posix_time;
      
      to_iso_extended_string(microsec_clock::local_time())
      

        Activity

        Hide
        Alan Conway added a comment -

        This is already implemented for the POSIX version of the broker, e.g.:

        2012-06-26 10:50:21.800176860 [Broker] critical Unexpected error: Can't bind to port 0.0.0.0:5672: Address already in use (../../qpid/cpp/src/qpid/sys/posix/Socket.cpp:206)

        and it appears that it has also been implemented on Windows, see ~/qpid/qpid/cpp/src/qpid/sys/windows/Time.cpp: void outputHiresNow(std::ostream& o)

        Are you using an older version of the broker?

        Show
        Alan Conway added a comment - This is already implemented for the POSIX version of the broker, e.g.: 2012-06-26 10:50:21.800176860 [Broker] critical Unexpected error: Can't bind to port 0.0.0.0:5672: Address already in use (../../qpid/cpp/src/qpid/sys/posix/Socket.cpp:206) and it appears that it has also been implemented on Windows, see ~/qpid/qpid/cpp/src/qpid/sys/windows/Time.cpp: void outputHiresNow(std::ostream& o) Are you using an older version of the broker?
        Hide
        Sergey Zhemzhitsky added a comment -

        Hi Alan,

        Currently I'm using qpid c++ client 0.14 and outputHiresNow displays unformatted time.

        Show
        Sergey Zhemzhitsky added a comment - Hi Alan, Currently I'm using qpid c++ client 0.14 and outputHiresNow displays unformatted time.
        Hide
        Steve Huston added a comment -

        Fixed on trunk at r1373147.

        Show
        Steve Huston added a comment - Fixed on trunk at r1373147.

          People

          • Assignee:
            Steve Huston
            Reporter:
            Sergey Zhemzhitsky
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development