jms

Spring DefaultMessageListenerContainer, ActiveMQ and message redelivery

Hi, if I use the DefaultMessageListenerContainer of Spring to recieve JMS messages, I don't get JMS messages redelivered, even if I set sessionAcknowledgeMode to 2. In case of a RuntimeException within the onMessage() of my JavaBean, the message is not acknowledged within the JMS provider (ActiveMQ), it stays as pending in the queue. B...

How to print PDFs automatically

We have a number of systems that produce PDFs that need to be printed. These are stored on a central document store. A message then goes onto a JMS queue that the document needs printing. A service, written in Java , picks these up and then invokes a native command. This is to call Adobe Reader with the /t flag. This causes the docu...

MantaRay JMS: event ID 4226. TCP connect timeout?

I have a problem with MantaRay JMS: I use a static world map because autodiscovery wouldn't work in our network. If more than 10 peers are offline, I get an error 4226. The problem is: Microsoft set a limit of 10 half-open connections with Windows XP SP2. MantaRay tries to contact every peer, and starts a lot of connections. The first 1...

How to list available destinations/topics in a SonicMQ environment

I am trying to write a test utility to list out the various items within the SonicMQ environments I connect to. I have been able to list out a number of items, including brokers, containers, and queues, but topics continue to elude me. I have searched through the API doc and played around a bit in code to no avail. Is there a way to l...

Always ensure only last 10 messages in ActiveMQ Topic.

We have an issue in ActiveMQ where we have a huge number of messages not dropping off topics. The topics are set to non-persistent, non-durable. Our Activemq.xml file is <beans> <broker xmlns="http://activemq.apache.org/schema/core" useJmx="false" persistent="false"> <!-- <persistenceAdapter> <journaledJDBC journalLogFile...

When to shut down message processing in case of queue / database failure?

This is more of a best practice question for the common case of an application receiving messages, persisting them to a database, and possibly sending messages as a result. Assume transactionality sorts out atomic commit; what is a good policy on when to shut the application down altogether? If the database fails, the application could...

how to receive data from different datasources and transmit them through JMS

The project is required to receive lot of data(the possible historical weather data of one State) from different datasources, like zip files, data files within a website. The data format is not clear, the files might be txt, pdf, or .xml. Since it specifies that JMS and JPA should be used for implementation, I am thinking use JMS Object...

Unable to deque messages from Topic after the listener listens the messages in spring jms

I am sending the messages to Topic using oracle.jms.AQjmsFactory. The messages are stored in DB topic . Using DefaultMessageListenerContainer , the messages are being listen .But the problem is the messages are not dequeueing or deleting from the topic i.e., the messages are stucked in topic. ...

JMS for email scalability

Does it make sense to use JMS and JavaMail together to build a scalable email solution? Presently these are the 2 options I am considering: -- Build a RESTful email center API and call it from all over the web app. -- Use JMS in between the web app and the email center. The 'email center' as I call it will probably be implemented us...

Delaying JMS messages in queue when starting JBoss

Is there a way to tell JMS in JBoss to delay processing of messages already in the persistent queue for a while, e.g. 2 minutes, while JBoss starts. As it is right now, when we restart JBoss, JMS starts to dispatch messages to the MessagesListeners even before JBoss has started properly. We're running JBoss 4.2.3 ...

TextMessage received from Oracle AQ using JMS contains just '???'

I need to connect to two Oracle AQ queues in different databases. I'm using exactly similar code in both cases, except for the connection string of course. One of the queues is working fine, but the second one not. String db_string = "jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=x.y.z.2)(PORT=1521))(ADDRESS=...

How to handle order of messages in JMS

I am reviewing a client server application written in java. The server receives JMS messages and processes them but the messages can come in unexpected order, a cancel can arrive before an order message. How do you handle such a case? Do you do it in the mdb? Any strategies or patterns for this kind of scenario? Thanks FF ...

Why would createTopicConnection take 450 seconds to complete - every other time?

We have a weblogic application talking to another weblogic application on another server. We use JMS for communication between them. We're seeing odd behaviour where createTopicConnection takes 450 seconds (pretty accurately, so 7.5 minuutes) to complete one time, but the next time it will complete quickly, the time after 450 seconds ag...

JMS consumer with ActiveMQ network of brokers

I have a JMS topic on an ActiveMQ network of brokers cluster (aka distributed topic). I have an external JMS consumer (Weblogic portal) that needs to subscribe to this topic and get all the messages sent to it (across all brokers). If the consumer subscribes to the topic on one of the brokers, it will only get the subset of the message...

Is JMS QueueSender is thread safe ?

Dear all, I am new to JMS API , I want to try QueueSender in multi-thread environment.... So, the question .. Is QueueSender.send() thread safe ?please provide reference or demo if available thanks in advance,,,, ...

What do I need to realize notification using JMS?

I just need notification system. javax.jms.* - good solution I think, but I can't understand what do I need to use JMS? I don't want to use any app. servers like GlassFish or Tomcat, I just would like to use standard jdk and myserver(very light) and myclient(very light too) and some MessageSystem to exchanging bitween myserver and myclie...

Using JMS as a distributed lock manager?

I have a system where some loosely coupled components are communicating by exchanging messages over JMS. I am now looking at a new requirement which leads to some shared resource needing protection from access by two or more components at the same time (more or less an instance of the reader/write problem). I am looking for a way to coor...

can JMS used in Java Swing App

I need to design a Swing application, which will need to send out multiple jobs as customer requested. each job is running the same shell scripts which will take 10-30 mins to return a value. (the jobs are not running on application server or as web services. )then the Swing application will need to decide what to do next according to th...

How do I get my MDB to ignore messages coming from itself?

I have a few clients that are both consumers and subscribers to a single topic on an ActiveMQ message broker. All the clients share the same code, they are in fact using exactly the same Enterprise Application consisting of: (1) an EJB producing a message, and (2) an MDB consuming the message. The problem is basically that if I have c...

jms unresolved message-destination-ref

hi, I am using netbeans 6.8, and glassfish v3, and making a simple jms application to work. I got this: com.sun.enterprise.container.common.spi.util.InjectionException: Exception attempting to inject Unresolved Message-Destination-Ref jms/[email protected]@null into class enterpriseapplication4.Main Code: public class Main ...