0xcodezero / activemessaging

Automatically exported from code.google.com/p/activemessaging
0 stars 0 forks source link

Deprecation warning from Stomp library/adapter #54

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Was receiving deprecation warning for "send" method, staging it was being 
deprecated in favor of the "publish" method. A quick fix to silence the warning 
is to add the following method to activemessaging/adapters/stomp.rb within the 
Connection class:

def send( *args )
  publish( *args )
end

Original issue reported on code.google.com by nge...@gmail.com on 15 Jul 2010 at 8:51

GoogleCodeExporter commented 9 years ago
LOL - That should have read:

"Was receiving deprecation warnings for "send" method, staging it was being 
deprecated in favor of the "publish" method."

Original comment by nge...@gmail.com on 15 Jul 2010 at 9:49

GoogleCodeExporter commented 9 years ago
This will support both older and the newer stomp libraries:

def send( *args )
  return ( self.respond_to?( :publish ) ? publish( *args ) : super( *args ) )
end

Original comment by nge...@gmail.com on 16 Jul 2010 at 9:26