没有 SockJS 的 RabbitMQ Web STOMP [英] RabbitMQ Web STOMP without SockJS

查看:58
本文介绍了没有 SockJS 的 RabbitMQ Web STOMP的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以在没有 SockJS 库的情况下设置 RabbitMQ Web STOMP 连接?

Is it possible to setup RabbitMQ Web STOMP connection without SockJS library?

我玩过 rabbitmq-web-stomp 插件但没有成功,因为服务器生成的初始响应是 Welcome to SockJS!(这显然不是基于 STOMP 的消息).

I have played around with rabbitmq-web-stomp plugin without a success as the initial response generated by the server is Welcome to SockJS! (which is obviously not a STOMP based message).

真的需要 SockJS 吗?它为游戏带来了什么(除了旧版浏览器支持)?

Is SockJS really required? What does it bring into the game (besides legacy browser support)?

推荐答案

SockJS 协议 支持 /websocket 路径下的原始 WebSocket 客户端.

SockJS protocol does support raw WebSocket clients under /websocket path.

任何符合 0.3 协议的 SockJS 服务器都支持原始 WebSocket url.测试服务器的原始 WebSocket url 如下所示:

Any SockJS server complying with 0.3 protocol does support a raw WebSocket url. The raw WebSocket url for the test server looks like:

ws://localhost:8081/echo/websocket

您可以将任何符合 WebSocket RFC 6455 的 WebSocket 客户端连接到此网址.

You can connect any WebSocket RFC 6455 compliant WebSocket client to this url.

Rabbit 的实现也支持这一点.所以默认端点是:http://example.com:15674/stomp/websocket.

This is supported by Rabbit's implementation as well. So the default endpoint is: http://example.com:15674/stomp/websocket.

这篇关于没有 SockJS 的 RabbitMQ Web STOMP的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