| Index: runtime/bin/vmservice/running_isolate.dart
|
| diff --git a/runtime/bin/vmservice/running_isolate.dart b/runtime/bin/vmservice/running_isolate.dart
|
| index cf726c8524caa756cfc7c4fcb4be892e0805eb6d..3dd4839675cd57b80bef44181849e9cc27ed47c7 100644
|
| --- a/runtime/bin/vmservice/running_isolate.dart
|
| +++ b/runtime/bin/vmservice/running_isolate.dart
|
| @@ -4,34 +4,15 @@
|
|
|
| part of vmservice;
|
|
|
| -class RunningIsolate implements ServiceRequestRouter {
|
| +class RunningIsolate implements MessageRouter {
|
| final int portId;
|
| final SendPort sendPort;
|
| final String name;
|
|
|
| RunningIsolate(this.portId, this.sendPort, this.name);
|
|
|
| - Future sendMessage(List request) {
|
| - final completer = new Completer.sync();
|
| - final receivePort = new RawReceivePort();
|
| - sendServiceMessage(sendPort, receivePort, request);
|
| - receivePort.handler = (value) {
|
| - receivePort.close();
|
| - if (value is Exception) {
|
| - completer.completeError(value);
|
| - } else {
|
| - completer.complete(value);
|
| - }
|
| - };
|
| - return completer.future;
|
| - }
|
| -
|
| - Future route(ServiceRequest request) {
|
| + Future<String> route(Message message) {
|
| // Send message to isolate.
|
| - var message = request.toServiceCallMessage();
|
| - return sendMessage(message).then((response) {
|
| - request.setResponse(response);
|
| - return new Future.value(request);
|
| - });
|
| + return message.send(sendPort);
|
| }
|
| }
|
|
|