diff --git a/examples/node/xds/greeter_client.js b/examples/node/xds/greeter_client.js
index <HASH>..<HASH> 100644
--- a/examples/node/xds/greeter_client.js
+++ b/examples/node/xds/greeter_client.js
@@ -53,7 +53,9 @@ function main() {
     user = 'world';
   }
   client.sayHello({name: user}, function(err, response) {
+    if (err) throw err;
     console.log('Greeting:', response.message);
+    client.close();
   });
 }
Node xDS example: show error on failure, close client when done