You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@qpid.apache.org by ganeshmurthy <gi...@git.apache.org> on 2015/10/06 04:06:59 UTC

[GitHub] qpid-dispatch pull request: DISPATCH-178 - Added code to route pro...

GitHub user ganeshmurthy opened a pull request:

    https://github.com/apache/qpid-dispatch/pull/12

    DISPATCH-178 - Added code to route proton trace messages to the dispa…

    …tch router log file instead of console

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/ganeshmurthy/qpid-dispatch log-fix

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/qpid-dispatch/pull/12.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #12
    
----
commit 18d88c64a382c39b8f4868f955d6053e7e64f067
Author: ganeshmurthy <gm...@redhat.com>
Date:   2015-10-06T01:41:27Z

    DISPATCH-178 - Added code to route proton trace messages to the dispatch router log file instead of console

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

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


[GitHub] qpid-dispatch pull request: DISPATCH-178 - Added code to route pro...

Posted by ted-ross <gi...@git.apache.org>.
Github user ted-ross commented on a diff in the pull request:

    https://github.com/apache/qpid-dispatch/pull/12#discussion_r41256608
  
    --- Diff: src/server.c ---
    @@ -252,6 +262,8 @@ static void thread_process_listeners_LH(qd_server_t *qd_server)
             ctx->user_context = 0;
             ctx->link_context = 0;
             ctx->ufd          = 0;
    +        ctx->uid          = qd_server->next_connection_id; // Increment the connection id so the next connection can use it
    +        qd_server->next_connection_id++;
    --- End diff --
    
    You can combine these into one statement:  ctx->uid = qd_server->next_connection_id++;


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

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


[GitHub] qpid-dispatch pull request: DISPATCH-178 - Added code to route pro...

Posted by ted-ross <gi...@git.apache.org>.
Github user ted-ross commented on a diff in the pull request:

    https://github.com/apache/qpid-dispatch/pull/12#discussion_r41256741
  
    --- Diff: src/server.c ---
    @@ -282,6 +294,16 @@ static void thread_process_listeners_LH(qd_server_t *qd_server)
             pn_transport_set_max_frame(tport, config->max_frame_size);
             pn_transport_set_idle_timeout(tport, config->idle_timeout_seconds * 1000);
     
    +        //
    +        // Proton pushes out its trace to qd_log_tracer() which in turn writes a trace message to the qdrouter log
    +        // If trace level logging is enabled on the router set PN_TRACE_FRM on the proton transport
    +        //
    +        if (qd_log_enabled(qd_server->log_source, QD_LOG_TRACE)) {
    +            pn_transport_set_context(tport, ctx);
    --- End diff --
    
    We should set the context unconditionally on all transports.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

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


[GitHub] qpid-dispatch pull request: DISPATCH-178 - Added code to route pro...

Posted by ted-ross <gi...@git.apache.org>.
Github user ted-ross commented on a diff in the pull request:

    https://github.com/apache/qpid-dispatch/pull/12#discussion_r41256762
  
    --- Diff: src/server.c ---
    @@ -799,6 +822,9 @@ static void cxtr_try_open(void *context)
         // qdpn_connector is not thread safe
         //
         sys_mutex_lock(ct->server->lock);
    +    // Increment the connection id so the next connection can use it
    +    ctx->uid          = ct->server->next_connection_id;
    +    ct->server->next_connection_id++;
    --- End diff --
    
    Same comment as above.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

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


[GitHub] qpid-dispatch pull request: DISPATCH-178 - Added code to route pro...

Posted by ted-ross <gi...@git.apache.org>.
Github user ted-ross commented on a diff in the pull request:

    https://github.com/apache/qpid-dispatch/pull/12#discussion_r41256821
  
    --- Diff: src/server_private.h ---
    @@ -98,6 +98,7 @@ struct qd_connection_t {
         void             *user_context;
         void             *link_context; // Context shared by this connection's links
         qd_user_fd_t     *ufd;
    +    uint64_t         uid; // A unique identifier for the qd_connection_t. The underlying pn_connection already has one but it is long and clunky.
    --- End diff --
    
    This should be called "connection_id".


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

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


[GitHub] qpid-dispatch pull request: DISPATCH-178 - Added code to route pro...

Posted by ganeshmurthy <gi...@git.apache.org>.
Github user ganeshmurthy closed the pull request at:

    https://github.com/apache/qpid-dispatch/pull/12


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

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


[GitHub] qpid-dispatch pull request: DISPATCH-178 - Added code to route pro...

Posted by ted-ross <gi...@git.apache.org>.
Github user ted-ross commented on a diff in the pull request:

    https://github.com/apache/qpid-dispatch/pull/12#discussion_r41256898
  
    --- Diff: src/server.c ---
    @@ -64,6 +64,15 @@ static qd_thread_t *thread(qd_server_t *qd_server, int id)
     
     qd_error_t qd_entity_update_connection(qd_entity_t* entity, void *impl);
     
    +/**
    + * This function is set as the pn_transport->tracer and is invoked when proton tries to write the log message to pn_transport->tracer
    + */
    +static void qd_log_tracer(pn_transport_t *transport, const char *message)
    --- End diff --
    
    It would be more accurate to call this function "qd_transport_tracer".


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

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