<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/python-packages/qpid-python.git/cpp/bindings/qpid/python, branch QPID-6125-ProtocolRefactoring</title>
<subtitle>git.apache.org: qpid.git
</subtitle>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/qpid-python.git/'/>
<entry>
<title>QPID-5975: HA extra/missing messages when running qpid-txtest2 in a loop with failover.</title>
<updated>2014-08-28T21:47:44+00:00</updated>
<author>
<name>Alan Conway</name>
<email>aconway@apache.org</email>
</author>
<published>2014-08-28T21:47:44+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/qpid-python.git/commit/?id=b93b20dd123757b208f9e78ef778e3648c3438a0'/>
<id>b93b20dd123757b208f9e78ef778e3648c3438a0</id>
<content type='text'>
This is partly not-a-bug, there is a client error handling issue that has been
corrected.

qpid-txtest2 initializes a queue with messages at the start and drains the
queues at the end. These operations are *not transactional*. Therefore
duplicates are expected if there is a failover during initialization or
draining. When duplicates were observed, there was indeed a failover at one of
these times.

Making these operations transactional is not enough to pass, now we see the test
fail with "no messages to fetch". This is explained as follows:

If there is a failover during a transaction, TransactionAborted is raised. The
client assumes the transaction was rolled back and re-plays it. However, if the
failover occurs at a critical point *after* the client has sent commit
but *before* it has received a response, then the the client *does not know*
whether the transaction was committed or rolled-back on the new primary.

Re-playing in this case can duplicate the transaction. Each transaction moves
messages from one queue to another so as long as transactions are atomic the
total number of messages will not change. However, if transactions are
duplicated, a transactional session may try to move more messages than exist on
the queue, hence "no messages to fetch". For example if thread 1 moves N
messages from q1 to q2, and thread 2 tries to move N+M messages back, then
thread 2 will fail.

This problem has been corrected as follows: C++ and python clients now raise the
following exceptions:

- TransactionAborted: The transaction has definitely been rolled back due to a
  connection failure before commit or a broker error (e.g. a store error) during commit.
  It can safely be replayed.

- TransactionUnknown: The transaction outcome is unknown because the connection
  failed at the critical time. There's no simple automatic way to know what
  happened without examining the state of the broker queues.

Unfortunately With this fix qpid-txtest2 is no longer useful test for TX
failover because it regularly raises TransactionUnknown and there's not much we
can do with that.

A better test of TX atomicity with failover is to run a pair of
qpid-send/qpid-receive with fail-over and verify that the number of
enqueues/dequeues and message depth are a multiple of the transaction size. See
the JIRA for such a test. (Note these test also sometimes raise
TransactionUnknown but it doesn't matter since all we are checking is that
messages go on and off the queues in multiple of the TX size.)  )

Note: the original bug also reported seeing missing messages from
qpid-txtest2. I don't have a good explanation for that but since the
qpid-send/receive test shows that transactions are atomic I am going to let that
go for now.

git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1621211 13f79535-47bb-0310-9956-ffa450edef68
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This is partly not-a-bug, there is a client error handling issue that has been
corrected.

qpid-txtest2 initializes a queue with messages at the start and drains the
queues at the end. These operations are *not transactional*. Therefore
duplicates are expected if there is a failover during initialization or
draining. When duplicates were observed, there was indeed a failover at one of
these times.

Making these operations transactional is not enough to pass, now we see the test
fail with "no messages to fetch". This is explained as follows:

If there is a failover during a transaction, TransactionAborted is raised. The
client assumes the transaction was rolled back and re-plays it. However, if the
failover occurs at a critical point *after* the client has sent commit
but *before* it has received a response, then the the client *does not know*
whether the transaction was committed or rolled-back on the new primary.

Re-playing in this case can duplicate the transaction. Each transaction moves
messages from one queue to another so as long as transactions are atomic the
total number of messages will not change. However, if transactions are
duplicated, a transactional session may try to move more messages than exist on
the queue, hence "no messages to fetch". For example if thread 1 moves N
messages from q1 to q2, and thread 2 tries to move N+M messages back, then
thread 2 will fail.

This problem has been corrected as follows: C++ and python clients now raise the
following exceptions:

- TransactionAborted: The transaction has definitely been rolled back due to a
  connection failure before commit or a broker error (e.g. a store error) during commit.
  It can safely be replayed.

- TransactionUnknown: The transaction outcome is unknown because the connection
  failed at the critical time. There's no simple automatic way to know what
  happened without examining the state of the broker queues.

Unfortunately With this fix qpid-txtest2 is no longer useful test for TX
failover because it regularly raises TransactionUnknown and there's not much we
can do with that.

A better test of TX atomicity with failover is to run a pair of
qpid-send/qpid-receive with fail-over and verify that the number of
enqueues/dequeues and message depth are a multiple of the transaction size. See
the JIRA for such a test. (Note these test also sometimes raise
TransactionUnknown but it doesn't matter since all we are checking is that
messages go on and off the queues in multiple of the TX size.)  )

