Giter Site home page Giter Site logo

Comments (5)

WonderPanda avatar WonderPanda commented on May 22, 2024 1

At first I thought that you simply wanted to disable all RabbitMQ behavior for certain instances of your application. If this were the case, you can just conditionally build up your imports array based on an environment/config variable and exclude the call to RabbitMQModule.forRoot/forRootAsync.

Since you also want to be able to still interact with the AmqpConnection to be able to publish messages however, this would require some tweaking to the library.

I don't see a problem with adding in an additional configuration option that will allow you to control whether or not handlers get attached to RabbitMQ though since I can see this being a common use case that will come up. It shouldn't be a large change, I'll try to get a new package version pushed this week

from nestjs.

WonderPanda avatar WonderPanda commented on May 22, 2024 1

@theabuitendyk This feature is now available in version 1.10.0

from nestjs.

theabuitendyk avatar theabuitendyk commented on May 22, 2024

Thanks for your help @WonderPanda!

from nestjs.

priyankinfinnov avatar priyankinfinnov commented on May 22, 2024

Is there a way to register dynamically on the fly @WonderPanda @theabuitendyk ?

Context: I am writing a e2e/integration test for a distributed system. And i want to hold the queue consumer for some time. So i can use registerHandlers flag but when i want them to be executed how do i register dynamically via code?

from nestjs.

WonderPanda avatar WonderPanda commented on May 22, 2024

@priyankinfinnov You can inject the AmqpConnection and interact directly with it to register subscriptions/rpc etc

from nestjs.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.