qpid-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From raj...@apache.org
Subject svn commit: r885667 - /qpid/trunk/qpid/python/qpid/messaging.py
Date Tue, 01 Dec 2009 04:39:56 GMT
Author: rajith
Date: Tue Dec  1 04:39:55 2009
New Revision: 885667

URL: http://svn.apache.org/viewvc?rev=885667&view=rev
Added a simple workaround for the python client to handle the "text/plain" content type supplied
by the JMS client.
The python client expects the encoding along with the content type, while the java client
just specifies the content type.
The workaround will default to utf8 as the encoding for "text/plan" if the encoding isn't
Rafael will provide a more complete solution in the future.


Modified: qpid/trunk/qpid/python/qpid/messaging.py
URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/python/qpid/messaging.py?rev=885667&r1=885666&r2=885667&view=diff
--- qpid/trunk/qpid/python/qpid/messaging.py (original)
+++ qpid/trunk/qpid/python/qpid/messaging.py Tue Dec  1 04:39:55 2009
@@ -716,6 +716,7 @@
   dict: "amqp/map",
   list: "amqp/list",
   unicode: "text/plain; charset=utf8",
+  unicode: "text/plain",
   buffer: None,
   str: None,
   None.__class__: None
@@ -725,6 +726,7 @@
   "amqp/map": codec("map"),
   "amqp/list": codec("list"),
   "text/plain; charset=utf8": (lambda x: x.encode("utf8"), lambda x: x.decode("utf8")),
+  "text/plain": (lambda x: x.encode("utf8"), lambda x: x.decode("utf8")),
   "": (lambda x: x, lambda x: x),
   None: (lambda x: x, lambda x: x)

Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:commits-subscribe@qpid.apache.org

View raw message