【发布时间】:2021-10-04 23:29:36
【问题描述】:
我对 websocket 客户端 url 有疑问。我想为我的客户端机器使用远程 websocket 服务器。
Machine1, Machine2 ---> Remote Websocket Server
我有一个这样的 websocket 配置。
<websocket:message-broker application-destination-prefix="/app">
<websocket:stomp-endpoint path="/stomp" allowed-origins="*">
<websocket:handshake-handler ref="myHandshakeHandler"/>
<websocket:sockjs client-library-url="https://cdn.jsdelivr.net/npm/sockjs-client@1/dist/sockjs.min.js"/>
</websocket:stomp-endpoint>
<websocket:simple-broker prefix="/topic,/queue"/>
<websocket:client-inbound-channel>
<websocket:interceptors>
<ref bean="myInterceptor"/>
</websocket:interceptors>
</websocket:client-inbound-channel>
</websocket:message-broker>
我想发布并获取 websocket 操作的远程 url,这样我就可以多台我的 gui 机器。如何将websocket主机urllocalhost改为https://remotemachineurl:61614。
【问题讨论】:
-
谢谢贾斯汀,你帮了我很多。删除 artemis 标签时。 :)