W3C home > Mailing lists > Public > public-secondscreen@w3.org > April 2017

Re: [presentation-api] Behavior of a receiving user agent in reconnecting

From: Mark Foltz via GitHub <sysbot+gh@w3.org>
Date: Mon, 10 Apr 2017 22:33:53 +0000
To: public-secondscreen@w3.org
Message-ID: <issue_comment.created-293098317-1491863632-sysbot+gh@w3.org>
I see a benefit to the first option.  A long lived presentation might generate a lot of closed connections in the `PresentationConnectionList`, and removing them would allow closed `PresentationConnection` objects to be discarded.

Questions:

- Do we think developers would want to keep closed connections around in the list for bookkeeping reasons?  For example, to keep track of data for previously connected controllers/players, which could be transferred to a new connection if they rejoin the game.

- Do we need to add a `connectionremoved` event to PresentationConnectionList?  Presumably the receiving page will have already added a state change handler to 

Looking at our implementation it would not be terribly difficult to implement this change.  However I am not sure it is solving a concrete problem, until we have a case where we have thousands of closed connections.  Maybe as a defense against misbehaving controller pages.

For the second option, I am not sure how the receiving user agent would choose which PresentationConnection object to re-use.  It has no data to make a match with a previous connection. It seems simplest to construct a new one for each request.

-- 
GitHub Notification of comment by mfoltzgoogle
Please view or discuss this issue at https://github.com/w3c/presentation-api/issues/419#issuecomment-293098317 using your GitHub account
Received on Monday, 10 April 2017 22:34:00 UTC

This archive was generated by hypermail 2.3.1 : Monday, 10 April 2017 22:34:00 UTC