qpid-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From g...@apache.org
Subject svn commit: r1512417 - in /qpid/branches/0.24/qpid: ./ cpp/src/ cpp/src/qpid/broker/ cpp/src/qpid/broker/amqp/Topic.cpp cpp/src/tests/ cpp/src/tests/qpidt
Date Fri, 09 Aug 2013 17:47:43 GMT
Author: gsim
Date: Fri Aug  9 17:47:42 2013
New Revision: 1512417

URL: http://svn.apache.org/r1512417
Log:
QPID-5060: remove exchange and durable for properties map, as they apply to topic itself rather
than queue and are tracked by explicit properties (merged from r1512245)

Modified:
    qpid/branches/0.24/qpid/   (props changed)
    qpid/branches/0.24/qpid/cpp/src/   (props changed)
    qpid/branches/0.24/qpid/cpp/src/qpid/broker/   (props changed)
    qpid/branches/0.24/qpid/cpp/src/qpid/broker/amqp/Topic.cpp
    qpid/branches/0.24/qpid/cpp/src/tests/   (props changed)
    qpid/branches/0.24/qpid/cpp/src/tests/qpidt

Propchange: qpid/branches/0.24/qpid/
------------------------------------------------------------------------------
  Merged /qpid/trunk/qpid:r1512245

Propchange: qpid/branches/0.24/qpid/cpp/src/
------------------------------------------------------------------------------
  Merged /qpid/trunk/qpid/cpp/src:r1512245

Propchange: qpid/branches/0.24/qpid/cpp/src/qpid/broker/
------------------------------------------------------------------------------
  Merged /qpid/trunk/qpid/cpp/src/qpid/broker:r1512245

Modified: qpid/branches/0.24/qpid/cpp/src/qpid/broker/amqp/Topic.cpp
URL: http://svn.apache.org/viewvc/qpid/branches/0.24/qpid/cpp/src/qpid/broker/amqp/Topic.cpp?rev=1512417&r1=1512416&r2=1512417&view=diff
==============================================================================
--- qpid/branches/0.24/qpid/cpp/src/qpid/broker/amqp/Topic.cpp (original)
+++ qpid/branches/0.24/qpid/cpp/src/qpid/broker/amqp/Topic.cpp Fri Aug  9 17:47:42 2013
@@ -47,6 +47,13 @@ bool testProperty(const std::string& k, 
     else return i->second;
 }
 
+qpid::types::Variant::Map filter(const qpid::types::Variant::Map& properties)
+{
+    qpid::types::Variant::Map filtered = properties;
+    filtered.erase(DURABLE);
+    filtered.erase(EXCHANGE);
+    return filtered;
+}
 }
 
 Topic::Topic(Broker& broker, const std::string& n, const qpid::types::Variant::Map&
properties)
@@ -60,7 +67,7 @@ Topic::Topic(Broker& broker, const std::
     qpid::management::ManagementAgent* agent = broker.getManagementAgent();
     if (agent != 0) {
         topic = _qmf::Topic::shared_ptr(new _qmf::Topic(agent, this, name, exchange->GetManagementObject()->getObjectId(),
durable));
-        topic->set_properties(policy.asMap());
+        topic->set_properties(filter(properties));
         agent->addObject(topic);
     }
 }

Propchange: qpid/branches/0.24/qpid/cpp/src/tests/
------------------------------------------------------------------------------
  Merged /qpid/trunk/qpid/cpp/src/tests:r1512245

Modified: qpid/branches/0.24/qpid/cpp/src/tests/qpidt
URL: http://svn.apache.org/viewvc/qpid/branches/0.24/qpid/cpp/src/tests/qpidt?rev=1512417&r1=1512416&r2=1512417&view=diff
==============================================================================
--- qpid/branches/0.24/qpid/cpp/src/tests/qpidt (original)
+++ qpid/branches/0.24/qpid/cpp/src/tests/qpidt Fri Aug  9 17:47:42 2013
@@ -117,7 +117,7 @@ class Manager:
                     if k == "name":
                         name = v
                     elif v:
-                        if isinstance(v, dict) and v["_object_name"]:
+                        if isinstance(v, dict) and "_object_name" in v:
                             v = v["_object_name"]
                         details += "%s=%s " %(k,v)
                 print "%-25s %s" % (name, details)



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


Mime
View raw message