Note: the original bug also reported seeing missing messages from
qpid-txtest2. I don't have a good explanation for that but since the
qpid-send/receive test shows that transactions are atomic I am going to let that
go for now.

git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1621211 13f79535-47bb-0310-9956-ffa450edef68
</pre>
</div>
</content>
</entry>
<entry>
<title>NO-JIRA: Make bindings install on windows</title>
<updated>2014-06-17T22:44:15+00:00</updated>
<author>
<name>Andrew Stitcher</name>
<email>astitcher@apache.org</email>
</author>
<published>2014-06-17T22:44:15+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/qpid-python.git/commit/?id=77657fd7b7e57539255f141d2068d1e6814e5430'/>
<id>77657fd7b7e57539255f141d2068d1e6814e5430</id>
<content type='text'>
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1603302 13f79535-47bb-0310-9956-ffa450edef68
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1603302 13f79535-47bb-0310-9956-ffa450edef68
</pre>
</div>
</content>
</entry>
<entry>
<title>QPID-5829: Rearrange CMake files to centralise some flags</title>
<updated>2014-06-17T05:58:34+00:00</updated>
<author>
<name>Andrew Stitcher</name>
<email>astitcher@apache.org</email>
</author>
<published>2014-06-17T05:58:34+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/qpid-python.git/commit/?id=2697d56b78841f84ba20cc1fc98b82e3a076b799'/>
<id>2697d56b78841f84ba20cc1fc98b82e3a076b799</id>
<content type='text'>
- This means they can be used in the bindings.
- It also means that individual modules do not have to specify
  to catch undefined symbols as this is the default beahviour now.

git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1603064 13f79535-47bb-0310-9956-ffa450edef68
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
- This means they can be used in the bindings.
- It also means that individual modules do not have to specify
  to catch undefined symbols as this is the default beahviour now.

git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1603064 13f79535-47bb-0310-9956-ffa450edef68
</pre>
</div>
</content>
</entry>
<entry>
<title>QPID-5560: HA tests do not use AMQP 1.0</title>
<updated>2014-04-07T21:22:55+00:00</updated>
<author>
<name>Alan Conway</name>
<email>aconway@apache.org</email>
</author>
<published>2014-04-07T21:22:55+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/qpid-python.git/commit/?id=4e30a9a1a663bcb2a3a22b02f0c1d9eee434fc4c'/>
<id>4e30a9a1a663bcb2a3a22b02f0c1d9eee434fc4c</id>
<content type='text'>
The HA tests were using only AMQP 0-10.
Modified the tests to use AMQP 1.0 if available (still use 0-10 if 1.0 is not available)
Fixed bugs uncovered both in the tests and in the AMQP 1.0 implementation.

Summary of changes:
- brokertest.py: configurable support for of swig vs. native and amqp0-10 vs. 1.0
  - default to swig+amqp1.0 if swig is available, native+amqp0-10 otherwise

- qpidtoollibs/broker.py: enable use of swig client with BrokerAgent

- Swig python client:
  - support for passing client_properties/properties.
    - expose AddressHelper pn_data read/write as PnData helper class
  - set sender/receiver capacity on creation
  - limited disposition support - rejected messages.
  - support for additional timeout parameters
  - expose messaging::Logger, allow log configuration to be set from python.

- ha_tests.py:
  - bind, delete policies not supported by AMQP 1.0, switched to using BrokerAgent QMF.
  - pass protocol:amqp1.0 connection-option to c++ test clients (qpid-send, qpid-receive)
  - TX tests forsce use of 0-10 protocol (but still with Swig client if enabled.)

- Broker fixes:
  - Queue::Settings::isTemporary was set in the 0-10 SessionAdapter, moved to Broker::createQueue.
  - broker::amqp::Session was always setting an exclusive owner in createQueue

git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1585588 13f79535-47bb-0310-9956-ffa450edef68
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The HA tests were using only AMQP 0-10.
Modified the tests to use AMQP 1.0 if available (still use 0-10 if 1.0 is not available)
Fixed bugs uncovered both in the tests and in the AMQP 1.0 implementation.

Summary of changes:
- brokertest.py: configurable support for of swig vs. native and amqp0-10 vs. 1.0
  - default to swig+amqp1.0 if swig is available, native+amqp0-10 otherwise

- qpidtoollibs/broker.py: enable use of swig client with BrokerAgent

- Swig python client:
  - support for passing client_properties/properties.
    - expose AddressHelper pn_data read/write as PnData helper class
  - set sender/receiver capacity on creation
  - limited disposition support - rejected messages.
  - support for additional timeout parameters
  - expose messaging::Logger, allow log configuration to be set from python.

- ha_tests.py:
  - bind, delete policies not supported by AMQP 1.0, switched to using BrokerAgent QMF.
  - pass protocol:amqp1.0 connection-option to c++ test clients (qpid-send, qpid-receive)
  - TX tests forsce use of 0-10 protocol (but still with Swig client if enabled.)

- Broker fixes:
  - Queue::Settings::isTemporary was set in the 0-10 SessionAdapter, moved to Broker::createQueue.
  - broker::amqp::Session was always setting an exclusive owner in createQueue

