Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8112637
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T02:34:09+00:00 2026-06-06T02:34:09+00:00

How is different from multiplexing several sockets via a POLLIN? while True: socks =

  • 0

How is different from multiplexing several sockets via a POLLIN?

while True:
    socks = dict(poller.poll())

    if socks.get(control_receiver) == zmq.POLLIN:
        ...

    if socks.get(work_receiver) == zmq.POLLIN:
        ...

How can it make listener threads more reliable and easier to handle?


Background: I am rolling my own API server and wondering how to make the controller (the part that receives the requests from external source and control signals from the workers)

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-06T02:34:10+00:00Added an answer on June 6, 2026 at 2:34 am

    ØMQ Poller can be used to serve and communicate with multiple sockets.

    How ever, with ØMQ Poller, you end up with explicit blocks (under if loop) for handling the sockets. Each socket registered with ØMQ Poller has to have an explicit “if block” to handle it.

    This becomes unwieldy as you start writing bigger programs. I would like to add – “a bit ugly”

    With Event Loops, this becomes more streamlined as you can register callbacks to receive and send data and you can structure your callback else where.

    I have following examples from the tutorial that I am writing.

    1. http://learning-0mq-with-pyzmq.readthedocs.org/en/latest/pyzmq/multisocket/zmqpoller.html
    2. http://learning-0mq-with-pyzmq.readthedocs.org/en/latest/pyzmq/multisocket/tornadoeventloop.html

    Others can add on to this understanding or correct it.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is C# Split Function different from Java ? Why do I get this error
I got a core that looks very different from the ones I usually get
Different from this question , but similar in that I don't get an error
Redis is conceptually different from traditional SQL databases that I use, and I'm trying
How are keyword arguments different from regular arguments? Can't all arguments be passed as
My question in slightly different from the $fopen $fwrite function Since what i would
My question is slightly different from Looking for a recommendation for a lightweight mobile
Is UIObject#setVisible(false) functionally different from Widget#removeFromParent ? Besides, Is DialogBox#hide just a wapper call
This question is a little different from others of a similar title. I am
my question is a bit different from the other ones.. i got an xsl-code

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.