activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Timothy Bish (JIRA)" <jira+amq...@apache.org>
Subject [jira] Commented: (AMQNET-143) Calling MessageProducer.Send without destination should throw more specific exception.
Date Wed, 25 Feb 2009 15:27:59 GMT

    [ https://issues.apache.org/activemq/browse/AMQNET-143?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=49985#action_49985
] 

Timothy Bish commented on AMQNET-143:
-------------------------------------

Agreed, there isn't any checking the MessageProducer currently for these conditions.  We should
add an UnsupportedOperationException type to the NMS API package and then perform the checking
in MessageConsumer to comply with the same rules as the JMS spec assign to its MessageProducer.

> Calling MessageProducer.Send without destination should throw more specific exception.
> --------------------------------------------------------------------------------------
>
>                 Key: AMQNET-143
>                 URL: https://issues.apache.org/activemq/browse/AMQNET-143
>             Project: ActiveMQ .Net
>          Issue Type: Bug
>            Reporter: Mark Pollack
>            Assignee: Jim Gomes
>             Fix For: 1.1
>
>
> When sending a message on a messageproducer when the destination has not been set, a
somewhat obscure exception is thrown.  See stack trace below.  Following the JMS spec, (see
the javadocs) an exception of the type    
> UnsupportedOperationException - if a client uses this method with a MessageProducer that
did not specify a destination at creation time.
> InvalidDestinationException - if a client uses this method with a MessageProducer with
an invalid destination. 
> would be much better.
> I am using a build taken from svn on 1/14/2009.
> Apache.NMS.ActiveMQ.BrokerException: java.lang.NullPointerException : 
>    at Apache.NMS.ActiveMQ.Transport.ResponseCorrelator.Request(Command command, TimeSpan
timeout) in d:\Hudson\jobs\Apache.NMS.ActiveMQ Trunk\workspace\src\main\csharp\Transport\ResponseCorrelator.cs:line
105
>    at Apache.NMS.ActiveMQ.Connection.SyncRequest(Command command, TimeSpan requestTimeout)
in d:\Hudson\jobs\Apache.NMS.ActiveMQ Trunk\workspace\src\main\csharp\Connection.cs:line 333
>    at Apache.NMS.ActiveMQ.Session.DoSend(Command message, TimeSpan requestTimeout) in
d:\Hudson\jobs\Apache.NMS.ActiveMQ Trunk\workspace\src\main\csharp\Session.cs:line 478
>    at Apache.NMS.ActiveMQ.MessageProducer.Send(IDestination destination, IMessage message,
Boolean persistent, Byte priority, TimeSpan timeToLive, Boolean specifiedTimeToLive) in d:\Hudson\jobs\Apache.NMS.ActiveMQ
Trunk\workspace\src\main\csharp\MessageProducer.cs:line A first chance exception of type 'System.IO.EndOfStreamException'
occurred in mscorlib.dll
> The thread 0x1e54 has exited with code 0 (0x0).
> The thread 0x5d4 has exited with code 0 (0x0).
> The thread 0x1208 has exited with code 0 (0x0).
> A first chance exception of type 'System.IO.EndOfStreamException' occurred in mscorlib.dll
> The thread 0x1978 has exited with code 0 (0x0).
> The thread 0x1ed4 has exited with code 0 (0x0).
> The thread 0x1ba0 has exited with code 0 (0x0).
> A first chance exception of type 'System.IO.EndOfStreamException' occurred in mscorlib.dll
> The thread 0x1758 has exited with code 0 (0x0).
> 172
>    at Apache.NMS.ActiveMQ.MessageProducer.Send(IMessage message) in d:\Hudson\jobs\Apache.NMS.ActiveMQ
Trunk\workspace\src\main\csharp\MessageProducer.cs:line 120
>    at Spring.NmsQuickStart.Client.Gateways.RequestReplyNmsTemplate.<>c__DisplayClass2.<ConvertAndSendRequestReply>b__0(ISession
session, IMessageProducer producer) in L:\projects\spring-net\trunk\examples\Spring\Spring.NmsQuickStart\src\Spring\Spring.NmsQuickStart.Client\Gateways\RequestReplyNmsTemplate.cs:line
17
>    

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message