Comments (2)
Channel.wait is a relic from amqplib, I don't believe it's used anymore.
Connection.drain_events is the common way to read from the socket, it will drain events from all channels and supports a timeout argument. Like channel.wait it's also a blocking function though, so if you want to drain events asynchronously you should use select/poll/epoll to call the function when the socket is readable.
kombu.async is what celery uses to consume messages asynchronously, but the API is not really public yet. You don't have to use kombu, as you should be able to write a simple select loop around py-amqp, but you will have to learn how to do that elsewhere.
from py-amqp.
As a temporary solution I set a timeout on drain_events and simply caught the timeout event. Works like a charm. Thanks.
from py-amqp.
Related Issues (20)
- Version 5.0.4 has an error HOT 16
- TCP_USER_TIMEOUT doesn't exist on solaris 11.4 HOT 2
- [BUG] Cannot set cert_reqs=ssl.CERT_NONE due to order of context modification in _wrap_socker_sni HOT 1
- Potentially broken _AbstractTransport.__repr__ HOT 4
- 5.0.6: sphinx warnings HOT 6
- 5.0.6: test suite is using `case` which uses `nose` (which is outdated) HOT 2
- Initial Update
- 5.0.7 SSL connection problem HOT 4
- Celery broken after release 5.0.8 HOT 6
- 5.1.1: pytest warnings HOT 2
- 'Server unexpectedly closed connection' HOT 6
- Waht is stable version? HOT 1
- amqp.exceptions.NotFound: Queue.declare: (404) NOT_FOUND
- pyamqp won't send heartbeat?
- 5.1.1: documentation build fails with sphinx 6.1.3 HOT 3
- Maximum recursion depth exceeded
- How does pyamqp/kombu make multiple threads share the same amqp connection? HOT 5
- bug: version 5.2.0 breaks celery with sqs msg processing HOT 3
- Client which use amqp lib always think that connection is blocked.
- Basic.publish: (406) PRECONDITION_FAILED - message size larger than configured max HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from py-amqp.