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

Unified Diff: runtime/bin/socket_patch.dart

Issue 293363007: Add 'Sockets' to observatory. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Deploy Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/bin/service_object_patch.dart ('k') | runtime/bin/vmservice/client/deployed/web/index.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/bin/socket_patch.dart
diff --git a/runtime/bin/socket_patch.dart b/runtime/bin/socket_patch.dart
index ebe557fe076737dc2db7538acddfc01895805cae..a50d51f6641cf652aee7cb1054434cf25ce20214 100644
--- a/runtime/bin/socket_patch.dart
+++ b/runtime/bin/socket_patch.dart
@@ -1061,21 +1061,24 @@ class _NativeSocket extends _NativeSocketNativeWrapper with _ServiceObject {
if (result is OSError) throw result;
}
- String get _serviceTypePath => 'io/socket';
+ String get _serviceTypePath => 'io/sockets';
String get _serviceTypeName => 'Socket';
Map _toJSON(bool ref) {
+ var name = '${address.host}:$port';
+ if (isTcp && !isListening) name += " <-> ${remoteAddress.host}:$remotePort";
var r = {
'id': _servicePath,
'type': _serviceType(ref),
- 'name': '${address.host}:$port',
- 'user_name': '${address.host}:$port',
+ 'name': name,
+ 'user_name': name,
};
if (ref) {
return r;
}
r['port'] = port;
r['address'] = address.host;
+ r['fd'] = nativeGetSocketId();
return r;
}
« no previous file with comments | « runtime/bin/service_object_patch.dart ('k') | runtime/bin/vmservice/client/deployed/web/index.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698