I m using the faye-rails gem in my application. I want to save all messages i receive in a channel. I tried using the map function in my routes to map a channel to a controller and did monitor :publish for the channel.
faye_server '/faye', :timeout => 25 do
map '/messages/public' => ChatLogController
map :default => :block
end
and this is my ChatLogController:
class WidgetController < FayeRails::Controller
channel '/public/messages' do
monitor :publish do puts "i am in the monitor block"
end end
But i am not getting "i am in the monitor block" printed in the log. What am i doing wrong? pls help me.