W3C home > Mailing lists > Public > public-webrtc@w3.org > March 2014

Re: Improvements suggestion for DataChannels

From: Martin Thomson <martin.thomson@gmail.com>
Date: Mon, 3 Mar 2014 03:06:34 -0800
Message-ID: <CABkgnnXZ8vyAYnSKuiamj09Bx7SnHftirde-BwF5Xqy7xnBzQQ@mail.gmail.com>
To: Adam Bergkvist <adam.bergkvist@ericsson.com>
Cc: "piranna@gmail.com" <piranna@gmail.com>, Randell Jesup <randell-ietf@jesup.org>, public-webrtc <public-webrtc@w3.org>
On 3 March 2014 03:01, Adam Bergkvist <adam.bergkvist@ericsson.com> wrote:
> I still think we should avoid having a list of DataChannels on the
> PeerConnection object since we don't have a counterpart for
> PeerConnection.removeStream() for DataChannels. This means that, to make it
> possible to ever garbage collect DataChannel objects, DataChannel.close()
> would need to have a side effect that removed the channel from its
> PeerConnection or we would have to add a new method to do that. Both are
> strange an unmotivated IMO.


I'm not sure that that is true.  If the getter is never called, then
the channel can be GCd.  If it is called, then close is going to make
it unusable, but the object reference can persist as long as the
reference is held.

The object itself doesn't really hold any state.  I don't see this as
a big issue.
Received on Monday, 3 March 2014 11:07:01 UTC

This archive was generated by hypermail 2.3.1 : Monday, 23 October 2017 15:19:38 UTC