nms

Connection closes after few seconds when connecting to ActiveMQ set up on AWS

久未见 提交于 2020-01-06 06:05:44
问题 I am connecting to Apache Active MQ which is hosted on AWS to integrate my app to a custom service. I need to keep this running always, not one time like it's right now. The code below works, but only for one message, I need to maintain the connection active all the time listening in order to receive all the messages. Here is the code. using Apache.NMS; using Apache.NMS.Util; using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading; using

Can I delete a message from a queue of ActiveMQ in c# code?

ぃ、小莉子 提交于 2019-12-25 01:59:04
问题 I want to set a unique guid for each message in message head, then if I want, I could delete a specific message if I want to. Is there any api in NMS could help me deleting the message? I am using ActiveMQ 5.9.0 and NMS 1.6.1 回答1: Yes, although only if that destination has no active consumers. You can do something like this: protected static void DeleteDestination() { IConnectionFactory factory = new ConnectionFactory(ReplaceEnvVar(connectionURI)); using (Connection connection = factory

ActiveMQ: Publish Messages in bulk, persistent, but not async?

北慕城南 提交于 2019-12-24 10:04:52
问题 is it possible to store a large amount of messages in bulk? I want to send them sync, persistent, but to get speed very much at one time. I am using NMS, the .net version of the java-framework. But if you only know how to do this in java, it would even help. Maybe I can find a solution for .net more easier. I thought of things like transactions. But I only got transactions to work for consumers, not for producers. 回答1: Conventional wisdom used to suggest that if you wanted maximum throughput

How to monitor Apache Artemis

倾然丶 夕夏残阳落幕 提交于 2019-12-18 12:07:17
问题 I'm doing some testing with RabbitMQ, ActiveMQ and Apache Artemis in a Windows .NET environment. RabbitMQ and ActiveMQ ship with a web interface where you can see information about your broker, queues, messages etc. but Artemis does not. I really want to be able to monitor my Artemis broker in a web interface or at the very least with some cmd/PowerShell commands. I've read on this page about some third-party tools that can be used to monitor an ActiveMQ instance and I assumed that it also

Apache.NMS.ActiveMQ client hang when connection has been broken

穿精又带淫゛_ 提交于 2019-12-11 14:33:09
问题 Our client connects to cluster with 2 ActiveMQ nodes. Apache.NMS.ActiveMQ library hang when we drop network connection manually between client and cluster. We use Apache.NMS.ActiveMQ with version 1.7.2 and cluster based on ActiveMQ 5.15.3. Connection URI is: failover:(tcp://dd-amq-app01:61616,tcp://dd-amq-app02:61616)?transport.maxReconnectAttempts=0&transport.startupMaxReconnectAttempts=0&transport.useExponentialBackOff=false&transport.maxReconnectDelay=1000&transport.timeout=10000 I expect

How do I set the prefetch limit for NMS listener container

[亡魂溺海] 提交于 2019-12-11 12:59:54
问题 Other than on the connection URL, how do I set the prefetch limit in spring config. I can't find any doc on any of the properties and the param on the Connection URL doesn't seem to work. Besides, I need to do this on the consumer level. Here is my config below. <nms:listener-container connection-factory="SingleConnectionFactory" concurrency="${GraphManagerService.NMS.Consumers}" auto-startup="false"> <nms:listener ref="MessageListenerAdapter" destination="${GraphManagerService.NMS.QueueName}

ActiveMQ Exception when trying to work with SSL

岁酱吖の 提交于 2019-12-11 08:15:05
问题 I'm trying to send secure messages over SSL with ActiveMQ, using the Apache NMS API for .NET. In the broker.xml I tried adding "sslEnabled=true" to the default acceptor: <acceptor name="artemis">tcp://0.0.0.0:61616?sslEnabled=true;tcpSendBufferSize=1048576;tcpReceiveBufferSize=1048576;protocols=CORE,AMQP,STOMP,HORNETQ,MQTT,OPENWIRE;useEpoll=true;amqpCredits=1000;amqpLowCredits=300</acceptor> I'm trying to set up a consumer like this: IConnectionFactory factory = new ConnectionFactory(

ActiveMQ - Sending a message to a temporary queue specified using a string (NMS in C#)

↘锁芯ラ 提交于 2019-12-10 21:15:55
问题 I have a synchronous message transaction within my system, and the process broadly follows this flow: "Point A" creates a temporary queue ("destination 2") on the message broker; Message sent from point A to destination 1 (a normal queue on the message broker), with the ReplyTo address set as destination 2; point A blocks waiting for response on destination 2; point B receives message from destination 1; point B creates a work object - a property of which is the name of destination 2 (derived

What serialization method is used for an ActiveMQ NMS C# object message?

╄→гoц情女王★ 提交于 2019-12-08 01:32:35
问题 I'm planning on using Apache NMS for ActiveMQ messaging, and am wondering what serialization method is going to be used on the objects I send? XML/Binary? What controls the serialization and how can I customize it? Does anyone have experience doing this with C# objects? Are there any pitfalls that you know of? 回答1: The default is System.Runtime.Serialization.Formatters.Binary.BinaryFormatter for IObjectMessage. You can set your own by e.g. IObjectMessage m = session.CreateObjectMessage(); (