[ 
https://issues.apache.org/jira/browse/PROTON-1299?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Robbie Gemmell resolved PROTON-1299.
------------------------------------
    Resolution: Fixed

> [proton-j] the Link#getRemoteCredit() method return value isn't suitable for 
> sending links
> ------------------------------------------------------------------------------------------
>
>                 Key: PROTON-1299
>                 URL: https://issues.apache.org/jira/browse/PROTON-1299
>             Project: Qpid Proton
>          Issue Type: Bug
>          Components: proton-j
>    Affects Versions: 0.14.0
>            Reporter: Robbie Gemmell
>            Assignee: Robbie Gemmell
>             Fix For: 0.15.0
>
>
> The Link interface has a getRemoteCredit() method for getting a local view of 
> the 'effective remote credit' for the link based on current credit and queued 
> messages. This has historically returned the value 'credit - queued' for both 
> sending and receiving links. That makes no sense for sending links since the 
> credit value for them already incorporates the effect of any sent messages 
> still buffered in the engine, so subtracting the queued count from this just 
> applies the send effect twice if there are actually queued messages, leading 
> the value to be misleading.
> The method should probably only have been defined for receiving links (or not 
> at all given the queued count is able to be inspected separately), but rather 
> than break the API by moving it to the Reciever interface, the implementation 
> should just be updated to ensure an appropriate answer is given for sending 
> links (by making it the same as calling getCredit()).



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to