<html>
  <head>
    <meta content="text/html; charset=windows-1252"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    my understanding is that if you are calling stop()/wait() your
    intention is to shut down the listener. if you intend on keeping an
    active consumer on the queue, you shouldn't be calling either stop()
    or wait(), just start.<br>
    <br>
    <div class="moz-cite-prefix">On 05/11/2015 2:07 PM, Nader Lahouti
      wrote:<br>
    </div>
    <blockquote
cite="mid:CAF5T5jvua0wrXqZiBgd6cOSApF74eg3kbPaBYb-Bm0HNhaXpbA@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div><br>
        </div>
        <div>Thanks for the pointer, I'll look into it. But one
          question, by calling stop() and then wait(), does it mean the
          application has to call start() again after the wait()? to
          process more messages?</div>
        <div><br>
        </div>
        <div>I am also using  <a moz-do-not-send="true"
            href="http://docs.openstack.org/developer/oslo.messaging/server.html">http://docs.openstack.org/developer/oslo.messaging/server.html</a>
          for the RPC server </div>
        <div>Does it mean there has to be stop() and then wait() there
          as well?</div>
        <div><br>
        </div>
        <div><br>
        </div>
        <div>Thanks,</div>
        <div>Nader.</div>
        <div><br>
        </div>
        <div><br>
        </div>
      </div>
      <div class="gmail_extra"><br>
        <div class="gmail_quote">On Thu, Nov 5, 2015 at 10:19 AM, gord
          chung <span dir="ltr"><<a moz-do-not-send="true"
              href="mailto:gord@live.ca" target="_blank">gord@live.ca</a>></span>
          wrote:<br>
          <blockquote class="gmail_quote" style="margin:0 0 0
            .8ex;border-left:1px #ccc solid;padding-left:1ex"><span
              class=""><br>
              <br>
              On 05/11/2015 1:06 PM, Nader Lahouti wrote:<br>
              <blockquote class="gmail_quote" style="margin:0 0 0
                .8ex;border-left:1px #ccc solid;padding-left:1ex">
                Hi Doug,<br>
                <br>
                I have an app that listens to notifications and used the
                info provided in<br>
                <a moz-do-not-send="true"
href="http://docs.openstack.org/developer/oslo.messaging/notification_listener.html"
                  rel="noreferrer" target="_blank">http://docs.openstack.org/developer/oslo.messaging/notification_listener.html</a><br>
                <br>
                <br>
                Basically I create<br>
                1. NotificationEndpoints(object):<br>
                <a moz-do-not-send="true"
href="https://github.com/openstack/networking-cisco/blob/master/networking_cisco/apps/saf/common/rpc.py#L89"
                  rel="noreferrer" target="_blank">https://github.com/openstack/networking-cisco/blob/master/networking_cisco/apps/saf/common/rpc.py#L89</a><br>
                2. NotifcationListener(object):<br>
                <a moz-do-not-send="true"
href="https://github.com/openstack/networking-cisco/blob/master/networking_cisco/apps/saf/common/rpc.py#L100"
                  rel="noreferrer" target="_blank">https://github.com/openstack/networking-cisco/blob/master/networking_cisco/apps/saf/common/rpc.py#L100</a><br>
                3. and call start() and  then wait()<br>
              </blockquote>
              <br>
            </span>
            the correct usage is to call stop() before wait()[1]. for
            reference on how to use listeners, you can see Ceilometer[2]<br>
            <br>
            [1]<a moz-do-not-send="true"
href="http://docs.openstack.org/developer/oslo.messaging/notification_listener.html"
              rel="noreferrer" target="_blank">http://docs.openstack.org/developer/oslo.messaging/notification_listener.html</a><br>
            [2] <a moz-do-not-send="true"
href="https://github.com/openstack/ceilometer/blob/master/ceilometer/utils.py#L250"
              rel="noreferrer" target="_blank">https://github.com/openstack/ceilometer/blob/master/ceilometer/utils.py#L250</a><span
              class="HOEnZb"><font color="#888888"><br>
                <br>
                -- <br>
                gord</font></span>
            <div class="HOEnZb">
              <div class="h5"><br>
                <br>
                <br>
__________________________________________________________________________<br>
                OpenStack Development Mailing List (not for usage
                questions)<br>
                Unsubscribe: <a moz-do-not-send="true"
href="http://OpenStack-dev-request@lists.openstack.org?subject:unsubscribe"
                  rel="noreferrer" target="_blank">OpenStack-dev-request@lists.openstack.org?subject:unsubscribe</a><br>
                <a moz-do-not-send="true"
                  href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev"
                  rel="noreferrer" target="_blank">http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev</a><br>
              </div>
            </div>
          </blockquote>
        </div>
        <br>
      </div>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
      <pre wrap="">__________________________________________________________________________
OpenStack Development Mailing List (not for usage questions)
Unsubscribe: <a class="moz-txt-link-abbreviated" href="mailto:OpenStack-dev-request@lists.openstack.org?subject:unsubscribe">OpenStack-dev-request@lists.openstack.org?subject:unsubscribe</a>
<a class="moz-txt-link-freetext" href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev">http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev</a>
</pre>
    </blockquote>
    <br>
    <pre class="moz-signature" cols="72">-- 
gord</pre>
  </body>
</html>