You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@qpid.apache.org by "Gordon Sim (JIRA)" <ji...@apache.org> on 2015/04/09 22:35:13 UTC

[jira] [Assigned] (QPID-6484) AccessViolationException when creating queues

     [ https://issues.apache.org/jira/browse/QPID-6484?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Gordon Sim reassigned QPID-6484:
--------------------------------

    Assignee: Gordon Sim

> AccessViolationException when creating queues
> ---------------------------------------------
>
>                 Key: QPID-6484
>                 URL: https://issues.apache.org/jira/browse/QPID-6484
>             Project: Qpid
>          Issue Type: Bug
>          Components: Dot Net Client
>    Affects Versions: 0.32
>         Environment: Windows 8.1
> VS 2013 x86
> .NET wrapped Qpid C++ Client 0.32 with Proton 0.9
> Qpid Java Broker 0.30
> AMQP 1.0
>            Reporter: Enrico Popall
>            Assignee: Gordon Sim
>            Priority: Critical
>
> If the client creates a queue which does not exist on the broker, the Session.createSender/Session.createReceiver method throws an AccessViolationException.
> If the queue exist, the creation of the sender/receiver works like a charm.
> {code:title=csharp.example.client.cs}
> namespace Org.Apache.Qpid.Messaging.Examples {
>     class Client {
>         static int Main(string[] args) {
>             String url = "amqp:tcp:127.0.0.1:5672";
>             String connectionOptions = "{protocol:amqp1.0,sasl_mechanisms:PLAIN,username:guest,password:guest}";
>             if (args.Length > 0)
>                 url = args[0];
>             if (args.Length > 1)
>                 connectionOptions = args[1];
>             Connection connection = new Connection(url, connectionOptions);
>             try
>             {
>                 connection.Open();
>                 Session session = connection.CreateSession();
>                 Sender sender = session.CreateSender("service_queue; {create:always}");
>                 Address responseQueue = new Address("#response-queue; {create:always}");
>                 Receiver receiver = session.CreateReceiver(responseQueue);
>                 String[] s = new String[] {
>                     "Twas brillig, and the slithy toves",
>                     "Did gire and gymble in the wabe.",
>                     "All mimsy were the borogroves,",
>                     "And the mome raths outgrabe."
>                 };
>                 Message request = new Message("");
>                 request.ReplyTo = responseQueue;
>                 for (int i = 0; i < s.Length; i++) {
>                     request.SetContent(s[i]);
>                     sender.Send(request);
>                     Message response = receiver.Fetch();
>                     Console.WriteLine("{0} -> {1}", request.GetContent(), response.GetContent());
>                 }
>                 connection.Close();
>                 return 0;
>             }
>             catch (Exception e)
>             {
>                 Console.WriteLine("Exception {0}.", e);
>                 connection.Close();
>             }
>             return 1;
>         }
>     }
> }{code}
> Stacktrace:
>    bei qpid.messaging.Session.createSender(Session* , Sender* , basic_string<char\,std::char_traits<char>\,std::allocator<char> >* )
>    bei Org.Apache.Qpid.Messaging.Session.CreateSender(String address) in \qpid-0.32\qpid\cpp\bindings\qpid\dotnet\src\session.cpp:Zeile 474.
>    bei Org.Apache.Qpid.Messaging.Examples.Client.Main(String[] args) in \qpid-0.32\qpid\cpp\bindings\qpid\dotnet\examples\csharp.example.client\csharp.example.client.cs:Zeile 43.
>    bei System.AppDomain._nExecuteAssembly(RuntimeAssembly assembly, String[] args)
>    bei System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String[] args)
>    bei Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()
>    bei System.Threading.ThreadHelper.ThreadStart_Context(Object state)
>    bei System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
>    bei System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
>    bei System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
>    bei System.Threading.ThreadHelper.ThreadStart()



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@qpid.apache.org
For additional commands, e-mail: dev-help@qpid.apache.org