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

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

ChugR commented on pull request #676: DISPATCH-1518: Added ability to turn on 
protocol frame trace logging …
URL: https://github.com/apache/qpid-dispatch/pull/676#discussion_r377764623
 
 

 ##########
 File path: src/router_node.c
 ##########
 @@ -1432,6 +1432,30 @@ static void CORE_link_second_attach(void *context, 
qdr_link_t *link, qdr_terminu
         qdr_link_stalled_outbound(link);
 }
 
+
+static void CORE_conn_trace(void *context, qdr_connection_t *qdr_conn, bool 
trace)
+{
+    qd_connection_t      *qconn  = (qd_connection_t*) 
qdr_connection_get_context(qdr_conn);
+
+    if (!qconn)
+        return;
+
+    pn_transport_t *tport  = pn_connection_transport(qconn->pn_conn);
+
+    if (!tport)
+        return;
+
+    if (trace) {
+        pn_transport_trace(tport, PN_TRACE_FRM);
+        pn_transport_set_tracer(tport, connection_transport_tracer);
+
+    }
+    else {
+        pn_transport_set_tracer(tport, 0);
 
 Review comment:
   When pn_tracer_t tracer is zero the an assert triggers in the proton code.
 
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Add ability to turn on router trace logging for a specific connection 
> ----------------------------------------------------------------------
>
>                 Key: DISPATCH-1518
>                 URL: https://issues.apache.org/jira/browse/DISPATCH-1518
>             Project: Qpid Dispatch
>          Issue Type: Improvement
>          Components: Container
>    Affects Versions: 1.9.0
>            Reporter: Ganesh Murthy
>            Assignee: Ganesh Murthy
>            Priority: Major
>             Fix For: 1.11.0
>
>
> It would be nice to be able to turn on tracing per connection, e.g. something 
> like `qdmanage update --type=connection id=897644 tracing=true`
> That way you could benefit from protocol level tracing on connections of 
> interest as and when needed. Perhaps also there could be some way of 
> specifying a policy for connection tracing, e.g. all connections whose 
> container id is 'foo' or who are connecting from 192.666.555.444 or similar.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org

Reply via email to