Closed rtyler closed 10 years ago
Yep - noticed the same thing. The latest version of the gem seems to rely on the presence of a Slogger
to get much information to bubble out to the caller. I don't like that approach.
I have a number of local patches to the latest gem that I can share with you if you're interested.
One in particular includes handling ERROR frames, parsing their content and turning them into higher level exceptions that are invoked on the caller's thread, etc. I've trolled the entirety of the ActiveMQ codebase to come up with the list of all ResourceAllocationException's that can make their way back to the client. If you're using a different broker you can just replace the regexs with ones of your choosing.
Let me know.
@ppaul Any particular reason you've not submitted pull requests for those patches you've got backlogged? I'd like to see them in that form, or at least in a forked repo
Any particular reason you've not submitted pull requests for those patches you've got backlogged?
Mainly because I no longer have an appetite for dealing with the current maintainers with whom one has to battle tirelessly in order to get something accepted.
My patches are just a stop gap until I either write a stomp gem myself (which I don't really have time for) or start using another protocol.
@ppaul I'd also be interested in seeing those patches. (@rtyler and I work together, so I'll see 'em anyway if you send them to him.) And I have recently acquired bits on this repo, so if the problem is just lack of maintainer time/responsiveness, uh ... reiterates mention of a pull request
The inability of a Stomp::Client to receive async. ERROR frames from the broker is indeed a flaw. Been there since day 1 it seems.
A fix is on the todo list.
As requested, here is a Gist containing my local changes. The large comment block at the top details the changes, their rationale, as well as guidance to our developers regarding their use.
They were tested against ActiveMQ 5.8.0 only, using my local client tester, on both JRuby 1.7.3 and rubyee_1.8.7.
YMMV. Bug reports welcome.
Thanks, Paul
@ppaul The error logging parts of that gist are in https://github.com/ismith/stomp/tree/error_logging, they just lack unit tests. If you have some to share, please do, otherwise, I'm going to work on writing some.
Go for it
On Tue, Sep 24, 2013 at 4:33 PM, Ian Smith notifications@github.com wrote:
@ppaul https://github.com/ppaul The error logging parts of that gist are in https://github.com/ismith/stomp/tree/error_logging, they just lack unit tests. If you have some to share, please do, otherwise, I'm going to work on writing some.
— Reply to this email directly or view it on GitHubhttps://github.com/stompgem/stomp/issues/73#issuecomment-25039917 .
Resolved as pull req #81, will be releasing shortly with this change.
When performing some load testing, we configured really low memory/disk usage for ActiveMQ, e.g.:
Note the
sendFailIfNoSpace
.What ends up happening if the broker cannot receive messages is that the
Stomp::Client#publish
call continues to "succeed" (not block at least) and eventually the following is printed to$stderr
:I think the Stomp::Client should have some means of expressing an error from the server, but I'm not sure how it should be expressed