Comments (5)
BTW. When running publisher example using rstream
from git repo:
Traceback (most recent call last):
File "/home/wrobell/projects/snippets/rabbitmq/producer.py", line 15, in <module>
asyncio.run(publish())
File "/usr/lib/python3.9/asyncio/runners.py", line 44, in run
return loop.run_until_complete(main)
File "/usr/lib/python3.9/asyncio/base_events.py", line 642, in run_until_complete
return future.result()
File "/home/wrobell/projects/snippets/rabbitmq/producer.py", line 13, in publish
await producer.publish('mystream', f'msg: {i}'.encode())
File "/home/wrobell/.local/lib/python3.9/site-packages/rstream/producer.py", line 199, in publish
publishing_ids = await self.publish_batch(
File "/home/wrobell/.local/lib/python3.9/site-packages/rstream/producer.py", line 165, in publish_batch
msg = RawMessage(item) if isinstance(item, bytes) else item
TypeError: RawMessage() takes no arguments
from rstream.
the stream must exist.
if you try the java client you will have the same result:
Consumer consumer =
environment.consumerBuilder()
.stream("stream_that_is_not_created_before")
.offset(OffsetSpecification.offset(100))
.messageHandler((context, message) -> {
error:
Exception in thread "main" com.rabbitmq.stream.StreamDoesNotExistException: Stream stream_that_is_not_created_before does not exist
at com.rabbitmq.stream.impl.ConsumersCoordinator.findBrokersForStream(ConsumersCoordinator.java:134)
at com.rabbitmq.stream.impl.ConsumersCoordinator.subscribe(ConsumersCoordinator.java:88)
at com.rabbitmq.stream.impl.StreamEnvironment.registerConsumer(StreamEnvironment.java:471)
at com.rabbitmq.stream.impl.StreamConsumer.<init>(StreamConsumer.java:91)
at com.rabbitmq.stream.impl.StreamConsumerBuilder.build(StreamConsumerBuilder.java:113)
at Main.main(Main.java:82)
from rstream.
Thanks for the example. There is stream creator concept though. This seems to allow to create streams by both producers and consumers?
from rstream.
the streamCreator()
is an environment
method, so nothing to do with publishers and consumers.
from rstream.
OK. I do understand the distinction your are point at. Let's close this issue then.
from rstream.
Related Issues (20)
- Provide a name to client connections
- Is rstream suppout External credentials HOT 1
- superstream: Close/Remove locator connection when not needed anymore
- avoid to keep locator connections opened
- NotImplementedError in basic_consumers /basic_consumer.py HOT 7
- OverflowError: int too big to convert HOT 3
- Implement Create/Delete SuperStream feature
- Is there something like deadletter queue in RabbitMQ Stream? HOT 2
- Future must be safely set_result HOT 3
- pypi: username/password authentication deprecated HOT 4
- review/refactor examples
- Preventing Excessive Callback Invocations After Consumer Closure in `consumer.subscribe` HOT 2
- Request for Callback Disconnection Feature After Receiving the Last Message HOT 1
- Offset specifications ignored when using SuperStream with stream plugin HOT 3
- Reviewing/Improving logging and exceptions
- Implement maxProducersByConnection and maxConsumerByConnection
- Fail to build on Mac M* series HOT 5
- Stream connection error while using rabbitmq and docker on remote server HOT 3
- Implement a builder or validator for the arguments
- Change the default codec from binary to AMQP 1.0
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 rstream.