You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@qpid.apache.org by tr...@apache.org on 2016/03/30 14:24:16 UTC

[2/2] qpid-dispatch git commit: DISPATCH-200 - Minor cleanup from Ganesh's pull request.

DISPATCH-200 - Minor cleanup from Ganesh's pull request.


Project: http://git-wip-us.apache.org/repos/asf/qpid-dispatch/repo
Commit: http://git-wip-us.apache.org/repos/asf/qpid-dispatch/commit/122eeec3
Tree: http://git-wip-us.apache.org/repos/asf/qpid-dispatch/tree/122eeec3
Diff: http://git-wip-us.apache.org/repos/asf/qpid-dispatch/diff/122eeec3

Branch: refs/heads/master
Commit: 122eeec3494a4e33d1fdbe7bb3e7ff2d298cffb5
Parents: 56e56ce
Author: Ted Ross <tr...@redhat.com>
Authored: Wed Mar 30 08:23:23 2016 -0400
Committer: Ted Ross <tr...@redhat.com>
Committed: Wed Mar 30 08:23:23 2016 -0400

----------------------------------------------------------------------
 include/qpid/dispatch/server.h | 11 +++++++++++
 src/container.c                |  1 -
 src/server_private.h           |  8 --------
 tests/management/qdrouter.py   | 15 +++++++++++++--
 4 files changed, 24 insertions(+), 11 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/qpid-dispatch/blob/122eeec3/include/qpid/dispatch/server.h
----------------------------------------------------------------------
diff --git a/include/qpid/dispatch/server.h b/include/qpid/dispatch/server.h
index 134dc30..46f50b5 100644
--- a/include/qpid/dispatch/server.h
+++ b/include/qpid/dispatch/server.h
@@ -500,6 +500,17 @@ void *qd_connection_get_link_context(qd_connection_t *conn);
 
 
 /**
+ * Sets the user id on the connection.
+ * If the sasl mech is EXTERNAL, set the user_id on the connection as the concatenated
+ * list of fields specified in the uidFormat field of qdrouter.json
+ * If no uidFormat is specified, the user is set to the pn_transport_user
+ *
+ * @param conn Connection object
+ */
+void qd_connection_set_user(qd_connection_t *conn);
+
+
+/**
  * Activate a connection for output.
  *
  * This function is used to request that the server activate the indicated

http://git-wip-us.apache.org/repos/asf/qpid-dispatch/blob/122eeec3/src/container.c
----------------------------------------------------------------------
diff --git a/src/container.c b/src/container.c
index 0d789b0..ddd85ae 100644
--- a/src/container.c
+++ b/src/container.c
@@ -21,7 +21,6 @@
 #include <string.h>
 #include "dispatch_private.h"
 #include "connection_manager_private.h"
-#include "server_private.h"
 #include <qpid/dispatch/container.h>
 #include <qpid/dispatch/server.h>
 #include <qpid/dispatch/message.h>

http://git-wip-us.apache.org/repos/asf/qpid-dispatch/blob/122eeec3/src/server_private.h
----------------------------------------------------------------------
diff --git a/src/server_private.h b/src/server_private.h
index 930f271..7a0d1db 100644
--- a/src/server_private.h
+++ b/src/server_private.h
@@ -173,12 +173,4 @@ ALLOC_DECLARE(qd_connector_t);
 ALLOC_DECLARE(qd_connection_t);
 ALLOC_DECLARE(qd_user_fd_t);
 
-/**
- * Sets the user id on the connection.
- * If the sasl mech is EXTERNAL, set the user_id on the connection as the concatenated list of fields specified in the uidFormat field of qdrouter.json
- * If no uidFormat is specified, the user is set to the pn_transport_user
- * @param conn Connection object
- */
-void qd_connection_set_user(qd_connection_t *conn);
-
 #endif

http://git-wip-us.apache.org/repos/asf/qpid-dispatch/blob/122eeec3/tests/management/qdrouter.py
----------------------------------------------------------------------
diff --git a/tests/management/qdrouter.py b/tests/management/qdrouter.py
index 1be6510..595ea17 100644
--- a/tests/management/qdrouter.py
+++ b/tests/management/qdrouter.py
@@ -81,11 +81,22 @@ class QdrouterTest(unittest.TestCase):
         conf = Config()
         content = conf._parse(text.split("\n"))
         self.maxDiff = None
-        expect = [[u'router', {u'mode': u'standalone'}], [u'sslProfile', {u'password': u'secret', u'name': u'test-profile'}], [u'listener', {u'sslProfile': u'test-profile', u'name': u'l0', u'saslMechanisms': u'ANONYMOUS'}], [u'listener', {u'saslMechanisms': u'ANONYMOUS', u'identity': u'l1', u'port': u'1234'}], [u'listener', {u'saslMechanisms': u'ANONYMOUS', u'port': u'4567'}]]
+        expect = [
+            [u'router', {u'mode': u'standalone'}],
+            [u'sslProfile', {u'password': u'secret', u'name': u'test-profile'}],
+            [u'listener', {u'sslProfile': u'test-profile', u'name': u'l0', u'saslMechanisms': u'ANONYMOUS'}],
+            [u'listener', {u'saslMechanisms': u'ANONYMOUS', u'identity': u'l1', u'port': u'1234'}],
+            [u'listener', {u'saslMechanisms': u'ANONYMOUS', u'port': u'4567'}]
+        ]
         self.assertEqual(content, expect)
 
         content = conf._expand(content)
-        expect = [[u'router', {u'mode': u'standalone'}], [u'listener', {u'password': u'secret', u'name': u'l0', u'sslProfileName': u'test-profile', u'saslMechanisms': u'ANONYMOUS'}], [u'listener', {u'port': u'1234', u'identity': u'l1', u'saslMechanisms': u'ANONYMOUS'}], [u'listener', {u'port': u'4567', u'saslMechanisms': u'ANONYMOUS'}]]
+        expect = [
+            [u'router', {u'mode': u'standalone'}],
+            [u'listener', {u'password': u'secret', u'name': u'l0', u'sslProfileName': u'test-profile', u'saslMechanisms': u'ANONYMOUS'}],
+            [u'listener', {u'port': u'1234', u'identity': u'l1', u'saslMechanisms': u'ANONYMOUS'}],
+            [u'listener', {u'port': u'4567', u'saslMechanisms': u'ANONYMOUS'}]
+        ]
         self.assertEqual(content, expect)
 
         conf.load(text.split(u"\n"))


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