git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1585588 13f79535-47bb-0310-9956-ffa450edef68
</pre>
</div>
</content>
</entry>
<entry>
<title>QPID-5503: expose next_receiver through swig wrapper, add test for both 1.0 and 0-10</title>
<updated>2014-01-22T15:57:36+00:00</updated>
<author>
<name>Gordon Sim</name>
<email>gsim@apache.org</email>
</author>
<published>2014-01-22T15:57:36+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/qpid-python.git/commit/?id=827eb9653f513d88533f845ee56b21e9d59c3ac1'/>
<id>827eb9653f513d88533f845ee56b21e9d59c3ac1</id>
<content type='text'>
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1560395 13f79535-47bb-0310-9956-ffa450edef68
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1560395 13f79535-47bb-0310-9956-ffa450edef68
</pre>
</div>
</content>
</entry>
<entry>
<title>QPID-5394: Fix the binding dependencies so that we no longer keep on rebuilding the python swig bindings unnecessarily</title>
<updated>2013-12-04T22:19:02+00:00</updated>
<author>
<name>Andrew Stitcher</name>
<email>astitcher@apache.org</email>
</author>
<published>2013-12-04T22:19:02+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/qpid-python.git/commit/?id=257b6ff9e026086d571ee12a10614e59f59cf3e2'/>
<id>257b6ff9e026086d571ee12a10614e59f59cf3e2</id>
<content type='text'>
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1547933 13f79535-47bb-0310-9956-ffa450edef68
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1547933 13f79535-47bb-0310-9956-ffa450edef68
</pre>
</div>
</content>
</entry>
<entry>
<title>QPID-5140: removed unnecessary and peculiar assignment</title>
<updated>2013-09-20T16:10:06+00:00</updated>
<author>
<name>Gordon Sim</name>
<email>gsim@apache.org</email>
</author>
<published>2013-09-20T16:10:06+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/qpid-python.git/commit/?id=ff60c19089b9b5f6570f92c7ab3ba72b8ee4aaaf'/>
<id>ff60c19089b9b5f6570f92c7ab3ba72b8ee4aaaf</id>
<content type='text'>
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1525047 13f79535-47bb-0310-9956-ffa450edef68
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1525047 13f79535-47bb-0310-9956-ffa450edef68
</pre>
</div>
</content>
</entry>
<entry>
<title>QPID-4924: Created the console Python example app.</title>
<updated>2013-09-18T21:15:19+00:00</updated>
<author>
<name>Darryl L. Pierce</name>
<email>mcpierce@apache.org</email>
</author>
<published>2013-09-18T21:15:19+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/qpid-python.git/commit/?id=d32d34c356bf04e82c531f54ecfcb718b95e9673'/>
<id>d32d34c356bf04e82c531f54ecfcb718b95e9673</id>
<content type='text'>
It allows the user to send messages tot he server example app and get
messages back.

git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1524573 13f79535-47bb-0310-9956-ffa450edef68
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
It allows the user to send messages tot he server example app and get
messages back.

git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1524573 13f79535-47bb-0310-9956-ffa450edef68
</pre>
</div>
</content>
</entry>
<entry>
<title>QPID-4924: Fixed the Python examples to use the new Python module</title>
<updated>2013-09-18T21:15:16+00:00</updated>
<author>
<name>Darryl L. Pierce</name>
<email>mcpierce@apache.org</email>
</author>
<published>2013-09-18T21:15:16+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/qpid-python.git/commit/?id=199bdab9674606e379654db00913cc27ff702a92'/>
<id>199bdab9674606e379654db00913cc27ff702a92</id>
<content type='text'>
Now the imports will first attempt to bring in qpid_messaging, the Swig
generated Python. If that fails it will then fall back to trying to
import qpid.messaging, the pure Python binding.

git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1524572 13f79535-47bb-0310-9956-ffa450edef68
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Now the imports will first attempt to bring in qpid_messaging, the Swig
generated Python. If that fails it will then fall back to trying to
import qpid.messaging, the pure Python binding.

git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1524572 13f79535-47bb-0310-9956-ffa450edef68
</pre>
</div>
</content>
</entry>
<entry>
<title>QPID-5140: Add get/set methods to MessageProperties</title>
<updated>2013-09-18T20:20:16+00:00</updated>
<author>
<name>Darryl L. Pierce</name>
<email>mcpierce@apache.org</email>
</author>
<published>2013-09-18T20:20:16+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/qpid-python.git/commit/?id=942a30ae5fe94268636e0313865e519e8fd87615'/>
<id>942a30ae5fe94268636e0313865e519e8fd87615</id>
<content type='text'>
Also set MessageProperties instance as the properties value on the
owning Message object.

git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1524554 13f79535-47bb-0310-9956-ffa450edef68
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Also set MessageProperties instance as the properties value on the
owning Message object.

git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1524554 13f79535-47bb-0310-9956-ffa450edef68
</pre>
</div>
</content>
</entry>
</feed>
