Skip to content
This repository has been archived by the owner on Nov 28, 2018. It is now read-only.

stomp consumer throws exception when use queue name like PRICE.STOCK.> #50

Open
mseld opened this issue Jun 2, 2018 · 0 comments
Open

Comments

@mseld
Copy link

mseld commented Jun 2, 2018

Stomp consumer doesn't support wildcards

var stomp_args = {
    host: "localhost",
    port: 61613,
    debug: false
}

var headers = {
    destination: "/queue/PRICE.STOCK.>",
    ack: "client-individual"
};

var client = new stomp.Stomp(stomp_args);

client.subscribe(headers, message_callback);

function message_callback(body, headers) {
    console.log('Message Callback Fired!');
    console.log('Headers: ' + sys.inspect(headers));
    console.log('Body: ' + body);
}

C:\Wildcards\consumer\node_modules\stomp\lib\stomp.js:299
if (subscription.enabled && subscription.callback !== null && typeof(subscription.callback) == 'function') {
^

TypeError: Cannot read property 'enabled' of undefined
at Stomp.should_run_message_callback (C:\Wildcards\consumer\node_modules\stomp\lib\stomp.js:299:25)
at Stomp.handle_new_frame (C:\Wildcards\consumer\node_modules\stomp\lib\stomp.js:315:22)
at Socket. (C:\Wildcards\consumer\node_modules\stomp\lib\stomp.js:160:19)
at emitOne (events.js:96:13)
at Socket.emit (events.js:188:7)
at readableAddChunk (_stream_readable.js:176:18)
at Socket.Readable.push (_stream_readable.js:134:10)
at TCP.onread (net.js:547:20)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant