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

Unified Diff: samples/chat/chat_stress_client.dart

Issue 27215002: Very simple version of Isolates. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address Anders' comment. Created 7 years, 2 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
Index: samples/chat/chat_stress_client.dart
diff --git a/samples/chat/chat_stress_client.dart b/samples/chat/chat_stress_client.dart
index 4465c1399c906c28b0efe8046608ed5fbc35a807..28e402cb133ebb964a81311d252835980fd4ce4f 100644
--- a/samples/chat/chat_stress_client.dart
+++ b/samples/chat/chat_stress_client.dart
@@ -52,7 +52,7 @@ class ChatStressClient {
leaveRequest["sessionId"] = sessionId;
httpClient.post("127.0.0.1", port, "/leave")
.then((HttpClientRequest request) {
- request.addString(JSON.encode(leaveRequest));
+ request.write(JSON.encode(leaveRequest));
return request.close();
})
.then((HttpClientResponse response) {
@@ -80,7 +80,7 @@ class ChatStressClient {
messageRequest["maxMessages"] = 100;
httpClient.post("127.0.0.1", port, "/receive")
.then((HttpClientRequest request) {
- request.addString(JSON.encode(messageRequest));
+ request.write(JSON.encode(messageRequest));
return request.close();
})
.then((HttpClientResponse response) {
@@ -115,7 +115,7 @@ class ChatStressClient {
messageRequest["message"] = "message $sendMessageCount";
httpClient.post("127.0.0.1", port, "/message")
.then((HttpClientRequest request) {
- request.addString(JSON.encode(messageRequest));
+ request.write(JSON.encode(messageRequest));
return request.close();
})
.then((HttpClientResponse response) {
@@ -143,7 +143,7 @@ class ChatStressClient {
joinRequest["handle"] = "test1";
httpClient.post("127.0.0.1", port, "/join")
.then((HttpClientRequest request) {
- request.addString(JSON.encode(joinRequest));
+ request.write(JSON.encode(joinRequest));
return request.close();
})
.then((HttpClientResponse response) {

Powered by Google App Engine
This is Rietveld 408576698