activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Hiram Chirino <hi...@hiramchirino.com>
Subject Re: AMQP connector warning
Date Fri, 25 Jan 2013 14:15:34 GMT
That error occurred because the destination address was not set.  If you
use a amqp url of
'amqp://zhigang1/myqueue' then it should work.  I'll try to update the code
to handle this error condition more gracefully and provide a better error
message.


On Fri, Jan 25, 2013 at 9:01 AM, Zhigang Wang <w1z2g3@gmail.com> wrote:

> Paste it again (send.py):
>
> Run it: ./send.py hi
>
>
> #!/usr/bin/env python
>
> import optparse
> import proton
> import sys
>
>
> def main():
>     parser = optparse.OptionParser('%prog [OPTS] MESSAGE')
>     parser.add_option('-a', '--address', default='amqp://zhigang1',
>                       help='adress:
> [amqp[s]://][user[:password]@]domain[/[name]]')
>     parser.add_option('-s', '--subject', default='foo.bar',
>                       help='subject')
>     opts, args = parser.parse_args()
>     if not args:
>         parser.print_help()
>         sys.exit(1)
>
>     messenger = proton.Messenger()
>     messenger.start()
>     msg = proton.Message()
>     msg.address = opts.address
>     msg.subject = opts.subject
>     content = ' '.join(args)
>     msg.body = unicode(content)
>     messenger.put(msg)
>     messenger.send()
>     messenger.stop()
>
>
> if __name__ == '__main__':
>     main()
>
>
> On Fri, Jan 25, 2013 at 8:10 AM, Hiram Chirino <hiram@hiramchirino.com
> >wrote:
>
> > Hi Zhigang,
> >
> > Do you have the a script that can reproduce that error?
> >
> >
> > On Thu, Jan 24, 2013 at 4:18 PM, Zhigang Wang <w1z2g3@gmail.com> wrote:
> >
> > > It seem worse now for today's snapshot:
> > >
> > > INFO   | jvm 1    | 2013/01/24 16:14:13 |
> > > org.apache.activemq.transport.amqp.AmqpProtocolException: Could not
> > process
> > > AMQP commands
> > > INFO   | jvm 1    | 2013/01/24 16:14:13 |       at
> > >
> > >
> >
> org.apache.activemq.transport.amqp.AmqpProtocolConverter.onFrame(AmqpProtocolConverter.java:245)
> > > INFO   | jvm 1    | 2013/01/24 16:14:13 |       at
> > >
> > >
> >
> org.apache.activemq.transport.amqp.AmqpProtocolConverter.onAMQPData(AmqpProtocolConverter.java:151)
> > > INFO   | jvm 1    | 2013/01/24 16:14:13 |       at
> > >
> > >
> >
> org.apache.activemq.transport.amqp.AmqpTransportFilter.onCommand(AmqpTransportFilter.java:94)
> > > INFO   | jvm 1    | 2013/01/24 16:14:13 |       at
> > >
> > >
> >
> org.apache.activemq.transport.TransportSupport.doConsume(TransportSupport.java:83)
> > > INFO   | jvm 1    | 2013/01/24 16:14:13 |       at
> > >
> >
> org.apache.activemq.transport.tcp.TcpTransport.doRun(TcpTransport.java:214)
> > > INFO   | jvm 1    | 2013/01/24 16:14:13 |       at
> > >
> org.apache.activemq.transport.tcp.TcpTransport.run(TcpTransport.java:196)
> > > INFO   | jvm 1    | 2013/01/24 16:14:13 |       at
> > > java.lang.Thread.run(Unknown Source)
> > > INFO   | jvm 1    | 2013/01/24 16:14:13 | Caused by:
> > > java.lang.NullPointerException
> > > INFO   | jvm 1    | 2013/01/24 16:14:13 |       at
> > >
> > >
> >
> org.apache.activemq.command.ActiveMQDestination.createDestination(ActiveMQDestination.java:93)
> > > INFO   | jvm 1    | 2013/01/24 16:14:13 |       at
> > >
> > >
> >
> org.apache.activemq.transport.amqp.AmqpProtocolConverter.createDestination(AmqpProtocolConverter.java:636)
> > > INFO   | jvm 1    | 2013/01/24 16:14:13 |       at
> > >
> > >
> >
> org.apache.activemq.transport.amqp.AmqpProtocolConverter.onReceiverOpen(AmqpProtocolConverter.java:601)
> > > INFO   | jvm 1    | 2013/01/24 16:14:13 |       at
> > >
> > >
> >
> org.apache.activemq.transport.amqp.AmqpProtocolConverter.onLinkOpen(AmqpProtocolConverter.java:380)
> > > INFO   | jvm 1    | 2013/01/24 16:14:13 |       at
> > >
> > >
> >
> org.apache.activemq.transport.amqp.AmqpProtocolConverter.onFrame(AmqpProtocolConverter.java:207)
> > > INFO   | jvm 1    | 2013/01/24 16:14:13 |       ... 6 more
> > >
> > > Please have a look.
> > >
> > > Thanks,
> > >
> > > Zhigang
> > >
> > >
> > > On Wed, Jan 23, 2013 at 12:40 PM, Zhigang Wang <w1z2g3@gmail.com>
> wrote:
> > >
> > > > Thank you for your quick fix. I will test it later.
> > > >
> > > > Zhigang
> > > >
> > > >
> > > > On Wed, Jan 23, 2013 at 11:38 AM, Hiram Chirino <
> > hiram@hiramchirino.com
> > > >wrote:
> > > >
> > > >> Yep. your script looks good.  I found a problem /w how the AMQP impl
> > was
> > > >> handling the socket disconnect.  I've now committed a fix for that.
> >  If
> > > >> you
> > > >> try a fresh build those messages should go away.  Thanks for the
> > report!
> > > >>
> > > >>
> > > >> On Wed, Jan 23, 2013 at 9:21 AM, Zhigang Wang <w1z2g3@gmail.com>
> > wrote:
> > > >>
> > > >> > Here it is:
> > > >> >
> > > >> > #!/usr/bin/env python
> > > >> >
> > > >> >
> > > >> --
> > > >>
> > > >> **
> > > >>
> > > >> *Hiram Chirino*
> > > >>
> > > >> *Engineering | Red Hat, Inc.*
> > > >>
> > > >> *hchirino@redhat.com <hchirino@redhat.com> | fusesource.com
|
> > > redhat.com*
> > > >>
> > > >> *skype: hiramchirino | twitter: @hiramchirino<
> > > >> http://twitter.com/hiramchirino>
> > > >> *
> > > >>
> > > >> *blog: Hiram Chirino's Bit Mojo <http://hiramchirino.com/blog/>*
> > > >>
> > > >
> > > >
> > >
> >
> >
> >
> > --
> >
> > **
> >
> > *Hiram Chirino*
> >
> > *Engineering | Red Hat, Inc.*
> >
> > *hchirino@redhat.com <hchirino@redhat.com> | fusesource.com | redhat.com
> *
> >
> > *skype: hiramchirino | twitter: @hiramchirino<
> > http://twitter.com/hiramchirino>
> > *
> >
> > *blog: Hiram Chirino's Bit Mojo <http://hiramchirino.com/blog/>*
> >
>



-- 

**

*Hiram Chirino*

*Engineering | Red Hat, Inc.*

*hchirino@redhat.com <hchirino@redhat.com> | fusesource.com | redhat.com*

*skype: hiramchirino | twitter: @hiramchirino<http://twitter.com/hiramchirino>
*

*blog: Hiram Chirino's Bit Mojo <http://hiramchirino.com/blog/>*

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message