Comments (8)
OK, thanks anyway
from amqplib.
You can force a timestamp using the following syntax
x-stream-offset’: { ‘!’: ‘timestamp’, value: 1686519750 }
Where 1686519750
is the number of seconds (as opposed to miliseconds) since 00:00:00 UTC, 1970-01-01
from amqplib.
I have tried to use the coded of this lib: https://github.com/amqp-node/amqplib/blob/4993dee433665e9e6fe7729f3eaeacca06b46cb7/lib/codec.js
but so far I was not succesful.
I guess that I have to use it, to encode a timestamp correctly.
Can someone shed some light on how to do that?
from amqplib.
I'm now using https://github.com/coders51/rabbitmq-stream-js-client instead.
It required some work as it is still experimental, but mostly merging locally the open PRs was enough.
I only consume through the rabbitmq-stream-js-client
lib, to publish and create I still do through amqplib
.
Just letting people here know in case they try to use streams.
Maybe worth noting in the "streams example" in this repo that timestamp offsets don't work currently.
from amqplib.
Hi @snird,
Thank you. I did have a look over the weekend but couldn't get the streams example working either. Do you have a public repo with the working version of rabbitmq-stream-js-client? I'd like to see what the x-stream-offset timestamp looks like with Wireshark and compare with amqplib
Thanks
Steve
from amqplib.
I don't have it public, as it is still on testing phase on my side.
Anyway, that won't help your case: the https://github.com/coders51/rabbitmq-stream-js-client lib uses the binary format of streams in RabbitMQ. That's not amqp 0.9.1 at all, so there are no possible comparisons.
from amqplib.
I'll leave this issue open until I've added something to the streams example & documentation
from amqplib.
Done. Thanks for opening this issue @snird, it was interesting.
from amqplib.
Related Issues (20)
- SDK connecting without errors after RabbitMQ service is shut down HOT 9
- Error emitted before handler is attached causes "Unhandled 'error' event" HOT 3
- consume does not respect promises? HOT 5
- Trailing dot in URL causes TLS failure HOT 2
- docs: channel api github page has broken top links HOT 2
- docs: confusing and inconsistent usage of terms "bork", "splode", "close" HOT 7
- global prefetch become 0 if per-consume prefetch set HOT 2
- ERR_SSL_EMS_NOT_ENABLED HOT 6
- How to determine if channel.ack() is successful? HOT 2
- CPU intensive controller prevents AMQP connection from receiving heartbeat, hence connections gets closed. HOT 2
- How to know if message is published ? HOT 6
- Aborting a Message Processing when RMQ Channel Closes HOT 8
- I'm encountering an "Unexpected close" error HOT 2
- Module not found: Can't resolve 'querystring' HOT 2
- Feature: Add support for AMQP 0.9.1 "update-secret" HOT 11
- 501 (FRAME-ERROR) - after indeterminate amount of large messages HOT 6
- Emits a acknowledge event. HOT 1
- Unable to cancel consumers HOT 4
- Error: Unexpected close at succeed HOT 13
- Typo in the example code 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 amqplib.