Comments (6)
@michaelkrone You were correct, there's a bug in the way subscribers are attached when using exchange types other than topic
. I've opened an issue to track it #5
It should be a small tweak so I'll get the fix up this weekend
from nestjs.
Hey @michaelkrone thanks for checking out the project. Out of curiosity what version of the package are you currently referencing? I believe that there was an issue with the timeout which I've already fixed up. I don't see the same behavior when using RPC in the kitchen-sink
example.
The steps I'm taking are to start up Rabbit using the docker-compose file in the Kitchen Sink project (docker-compose up -d
) and then to run the application using yarn start
. After that if you view localhost:3000/messaging
you should get a JSON response (which is retrieved through the RMQ exchange) and there shouldn't be any timeout error messages received.
Also, if during your investigation you notice any other issues that might otherwise prevent you from adopting please let me know as I'm engaged and motivated to make the developer experience as pleasing as possible.
from nestjs.
I did just notice that the Kitchen Sink example was referencing an older version of the @nestjs-plus/rabbitmq
package and I've updated it to latest with #4 but even on the earlier version it doesn't have the timeout issue you're referencing.
from nestjs.
Hi @WonderPanda , thank you for your quick response.
You are right, the RPC example is working fine. I looked up my changes and it turned out I used connection.request
when I meant to use connection.publish
, so the Timeout Exception is completely valid in that case.
I will close this Issue, sorry for any inconveniences.
P.S.
One thing I am investigating is when adding a second exchange with type 'fanout', the management console lists it with the correct type, but the following exception is thrown at startup:
Channel closed by server: 406 (PRECONDITION-FAILED) with message "PRECONDITION_FAILED - inequivalent arg 'type' for exchange 'exchange2' in vhost '/': received 'topic' but current is 'fanout'"
I will open another Issue if this turns out to be a problem, but I will make sure that this time it's not my incompetence that takes your time ;)
from nestjs.
@michaelkrone No problem! It just makes me happy that people are starting to check things out. I will definitely look into the different exchange types and see if there's something going on there.
One thing that is somewhat strange is that the intention for RPC is that you would use the request method as you're setting up a listener internally to get the response from the RPC handler. So it's a little weird about publish as that one is more intended for Pub/Sub scenarios. Are you able to share the repository or a small example that reproduces your setup so I can make sure that it's what you need?
from nestjs.
@michaelkrone #5 is now closed and I've updated the kitchen sink example app. Should be fine to use the different exchanges types now
from nestjs.
Related Issues (20)
- @golevelup/ts-jest default mocks return an empty object which is inconsistent with jest.fn() which returns undefined.
- @golevelup/nestjs-rabbitmq- error when publish message: Channel closed
- ts-jest - When function is called with a mock, toHaveBeenCalledWith() always succeed even when it should not
- rabbitmq: allow per subscriber/handler deserializer customization HOT 1
- RabbitMQ AmqpConnection access from child module
- Wildcard routing stopped working. RabbitMQ
- rabbitmq: support specifying exchange per routing key in RabbitSubscribe
- Single Channel Configuration Across Multiple @RabbitSubscribe Decorators Not Working as Expected
- No delivery mode option on AmqpConnection.request method HOT 2
- RabbitMQ: RabbitSubscribe using a handler name without corresponding handler config asserts randomized queues HOT 3
- rabbitmq: consumerTags are not cleaned up on connection/channel disconnect
- rabbitmq: canceled consumers are resumed if connection/channel reconnects HOT 1
- rabbitmq: direct sending to queue without the need for exchanges HOT 1
- rabbitmq: binding a queue to exchange without a routingKey
- ts-jest: Cannot create mock of a class which has private dependencies in constructor
- rabbitmq: handlers didn't works in app-non-pub HOT 1
- golevelup/nestjs-stripe: project can not compile
- Stripe Test Webhook
- Stripe webhooks - "undefined" is not valid JSON HOT 2
- How should I use this within RabbitSubscribe method?
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 nestjs.