Nodejs-Roadmap icon indicating copy to clipboard operation
Nodejs-Roadmap copied to clipboard

消息中间件之RabbitMQ - Node.js技术栈

Open qufei1993 opened this issue 5 years ago • 3 comments

https://www.nodejs.red/#/microservice/rabbitmq-base

Description

qufei1993 avatar May 30 '19 22:05 qufei1993

请教下,我按教程启动后发生以下问题,请问是什么问题呢? ode mq/producer.js (node:73508) UnhandledPromiseRejectionWarning: Error: Socket closed abruptly during opening handshake at Socket.endWhileOpening (/Users/priest/node_modules/amqplib/lib/connection.js:260:17) at Socket.emit (events.js:327:22) at endReadableNT (internal/streams/readable.js:1327:12) at processTicksAndRejections (internal/process/task_queues.js:80:21) (Use node --trace-warnings ... to show where the warning was created) (node:73508) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag --unhandled-rejections=strict (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1) (node:73508) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

0xarbs avatar Oct 08 '21 09:10 0xarbs

本地服务器是启动了的: ➜ 3.9.7 sbin/rabbitmq-server 2021-10-08 17:05:59.733339+08:00 [info] <0.221.0> Feature flags: list of feature flags found: 2021-10-08 17:05:59.747816+08:00 [info] <0.221.0> Feature flags: [x] implicit_default_bindings 2021-10-08 17:05:59.747855+08:00 [info] <0.221.0> Feature flags: [x] maintenance_mode_status 2021-10-08 17:05:59.747879+08:00 [info] <0.221.0> Feature flags: [x] quorum_queue 2021-10-08 17:05:59.747897+08:00 [info] <0.221.0> Feature flags: [x] stream_queue 2021-10-08 17:05:59.747979+08:00 [info] <0.221.0> Feature flags: [x] user_limits 2021-10-08 17:05:59.747992+08:00 [info] <0.221.0> Feature flags: [x] virtual_host_metadata 2021-10-08 17:05:59.748004+08:00 [info] <0.221.0> Feature flags: feature flag states written to disk: yes 2021-10-08 17:06:00.181992+08:00 [noti] <0.44.0> Application syslog exited with reason: stopped 2021-10-08 17:06:00.182045+08:00 [noti] <0.221.0> Logging: switching to configured handler(s); following messages may not be visible in this log output

## RabbitMQ 3.9.7

########## Copyright (c) 2007-2021 VMware, Inc. or its affiliates.

########## Licensed under the MPL 2.0. Website: https://rabbitmq.com

Erlang: 24.1 [jit] TLS Library: OpenSSL - OpenSSL 1.1.1l 24 Aug 2021

Doc guides: https://rabbitmq.com/documentation.html Support: https://rabbitmq.com/contact.html Tutorials: https://rabbitmq.com/getstarted.html Monitoring: https://rabbitmq.com/monitoring.html

Logs: /usr/local/var/log/rabbitmq/[email protected] /usr/local/var/log/rabbitmq/rabbit@localhost_upgrade.log

Config file(s): (none)

Starting broker... completed with 7 plugins.

0xarbs avatar Oct 08 '21 09:10 0xarbs

设置了path之后也还是不行 export PATH=/usr/local/Cellar/rabbitmq//sbin:$PATH

0xarbs avatar Oct 08 '21 10:10 0xarbs