我正在使用stomp.js通过WebSocket连接到ActiveMQ。
var url = "ws://localhost:61614/stomp";
var topic = "/topic/STOMPTEST";
var message = $('#message').val();
stompClient = Stomp.client(url);
stompClient.connect('', '', function (args) {
console.log('connected');
stompClient.send(topic, {}, message);
}, onfail);
如果邮件大小超过16KB,则它将与AMQ断开连接。在ActiveMQ控制台上获取和警告..说明
警告|短信太大> SCEP @ 3f1de914 {l(/ 10。)的16384个字符。 119.43.206:65157)<> R(/10.119.43.206:61614),d =真,开放=真,ISHUT =假,oshut =假,RB =假,WB =假,W =真,I = 1r} - {WebSocketServletConnectionRFC6455 p = WebSocketParserRFC6455 @ 3012db7c state = DATA buffer = g = WebSocketGeneratorRFC6455 @ 2607c28c closed = false buffer = -1}
在阅读ActiveMQ时,我发现在activemq.xml中可以像这样增加
<transportConnector name="ws" uri="ws://0.0.0.0:61614?maximumConnections=1000&wireFormat.maxFrameSize=104857600&transport.maxTextMessageSize=999999"/>
但是遇到同样的问题。 请帮忙。