[ 
https://issues.apache.org/jira/browse/DISPATCH-597?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15890714#comment-15890714
 ] 

ASF GitHub Bot commented on DISPATCH-597:
-----------------------------------------

Github user ted-ross commented on a diff in the pull request:

    https://github.com/apache/qpid-dispatch/pull/143#discussion_r103749521
  
    --- Diff: include/qpid/dispatch/server.h ---
    @@ -451,6 +452,28 @@ typedef struct qd_server_config_t {
          * connection will be automatically closed.
          */
         int idle_timeout_seconds;
    +
    +    /**
    +     *  Holds comma separated list that indicates which components of the 
message should be logged.
    +     *  Defaults to 'none' (log nothing). If you want all properties and 
application properties of the message logged use 'all'.
    +     *  Specific components of the message can be logged by indicating the 
components via a comma separated list.
    +     *  The components are
    +     *  message-id
    +     *   user-id
    +     *   to
    +     *   subject
    +     *   reply-to
    +     *   correlation-id
    +     *   content-type
    +     *   content-encoding
    +     *   absolute-expiry-time
    +     *   creation-time
    +     *   group-id
    +     *   group-sequence
    +     *   reply-to-group-id
    +     *   app-properties.
    +     */
    +    char *log_message;
    --- End diff --
    
    I would recommend storing this in its bit-mask form here.  Then it only 
needs to be parsed once at configuration time.  This also allows you to isolate 
the string definitions and the conversion functions to a single .h/.c module.


> Log enhancements
> ----------------
>
>                 Key: DISPATCH-597
>                 URL: https://issues.apache.org/jira/browse/DISPATCH-597
>             Project: Qpid Dispatch
>          Issue Type: Improvement
>          Components: Container
>    Affects Versions: 0.7.0
>            Reporter: Shibi Sudhakaran
>            Assignee: Ganesh Murthy
>             Fix For: 0.8.0
>
>
> Print information at INFO level into log that could be used for diagnosing 
> router health.  
> 1. Millisecond precision timestamp
> 2. Avoid logging message body.
> 3. Capability to configure application properties to be logged (messageId, 
> correlationId, creationTime , application custom properties) etc 
> Sample Entries (log level : INFO)
> ============
> => Mon 2016-09-26 11:31:44.050750 -0700 ROUTER_HELLO (info) SENT: 
> HELLO(id=Router.A.0 area=0 inst=1474860067 seen=['Router.A.1', 'Router.A.2', 
> 'Router.A.3', 'Router.A.4’])
> => Mon 2016-09-26 14:15:58.088754 -0700 MESSAGE (info) Sending Message{ 
> message-id='<messageid>' correlation-id='<correlationid>' 
> creation-time='2016-09-26 14:15:58.084 -0700' application properties='[Key: 
> request-creation-time => Value: 1474924558078]' } on link <linkname>
> => Mon 2016-09-26 14:15:20.547178 -0700 MESSAGE (info) Received Message{ 
> message-id='<messageid>' correlation-id='<correlationid>' 
> creation-time='2016-09-26 14:15:20.542 -0700' application properties='[Key: 
> request-creation-time => Value: 1474924520539]'} on link <linkname>
> => Mon 2016-09-26 09:40:00.149567 -0700 ROUTER_LS (info) Computed costs: 
> {'Router.A.0': 1, 'Router.A.2': 1, 'Router.A.3': 1, 'Router.A.4': 1}
> => Mon 2016-09-26 14:23:07.376756 -0700 ROUTER (info) Router started in 
> Interior mode, area=0 id=Router.A.1
> => Mon 2016-09-26 14:23:07.408136 -0700 CONN_MGR (info) Configured Listener: 
> 0.0.0.0:5671 proto=any role=normal
> => Mon 2016-09-26 14:14:57.520917 -0700 SERVER (info) Accepting incoming 
> connection from <ipaddress:port> to <ipaddress:port> 
> => Mon 2016-09-26 14:23:07.376471 -0700 SERVER (info) Container Name: 
> Router.A.1
> => Mon 2016-09-26 14:23:07.439250 -0700 SERVER (info) Connecting to 
> <ipaddress:port> 
> => Mon 2016-09-26 14:23:07.447536 -0700 SERVER (info) [1]:Client SSL socket 
> created.
> => Mon 2016-09-26 14:15:12.310692 -0700 SERVER (info) [8783]:SSL socket freed
> => Mon 2016-09-26 14:23:03.059884 -0700 SERVER (info) Shut Down



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to