Error: channel is not available
See original GitHub issueI’m creating an API which will accept the message and then will publish it to the queue.
So i have initialized my app.module.ts
@Module({
imports: [
RabbitMQModule.forRootAsync(RabbitMQModule, {
imports: [ConfigModule],
inject: [ConfigService],
useFactory: (configService: ConfigService) => ({
uri: configService.get('RABBIT_MQ_URI')
})
}),
],
controllers: [AppController],
providers: [
AppService
],
})
export class AppModule {}
And in the service imported the library AMQPService like this constructor(private readonly amqpConnection: AmqpConnection){}
So when, using the methods exposed like this this.amqpConnection.channel.assertExchange(exchange.name, exchange.type, exchange.options); and it throws Error: channel is not available.
When logged amqpConnection, recieved this object
AmqpConnection {
messageSubject: Subject {
closed: false,
currentObservers: null,
observers: [],
isStopped: false,
hasError: false,
thrownError: null
},
logger: Logger { context: 'AmqpConnection', options: {} },
initialized: Subject {
closed: false,
currentObservers: null,
observers: [],
isStopped: false,
hasError: false,
thrownError: null
},
_managedChannels: {},
_channels: {},
config: {
prefetchCount: 10,
defaultExchangeType: 'topic',
defaultRpcErrorBehavior: 'REQUEUE',
defaultSubscribeErrorBehavior: 'REQUEUE',
exchanges: [],
defaultRpcTimeout: 10000,
connectionInitOptions: { wait: true, timeout: 5000, reject: true },
connectionManagerOptions: {},
registerHandlers: true,
enableDirectReplyTo: true,
channels: {},
enableControllerDiscovery: false
}
}
Expectations:
- Should be able to assert an exchange.
Issue Analytics
- State:
- Created a year ago
- Comments:9 (1 by maintainers)
Top Results From Across the Web
Trying to remedy the "Channel is currently unavailable" error
Solved: I started getting "channel not available" errors a couple weeks ago on our main (living room) DVR STB as well as pixelation,...
Read more >Get Help With Channel Not Available Error - DIRECTV
Learn how to troubleshoot the Channel Not Available error message.
Read more >Error channel not available. Staging setup - Ross-Tech Forums
Hi. Can not setup staging in a car mk6. I can try this configurations: - module 17 instruments - UDS adaptation - Channel...
Read more >How to fix the error “Channel not found in ... - YouTube
How to fix the error “ Channel not found in installation skipping load routine” while opening LumionWe face many problems while using Lumion ......
Read more >Why Does YouTube Have "This Channel Is Not Available"?
Channel Has Been Closed. A YouTube channel may be listed as unavailable if the owner has closed the YouTube account for that specific...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

I think this is bug of the version 2.3.0 In version “@golevelup/nestjs-rabbitmq”: “2.2.0” all works fine
Since we’re still using 2.2 for our backend, best if we tried to update it to current version and see if problem persist. However that’s not a priority. When that happens, I’ll report back here.