This is an automated email from the ASF dual-hosted git repository.

jross pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/qpid-proton.git


The following commit(s) were added to refs/heads/master by this push:
     new 85347f3  PROTON-2155: Switch helloworld.py back to connect with args
85347f3 is described below

commit 85347f3dc8a7c598e7203aeac61ffe72325a0809
Author: Justin Ross <[email protected]>
AuthorDate: Thu Dec 5 18:12:01 2019 -0500

    PROTON-2155: Switch helloworld.py back to connect with args
---
 python/examples/helloworld.py | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/python/examples/helloworld.py b/python/examples/helloworld.py
index 5b88462..7a91aa4 100755
--- a/python/examples/helloworld.py
+++ b/python/examples/helloworld.py
@@ -24,12 +24,13 @@ from proton.handlers import MessagingHandler
 from proton.reactor import Container
 
 class HelloWorld(MessagingHandler):
-    def __init__(self, address):
+    def __init__(self, server, address):
         super(HelloWorld, self).__init__()
+        self.server = server
         self.address = address
 
     def on_start(self, event):
-        conn = event.container.connect()
+        conn = event.container.connect(self.server)
         event.container.create_receiver(conn, self.address)
         event.container.create_sender(conn, self.address)
 
@@ -41,4 +42,4 @@ class HelloWorld(MessagingHandler):
         print(event.message.body)
         event.connection.close()
 
-Container(HelloWorld("examples")).run()
+Container(HelloWorld("localhost:5672", "examples")).run()


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to