Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(432)

Issue 234323003: Make WebSocket.fromSocket public. (Closed)

Created:
6 years, 8 months ago by nweiz
Modified:
6 years, 7 months ago
CC:
reviews_dartlang.org
Visibility:
Public.

Description

Make WebSocket.fromUpgradedSocket public. This allows dart:io's WebSocket protocol code to be used in contexts where dart:io HttpRequest and HttpResponse objects aren't available. BUG=18172 R=ajohnsen@google.com Committed: https://code.google.com/p/dart/source/detail?r=35540

Patch Set 1 #

Total comments: 8

Patch Set 2 : code review #

Patch Set 3 : fix test #

Total comments: 5

Patch Set 4 : code review #

Total comments: 7
Unified diffs Side-by-side diffs Delta from patch set Stats (+59 lines, -0 lines) Patch
M sdk/lib/io/websocket.dart View 1 2 3 1 chunk +19 lines, -0 lines 3 comments Download
M tests/standalone/io/web_socket_test.dart View 1 2 3 chunks +40 lines, -0 lines 4 comments Download

Messages

Total messages: 14 (0 generated)
nweiz
6 years, 8 months ago (2014-04-10 23:14:56 UTC) #1
Anders Johnsen
I'm not sure this is something we want to expose. A request should only be ...
6 years, 8 months ago (2014-04-11 07:24:02 UTC) #2
nweiz
On 2014/04/11 07:24:02, Anders Johnsen wrote: > I'm not sure this is something we want ...
6 years, 8 months ago (2014-04-11 18:40:52 UTC) #3
Anders Johnsen
After long discussions, we've come to the same conclusions as you have, that this indeed ...
6 years, 7 months ago (2014-04-29 10:43:43 UTC) #4
nweiz
https://codereview.chromium.org/234323003/diff/1/sdk/lib/io/websocket.dart File sdk/lib/io/websocket.dart (right): https://codereview.chromium.org/234323003/diff/1/sdk/lib/io/websocket.dart#newcode137 sdk/lib/io/websocket.dart:137: * Creates a WebSocket from an existing socket. On ...
6 years, 7 months ago (2014-04-29 19:56:38 UTC) #5
Anders Johnsen
LGTM, with comments. (consider changing CL topic to match rename) https://codereview.chromium.org/234323003/diff/40001/sdk/lib/io/websocket.dart File sdk/lib/io/websocket.dart (right): https://codereview.chromium.org/234323003/diff/40001/sdk/lib/io/websocket.dart#newcode148 ...
6 years, 7 months ago (2014-04-29 20:05:10 UTC) #6
nweiz
Committed patchset #4 manually as r35540 (presubmit successful).
6 years, 7 months ago (2014-04-29 20:14:23 UTC) #7
kustermann
DBC https://codereview.chromium.org/234323003/diff/60001/tests/standalone/io/web_socket_test.dart File tests/standalone/io/web_socket_test.dart (right): https://codereview.chromium.org/234323003/diff/60001/tests/standalone/io/web_socket_test.dart#newcode404 tests/standalone/io/web_socket_test.dart:404: return request.response.detachSocket() The 'return' here has no effect ...
6 years, 7 months ago (2014-04-29 20:36:49 UTC) #8
nweiz
https://codereview.chromium.org/234323003/diff/40001/sdk/lib/io/websocket.dart File sdk/lib/io/websocket.dart (right): https://codereview.chromium.org/234323003/diff/40001/sdk/lib/io/websocket.dart#newcode148 sdk/lib/io/websocket.dart:148: * the messages it sends. If it's `false`, it ...
6 years, 7 months ago (2014-04-30 22:33:27 UTC) #9
Anders Johnsen
https://codereview.chromium.org/234323003/diff/40001/sdk/lib/io/websocket.dart File sdk/lib/io/websocket.dart (right): https://codereview.chromium.org/234323003/diff/40001/sdk/lib/io/websocket.dart#newcode152 sdk/lib/io/websocket.dart:152: bool serverSide: true}) => On 2014/04/30 22:33:27, nweiz wrote: ...
6 years, 7 months ago (2014-05-01 04:58:12 UTC) #10
Søren Gjesse
lgtm
6 years, 7 months ago (2014-05-01 07:26:52 UTC) #11
kasperl
https://codereview.chromium.org/234323003/diff/60001/sdk/lib/io/websocket.dart File sdk/lib/io/websocket.dart (right): https://codereview.chromium.org/234323003/diff/60001/sdk/lib/io/websocket.dart#newcode136 sdk/lib/io/websocket.dart:136: /** How bad would it be to add a ...
6 years, 7 months ago (2014-05-05 09:31:51 UTC) #12
Anders Johnsen
https://codereview.chromium.org/234323003/diff/60001/sdk/lib/io/websocket.dart File sdk/lib/io/websocket.dart (right): https://codereview.chromium.org/234323003/diff/60001/sdk/lib/io/websocket.dart#newcode136 sdk/lib/io/websocket.dart:136: /** On 2014/05/05 09:31:51, kasperl wrote: > How bad ...
6 years, 7 months ago (2014-05-05 09:33:48 UTC) #13
nweiz
6 years, 7 months ago (2014-05-05 19:21:02 UTC) #14
Message was sent while issue was closed.
https://codereview.chromium.org/234323003/diff/60001/sdk/lib/io/websocket.dart
File sdk/lib/io/websocket.dart (right):

https://codereview.chromium.org/234323003/diff/60001/sdk/lib/io/websocket.dar...
sdk/lib/io/websocket.dart:136: /**
On 2014/05/05 09:33:49, Anders Johnsen wrote:
> On 2014/05/05 09:31:51, kasperl wrote:
> > How bad would it be to add a (deprecated) default constructor for this so
that
> > people can subclass this for the time being?
> 
> Would it be okay if the WebSocket constructor throw a UnimplementedError?

Wouldn't that also break users using "extend WebSocket"?

Powered by Google App Engine
This is Rietveld 408576698