Hi all, I'm working on a hobby project of mine where I need to use RabbitMQ. I couldn't find any "standard" way of using it in Catalyst so I made the attached module Catalyst::Model::RabbitMQ.
I can then have a simple model: package MyApp::Model::MQ; use Moose; use namespace::autoclean; extends 'Catalyst::Model::RabbitMQ'; __PACKAGE__->config( queue_names => [ qw/user_changes/ ], default_routing_key => 'user_changes', ); And publish messages in my controllers like this: $c->model('MQ')->publish ("", "user_changes", "sent from catalyst"); $c->model('MQ')->publish (undef, undef, "sent from catalyst without key"); # using default_routing_key Is there already a better way of doing this? Should I add some documentation and try to get it to CPAN or should I just use someone else's already more complete and robust way of sending messages? /Jon
RabbitMQ.pm
Description: Binary data
_______________________________________________ List: Catalyst@lists.scsys.co.uk Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/ Dev site: http://dev.catalyst.perl.org/