[ python-Bugs-1010222 ] Validate order of messages

noreply at pgfoundry.org noreply at pgfoundry.org
Sat Feb 2 16:44:01 UTC 2008


Bugs item #1010222, was opened at 2008-01-05 22:39
You can respond by visiting: 
http://pgfoundry.org/tracker/?func=detail&atid=442&aid=1010222&group_id=1000094

Category: pq/pqueue
Group: None
Status: Open
Resolution: Accepted
Priority: 3
Submitted By: James Pye (jwp)
Assigned to: James Pye (jwp)
Summary: Validate order of messages

Initial Comment:
Currently, the client3.Transaction class will not *always* check to make sure messages come in order. Rather, in many situations it merely compares the incoming message to a set of messages. If it's contained in the set it sees it as "Ok", which is wrong. Usually, this does not cause problems, but it does keep the driver from identifying bad backends.

----------------------------------------------------------------------

Comment By: James Pye (jwp)
Date: 2008-02-02 09:43

Message:
This is being fixed by changing the structure of the "hook" attribute.

hook is now a mapping of client requests to a sequence of response steps. Each step is a dictionary of receivable messages associated with the message parser and the next step pointer. If the next step is None, the response is complete.

The position of the transaction will have two new items in the tuple: last step and current step.

Last step points to the starting position of the last set of messages processed. Current step points at the position to be used for the next sequence of messages.

----------------------------------------------------------------------

You can respond by visiting: 
http://pgfoundry.org/tracker/?func=detail&atid=442&aid=1010222&group_id=1000094


More information about the Python-general mailing list