fear: nats log promihous
This commit is contained in:
parent
90a3fd5861
commit
3ba9704741
|
@ -27,11 +27,13 @@ import { ForbiddenExceptionFilter } from './filter/forbid.filter';
|
|||
ClientsModule.register([
|
||||
{
|
||||
name: 'Client',
|
||||
transport: Transport.NATS,
|
||||
transport: Transport.RMQ,
|
||||
options: {
|
||||
servers: ['nats://localhost:4222'],
|
||||
maxReconnectAttempts: 5,
|
||||
reconnectTimeWait: 1000,
|
||||
urls: ['amqp://localhost:5672'],
|
||||
queue: 'cats_queue',
|
||||
queueOptions: {
|
||||
durable: false,
|
||||
},
|
||||
},
|
||||
},
|
||||
]),
|
||||
|
|
|
@ -8,11 +8,13 @@ import { ClientsModule, Transport } from '@nestjs/microservices';
|
|||
ClientsModule.register([
|
||||
{
|
||||
name: 'Client',
|
||||
transport: Transport.NATS,
|
||||
transport: Transport.RMQ,
|
||||
options: {
|
||||
servers: ['nats://localhost:4222'],
|
||||
maxReconnectAttempts: 5,
|
||||
reconnectTimeWait: 1000,
|
||||
urls: ['amqp://localhost:5672'],
|
||||
queue: 'cats_queue',
|
||||
queueOptions: {
|
||||
durable: false,
|
||||
},
|
||||
},
|
||||
},
|
||||
]),
|
||||
|
|
|
@ -6,11 +6,13 @@ async function bootstrap() {
|
|||
const app = await NestFactory.createMicroservice<MicroserviceOptions>(
|
||||
AppModule,
|
||||
{
|
||||
transport: Transport.NATS,
|
||||
transport: Transport.RMQ,
|
||||
options: {
|
||||
servers: ['nats://localhost:4222'], // 可以指定链接到多个nats的消息队列
|
||||
maxReconnectAttempts: 5,
|
||||
reconnectTimeWait: 1000,
|
||||
urls: ['amqp://localhost:5672'],
|
||||
queue: 'cats_queue',
|
||||
queueOptions: {
|
||||
durable: false,
|
||||
},
|
||||
},
|
||||
},
|
||||
);
|
||||
|
|
|
@ -6,11 +6,13 @@ async function bootstrap() {
|
|||
const app = await NestFactory.createMicroservice<MicroserviceOptions>(
|
||||
AppModule,
|
||||
{
|
||||
transport: Transport.NATS,
|
||||
transport: Transport.RMQ,
|
||||
options: {
|
||||
servers: ['nats://localhost:4222'], // 可以指定链接到多个nats的消息队列
|
||||
maxReconnectAttempts: 5,
|
||||
reconnectTimeWait: 1000,
|
||||
urls: ['amqp://localhost:5672'],
|
||||
queue: 'cats_queue',
|
||||
queueOptions: {
|
||||
durable: false,
|
||||
},
|
||||
},
|
||||
},
|
||||
);
|
||||
|
|
|
@ -6,11 +6,13 @@ async function bootstrap() {
|
|||
const app = await NestFactory.createMicroservice<MicroserviceOptions>(
|
||||
AppModule,
|
||||
{
|
||||
transport: Transport.NATS,
|
||||
transport: Transport.RMQ,
|
||||
options: {
|
||||
servers: ['nats://localhost:4222'], // 可以指定链接到多个nats的消息队列
|
||||
maxReconnectAttempts: 5,
|
||||
reconnectTimeWait: 1000,
|
||||
urls: ['amqp://localhost:5672'],
|
||||
queue: 'cats_queue',
|
||||
queueOptions: {
|
||||
durable: false,
|
||||
},
|
||||
},
|
||||
},
|
||||
);
|
||||
|
|
|
@ -8,11 +8,13 @@ import { ClientsModule, Transport } from '@nestjs/microservices';
|
|||
ClientsModule.register([
|
||||
{
|
||||
name: 'Client',
|
||||
transport: Transport.NATS,
|
||||
transport: Transport.RMQ,
|
||||
options: {
|
||||
servers: ['nats://localhost:4222'],
|
||||
maxReconnectAttempts: 5,
|
||||
reconnectTimeWait: 1000,
|
||||
urls: ['amqp://localhost:5672'],
|
||||
queue: 'cats_queue',
|
||||
queueOptions: {
|
||||
durable: false,
|
||||
},
|
||||
},
|
||||
},
|
||||
]),
|
||||
|
|
|
@ -21,11 +21,13 @@ import { AdminModule } from './admin/admin.module';
|
|||
ClientsModule.register([
|
||||
{
|
||||
name: 'Client',
|
||||
transport: Transport.NATS,
|
||||
transport: Transport.RMQ,
|
||||
options: {
|
||||
servers: ['nats://localhost:4222'],
|
||||
maxReconnectAttempts: 5,
|
||||
reconnectTimeWait: 1000,
|
||||
urls: ['amqp://localhost:5672'],
|
||||
queue: 'cats_queue',
|
||||
queueOptions: {
|
||||
durable: false,
|
||||
},
|
||||
},
|
||||
},
|
||||
]),
|
||||
|
|
|
@ -6,11 +6,13 @@ async function bootstrap() {
|
|||
const app = await NestFactory.createMicroservice<MicroserviceOptions>(
|
||||
AppModule,
|
||||
{
|
||||
transport: Transport.NATS,
|
||||
transport: Transport.RMQ,
|
||||
options: {
|
||||
servers: ['nats://localhost:4222'], // 可以指定链接到多个nats的消息队列
|
||||
maxReconnectAttempts: 5,
|
||||
reconnectTimeWait: 1000,
|
||||
urls: ['amqp://localhost:5672'],
|
||||
queue: 'cats_queue',
|
||||
queueOptions: {
|
||||
durable: false,
|
||||
},
|
||||
},
|
||||
},
|
||||
);
|
||||
|
|
|
@ -6,11 +6,13 @@ async function bootstrap() {
|
|||
const app = await NestFactory.createMicroservice<MicroserviceOptions>(
|
||||
AppModule,
|
||||
{
|
||||
transport: Transport.NATS,
|
||||
transport: Transport.RMQ,
|
||||
options: {
|
||||
servers: ['nats://localhost:4222'], // 可以指定链接到多个nats的消息队列
|
||||
maxReconnectAttempts: 5,
|
||||
reconnectTimeWait: 1000,
|
||||
urls: ['amqp://localhost:5672'],
|
||||
queue: 'cats_queue',
|
||||
queueOptions: {
|
||||
durable: false,
|
||||
},
|
||||
},
|
||||
},
|
||||
);
|
||||
|
|
|
@ -7,11 +7,13 @@ import { ClientsModule, Transport } from '@nestjs/microservices';
|
|||
ClientsModule.register([
|
||||
{
|
||||
name: 'Client',
|
||||
transport: Transport.NATS,
|
||||
transport: Transport.RMQ,
|
||||
options: {
|
||||
servers: ['nats://localhost:4222'],
|
||||
maxReconnectAttempts: 5,
|
||||
reconnectTimeWait: 1000,
|
||||
urls: ['amqp://localhost:5672'],
|
||||
queue: 'cats_queue',
|
||||
queueOptions: {
|
||||
durable: false,
|
||||
},
|
||||
},
|
||||
},
|
||||
]),
|
||||
|
|
|
@ -7,11 +7,13 @@ import { ClientsModule, Transport } from '@nestjs/microservices';
|
|||
ClientsModule.register([
|
||||
{
|
||||
name: 'Client',
|
||||
transport: Transport.NATS,
|
||||
transport: Transport.RMQ,
|
||||
options: {
|
||||
servers: ['nats://localhost:4222'],
|
||||
maxReconnectAttempts: 5,
|
||||
reconnectTimeWait: 1000,
|
||||
urls: ['amqp://localhost:5672'],
|
||||
queue: 'cats_queue',
|
||||
queueOptions: {
|
||||
durable: false,
|
||||
},
|
||||
},
|
||||
},
|
||||
]),
|
||||
|
|
|
@ -21,11 +21,13 @@ import * as cookieParser from 'cookie-parser';
|
|||
ClientsModule.register([
|
||||
{
|
||||
name: 'Client',
|
||||
transport: Transport.NATS,
|
||||
transport: Transport.RMQ,
|
||||
options: {
|
||||
servers: ['nats://localhost:4222'],
|
||||
maxReconnectAttempts: 5,
|
||||
reconnectTimeWait: 1000,
|
||||
urls: ['amqp://localhost:5672'],
|
||||
queue: 'cats_queue',
|
||||
queueOptions: {
|
||||
durable: false,
|
||||
},
|
||||
},
|
||||
},
|
||||
]),
|
||||
|
|
|
@ -7,11 +7,13 @@ import { ClientsModule, Transport } from '@nestjs/microservices';
|
|||
ClientsModule.register([
|
||||
{
|
||||
name: 'Client',
|
||||
transport: Transport.NATS,
|
||||
transport: Transport.RMQ,
|
||||
options: {
|
||||
servers: ['nats://localhost:4222'],
|
||||
maxReconnectAttempts: 5,
|
||||
reconnectTimeWait: 1000,
|
||||
urls: ['amqp://localhost:5672'],
|
||||
queue: 'cats_queue',
|
||||
queueOptions: {
|
||||
durable: false,
|
||||
},
|
||||
},
|
||||
},
|
||||
]),
|
||||
|
|
|
@ -6,11 +6,13 @@ async function bootstrap() {
|
|||
const app = await NestFactory.createMicroservice<MicroserviceOptions>(
|
||||
AppModule,
|
||||
{
|
||||
transport: Transport.NATS,
|
||||
transport: Transport.RMQ,
|
||||
options: {
|
||||
servers: ['nats://localhost:4222'], // 可以指定链接到多个nats的消息队列
|
||||
maxReconnectAttempts: 5,
|
||||
reconnectTimeWait: 1000,
|
||||
urls: ['amqp://localhost:5672'],
|
||||
queue: 'cats_queue',
|
||||
queueOptions: {
|
||||
durable: false,
|
||||
},
|
||||
},
|
||||
},
|
||||
);
|
||||
|
|
|
@ -11,6 +11,12 @@ services:
|
|||
environment:
|
||||
- RABBITMQ_DEFAULT_USER=guest
|
||||
- RABBITMQ_DEFAULT_PASS=guest
|
||||
# volumes:
|
||||
# - rabbitmq-data:/var/lib/rabbitmq
|
||||
command: >
|
||||
bash -c "rabbitmq-plugins enable rabbitmq_management &&
|
||||
rabbitmq-plugins enable rabbitmq_tracing &&
|
||||
rabbitmq-server"
|
||||
|
||||
mongodb:
|
||||
image: mongo:5.0
|
||||
|
|
Loading…
Reference in New Issue
Block a user