On 29/06/2009 11:32, Michael McMahon wrote:
Christopher Hegarty - Sun Microsystems Ireland wrote:
Hi Michael, Jessie,
I need a code review for some SCTP changes that were found during
testing.
CR 6855335:
Several changes in the SCTP implementation.
Webrev:
http://cr.openjdk.java.net/~chegar/6855335/webrev.00/webrev/
1) SctpMultiChannel.branch returns null.
branch was not implemented in the first push of sctp. It is now.
SctpChannelImpl.java: Do you need to establish any state other than
remoteAddresses?
What about localAddresses for instance?
Yeap, SctpChannel already has localAddresses.
remoteAddresses is used to cache the remote addresses of the
association. When getRemoteAddresses is used to query the channel for
the list of remote addresses is goes into the kernel to determine the
most recent list of addresses, if this call fails and the channel is
still open, remoteAddresses is returned.
One reason why the native call to determine the remote addresses can
fail while the channel is still open is if the peer has shutdown the
association. You can still receive outstanding messages already in the
recv buffer and there is most probably a shutdown notification on the
stack, so it seems intuitive (and is also specified) that
getRemoteAddresses will still return the list of remote addresses until
the channel is closed.
-Chris.
- Michael.