ASF subversion and git services commented on PROTON-376:

Commit 1508620 from [~mcpierce] in branch 'proton/trunk'
[ https://svn.apache.org/r1508620 ]

PROTON-376: Fix how a ::hash is automatically added to Data in Ruby

Added a singleton method to the Qpid::Proton::MAP mapping object to take
the ::hash instance and put it into the Data instance. Properly handles
a nil value as well.
> Ruby does not properly encode a map into a Data instance.
> ---------------------------------------------------------
>                 Key: PROTON-376
>                 URL: https://issues.apache.org/jira/browse/PROTON-376
>             Project: Qpid Proton
>          Issue Type: Bug
>          Components: proton-c
>            Reporter: Darryl L. Pierce
>            Assignee: Darryl L. Pierce
> When attempting to automatically put an instance of ::Hash into a Data 
> object, the following error message is shown instead:
> /home/mcpierce/Programming/Proton/proton-c/bindings/ruby/lib/qpid_proton/mapping.rb:73:in
>  `put': undefined method `map=' for #<Qpid::Proton::Data:0x00000002aa41f8> 
> (NoMethodError)
>       from 
> /home/mcpierce/Programming/Proton/proton-c/bindings/ruby/lib/qpid_proton/message.rb:71:in
>  `pre_encode'
>       from 
> /home/mcpierce/Programming/Proton/proton-c/bindings/ruby/lib/qpid_proton/messenger.rb:200:in
>  `put'
>       from ../examples/messenger/ruby/send.rb:50:in `block in <main>'
>       from ../examples/messenger/ruby/send.rb:44:in `each'
>       from ../examples/messenger/ruby/send.rb:44:in `<main>'

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to