Ernest Allen created QPID-5932:
----------------------------------

             Summary: Python console's sendMethodRequest()  should handle 
arguments that have default values in the schema
                 Key: QPID-5932
                 URL: https://issues.apache.org/jira/browse/QPID-5932
             Project: Qpid
          Issue Type: Bug
          Components: Python Client
    Affects Versions: 0.22
            Reporter: Ernest Allen
            Priority: Minor


The python console's sendMethodRequest() should handle some cases where the 
number of arguments supplied do not match the number of arguments required by 
the schema. 

When there are too many arguments supplied, the assumption is that the client 
is aware of a new argument, but the broker isn't. This is currently the case 
when qpid-route is dealing with an older broker and calls link.bridge(). The 
console will look for a named argument that was supplied, but isn't in the 
broker's schema. If one is found, it is removed. This requires that the new 
argument be named when it is passed to console. Otherwise we would have to 
assume the last argument supplied was the extra one, and that would be risky.

When there are too few arguments supplied, the assumption is that client is out 
of date and isn't aware a new argument that the schema requires. This is 
currently the case when an old qpid-route is dealing with a new broker and 
calls link.bridge(). The console will look for arguments in the schema that 
have default values (starting at the end of the schema). If one is found, it is 
added with the default value. This requires that all new arguments be given a 
default value in the schema. 
 



--
This message was sent by Atlassian JIRA
(v6.2#6252)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org

Reply via email to