Consume JMS mesages in a batch

Hi All,
I want to consume JMS messges in a batch. Assume I have 100 messages in a queue, and i want to consume 25 messages first and execute the flow. Then i should pick another 25 messages and so on. Is there a way to achieve this? Please do let me know.
Regards,
Maanik.

Hi,
You have to create a work manager with its setting like min thread=1 and max thread=25 and refer that work manager in your queue.
Second, you are never going to achieve 25 or 50 messages in bulk/batch. It will come one by one as jms queue means first in last out. setting it max thread=25, it will lead to processing of 25 concurrent messages.
Rgrds

Similar Messages

  • OSB: Proxy doesn't consume JMS messages

    Guys, I'm getting stuck with this one ...
    I've got four JMS proxy services. One of them uses Publish to enqueue a message into the three others. This way I get three copies of a single message, each in dedicated JMS queue. The same three JMS proxies are supposed to consume messages from JMS queues and process them. The configuration is the same for all three proxies and all three JMS queues. In fact all was cloned and the difference is only in suffix. So, I've got QueueA, QueueB, QueueC and ProxyA, ProxyB and ProxyC. So if I stick to these names, ProxyMain uses 3x Publish actions to enqueue a message into ProxyA, ProxyB and ProxyC at the same time. This is a proved solution and it has worked for years flawlessly!
    However, something weird happened a couple of days ago. All of a sudden, one of those three consuming JMS proxies doesn't consume anything. There's no issue on producing side (the first proxy) as the numbers of messages in all three queues are still increasing. Still, only messages from QueueA and QueueB are being consumed by ProxyA and ProxyB. The third queue (QueueC) doesn't have any consumer attached from ProxyC and I don't know why.
    I've already checked everything I know - proxy is enabled, there are no errors in logs related to the proxy or JMS, the issue is not reproducible in test environment with the same configuration, there are no JMS Quota or connection factory restrictions, consuming flag is enabled on queue ...
    The lack of errors in logs makes me feel like the ProxyC is connected to something else. However, the same proxy is used for producing messages (from ProxyMain) and messages are incoming to the queue so the endpoint set in proxy must be correct!
    Any help, hint or idea is appreciated ...

    The third queue (QueueC) doesn't have any consumer attached from ProxyC and I don't know whyTry renaming ProxyC to say ProxyC1 and activate the session. This will create a new underlying MDB for the jms proxy and you will see consumers getting set on the queue.. Faced this issue many times in our production environment and easiest workaround we found was to rename the proxy service [ toggling enable/disable proxy doesn't seem to have ny effect).. you can change the name to the original proxy once the consumers are set..                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • MDBs in 9.1 continue to consume JMS queues even after being deleted

    <b>We have an MDB application that reads a batch message off of a JMS queue, archives it in a database, parses the batch message into individual messages and writes them onto other JMS queues to be consumed by another application. Everything was running fine in Weblogic 8.1.5. However, due to problems with XA drivers and the MSDTC(predictable SQL server crashes), we decided to upgrade to Weblogic 9.1 to take advantage of the LLR option.</b>
              <b>First, we had an issue where our MDBs were causing the following exception:</b>
              <i>####<May 26, 2006 7:42:12 PM EDT> <Error> <JMX> <ist-clft2> <wltest1> <ExecuteThread: '1' for queue: 'default'> <<WLS Kernel>> <> <> <1148686932991> <BEA-149500> <An exception occurred while registering the MBean null.
              java.lang.IllegalArgumentException: Registered more than one instance with the same objectName : com.bea:ServerRuntime=wltest1,MessageDrivenEJBRuntime=RhapsodyMDB_DMBModule!JMSServer4@DMB_BEAN_QUEUE,Name=RhapsodyMDB_DMBModule!JMSServer4@DMB_BEAN_QUEUE,ApplicationRuntime=DataBrokerEAR1_2,Type=EJBPoolRuntime,EJBComponentRuntime=DataBrokerEJB new:[email protected] existing weblogic.ejb.container.monitoring.EJBPoolRuntimeMBeanImpl@7db003
                   at weblogic.management.jmx.ObjectNameManagerBase.registerObject(ObjectNameManagerBase.java:146)
                   at weblogic.management.mbeanservers.internal.WLSObjectNameManager.lookupObjectName(WLSObjectNameManager.java:133)
                   at weblogic.management.jmx.modelmbean.WLSModelMBeanFactory.registerWLSModelMBean(WLSModelMBeanFactory.java:86)
                   at weblogic.management.mbeanservers.internal.RuntimeMBeanAgent$1.registered(RuntimeMBeanAgent.java:104)
                   at weblogic.management.provider.internal.RegistrationManagerImpl.invokeRegistrationHandlers(RegistrationManagerImpl.java:205)
                   at weblogic.management.provider.internal.RegistrationManagerImpl.register(RegistrationManagerImpl.java:85)
                   at weblogic.management.runtime.RuntimeMBeanDelegate.register(RuntimeMBeanDelegate.java:320)
                   at weblogic.management.runtime.RuntimeMBeanDelegate.<init>(RuntimeMBeanDelegate.java:257)
                   at weblogic.management.runtime.RuntimeMBeanDelegate.<init>(RuntimeMBeanDelegate.java:222)
                   at weblogic.ejb.container.monitoring.EJBPoolRuntimeMBeanImpl.<init>(EJBPoolRuntimeMBeanImpl.java:32)
                   at weblogic.ejb.container.monitoring.MessageDrivenEJBRuntimeMBeanImpl.<init>(MessageDrivenEJBRuntimeMBeanImpl.java:49)
                   at weblogic.ejb.container.manager.MessageDrivenManager.initialize(MessageDrivenManager.java:503)
                   at weblogic.ejb.container.manager.MessageDrivenManager.setup(MessageDrivenManager.java:120)
                   at weblogic.ejb.container.manager.MessageDrivenManager.setup(MessageDrivenManager.java:146)
                   at weblogic.ejb.container.deployer.MessageDrivenBeanInfoImpl.createMDManager(MessageDrivenBeanInfoImpl.java:1481)
                   at weblogic.ejb.container.deployer.MessageDrivenBeanInfoImpl.createDDMDManagers(MessageDrivenBeanInfoImpl.java:1378)
                   at weblogic.ejb.container.deployer.MessageDrivenBeanInfoImpl.onDDMembershipChange(MessageDrivenBeanInfoImpl.java:1285)
                   at weblogic.jms.common.CDS$DD2Listener.listChange(CDS.java:454)
                   at weblogic.jms.common.CDSServer$DDHandlerChangeListener.statusChangeNotification(CDSServer.java:167)
                   at weblogic.jms.dd.DDHandler.callListener(DDHandler.java:318)
                   at weblogic.jms.dd.DDHandler.callListeners(DDHandler.java:344)
                   at weblogic.jms.dd.DDHandler.run(DDHandler.java:282)
                   at weblogic.jms.common.SerialScheduler.run(SerialScheduler.java:37)
                   at weblogic.work.ExecuteRequestAdapter.execute(ExecuteRequestAdapter.java:21)
                   at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:145)
                   at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:117)
              >
              ####<May 26, 2006 7:42:13 PM EDT> <Info> <EJB> <ist-clft2> <wltest1> <ExecuteThread: '1' for queue: 'default'> <<WLS Kernel>> <> <> <1148686933069> <BEA-010060> <The Message-Driven EJB: RhapsodyMDB has connected/reconnected to the JMS destination: weblogic.jms.DMB_BEAN_QUEUE.></i>
              <b>
              Generally this happend after there were cluster communication issues. Multi-cast messages were lost and our MDB reconnects to the JMS queues as indicated by the below log:</b>
              <i>####<May 30, 2006 5:19:06 PM EDT> <Info> <EJB> <AMTC-RAP-STG3> <RAPBEA1S> <[ACTIVE] ExecuteThread: '54' for queue: 'weblogic.kernel.Default (self-tuning)'> <<anonymous>> <> <> <1149023946040> <BEA-010060> <The Message-Driven EJB: DataBrokerMDB has connected/reconnected to the JMS destination: weblogic.jms.PHINMS_DMB_QUEUE.>
              ####<May 30, 2006 5:19:10 PM EDT> <Info> <Cluster> <AMTC-RAP-STG3> <RAPBEA1S> <[ACTIVE] ExecuteThread: '22' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1149023950228> <BEA-000112> <Removing RAPBEA3S jvmid:720875810499147484S:cmts-rap-bea3:[7005,-1,-1,-1,-1,-1,-1]:DMBstg:RAPBEA3S from cluster view due to timeout.>
              ####<May 30, 2006 5:19:11 PM EDT> <Info> <Cluster> <AMTC-RAP-STG3> <RAPBEA1S> <[STANDBY] ExecuteThread: '1' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1149023951009> <BEA-000115> <Lost 2 multicast message(s).>
              ####<May 30, 2006 5:19:11 PM EDT> <Info> <Cluster> <AMTC-RAP-STG3> <RAPBEA1S> <[ACTIVE] ExecuteThread: '22' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1149023951040> <BEA-000111> <Adding RAPBEA3S with ID 720875810499147484S:cmts-rap-bea3:[7005,-1,-1,-1,-1,-1,-1]:DMBstg:RAPBEA3S to cluster: DMBstg_cluster view.></i>
              <b>
              This would cause the queues to eventually have hundreds of consumers and cause the server to fail.
              Basically, it seems as though the MDBs that are supposed to stop continue and attempt to process, while new threads connect to the JMS queues.
              I tried undeploying our application and deleted it from the configuration. However there were consumers still on the respective queues and when I sent messages, I got an error indicating a "Class Not Found exception" due to the fact that the EJB was undeployed and deleted from the configuration, however the MDB component was not and continued to listen for messages. In 8.1.5, as soon as the application was undeployed, there were zero consumers on the JMS queues.
              I have read the posts about a soon to be released fix that would have the MDBs connect only to the queues locally and not go out the the cluster. Would this fix my issue?
              Is there something in the deployment descriptor to configure that will cause it to disconnect and now spawn so many consumers to the JMS queues?
              Why is it that the number of MDB consumers on the JMS queues stayed static in 8.1.5, but they are erratic in 9.1 even after I set our 9.1 server to use the 8.1.5 execute queue policy. Help would be much appreciated.</b>

    I recommend contacting customer support. There's a known problem with MDBs listening to distributed destinations that are local to the same cluster as the MDB, you're problem may be related (the clue is that the stack trace contains jms.dd.DDHandler.callListeners()). The problem is that the MDB connects to all physical queues in a distributed destination rather than just the local queue.
              Tom

  • Invoke Error while inserting consumed JMS Topic msg in table thru DBadapter

    Hi All,
    To brief abt my requirement, I am integrating Peoplesoft HRMS module with Oracle SOA i.e.,
    +
    1. PS HRMS module will publish a JMS msg into a JMS Topic
    2. I will consume the same msg using JMS adapter consume operation in my SOA project
    3. The Payload(msg) is coming into RECEIVE activity and thru ASSIGN activity invoking the DB adapter to insert the msg into a table.
    4. INVOKE activity is throwing the below error(along with the error, able to see the payload in INVOKE activity )
    <part name="summary"> +
    <summary>*Exception occured when binding was invoked. Exception occured during invocation of JCA binding: "JCA Binding execute of Reference operation 'insert' failed due to: Mapping Not Found Exception. The mapping [EMPLID] for descriptor [class insert.Employee] could not be found. The input xml record had an element [Employee/EMPLID]. Most likely the wrong xml input variable (not matching the expected xsd) was passed to this invoke. Make sure that the input xml is valid relative to the xsd and that the mapping exists in the Mappings.xml. If an old version of the descriptor without this mapping has been loaded by the database adapter, you may need to bounce the app server. If the same descriptor is described in two separate Mappings.xml files, make sure both versions include this attribute/mapping. ". The invoked JCA adapter raised a resource exception. Please examine the above error message carefully to determine a resolution. *</summary>
    </part>
    Please, provide some suggestions.
    Regards,
    Satya

    Hi Satya,
    Try replacing the Assign activity with a Transform acitivity.
    Also please check the schema that comes of the DB adapter is having the similar sort of definition that you are getting in your input.
    What I mean is to check for length of fields, type of the fields etc.
    Thanks,
    Deepak.
    Edited by: DeepakDabbiru on Oct 23, 2012 3:29 AM

  • Consume JMS Unit-Of-Work message through OSB proxy service

    Hi,
    Anyone know how to consume a JMS Unit-Of-Work (UOW) message using an OSB Proxy Service of JMS type?
    I can submit a unit-of-work JMS message (which consists of multiple constituent messages) using an OSB proxy & business service combination and setting the UOW transport headers appropriately. I can also separately produce and consume Java objects via a JMS queue where the consumption is done via OSB proxy (of java request message type), but these aren't UOW messages.
    Apparently as soon as it is a UOW message then the message consumed is an ObjectMessage ArrayList and one has to use the "Java" request message type for the JMS consumer proxy, but I'm unsure of how to create the concurrent client jar to use it in the same proxy service's JMS transport configuration in order to output the ObjectMessage ArrayList (UOW message). 
    Ideally I'd like to consume a single UOW XML message via an OSB JMS proxy service.
    Any pointers would be appreciated.
    R

    Finally got this working!!
    For posterity: Needed to insert Java Object JMS messages on the OSB JMS producer (Business Service) side with correct UOW jms transport header set in route node. Then consume the Unit-Of-Work message on the other side via jms proxy service with "java" request message type, with appropriate jar containing the Object class as the "Client jar" in the JMS Transport configuration. In the same JMS consumer proxy I had to do a java callout, passing the contents of $body, using java.util.ArrayList and javax.jms.ObjectMessage, as input into a method (.. decodeJavaMessage(ArrayList<ObjectMessage> ...)). In this java callout class you can get to each individual ObjectMessage via typecasting the get() method on the Arraylist to (ObjectMessage) and then just typecast the getObject() on this Objectmessage into your original Java Class (same as what you inserted onto queue originally).
    Hope this saves someone some time in future!

  • Not able to consume JMS Q by standalone App

    We are making use JMS Q to store the request and build another standalone job to consume it. But some time how our standalone app not able to retrieve message from Q and we need to restart the app many times then it will working fine. Do you have any idea of it? Should we update any weblogic patch?

    There are no errors /exceptions. The project is deployed, since it is a JMS adapter with consume operation it should poll the queue and get the message if it is available.
    This is the *.jca file for adapter.
    <adapter-config name="psoftconsume" adapter="Jms Adapter" wsdlLocation="psoftconsume.wsdl" xmlns="http://platform.integration.oracle/blocks/adapter/fw/metadata">
    <connection-factory location="eis/JMS/RemoteQueue" UIConnectionName="remotewls" UIJmsProvider="WLSJMS" adapterRef=""/>
    <endpoint-activation portType="Consume_Message_ptt" operation="Consume_Message">
    <activation-spec className="oracle.tip.adapter.jms.inbound.JmsConsumeActivationSpec">
    <property name="DestinationName" value="eis/JMS/RemoteQueue"/>
    <property name="UseMessageListener" value="false"/>
    <property name="PayloadType" value="TextMessage"/>
    </activation-spec>
    </endpoint-activation>
    </adapter-config>

  • Error when consuming JMS messages in clustered environment

    Hi ,
    I have the following setup:
    2 ManagedServers configured in a cluster: ManagedServer1a and ManagedServer2.
    JMSServer: Configured on ManagedServer1a.
    ConnectionFactory : Associated with the Cluster
    Queues and Topics : Associated with the JMSServer.
    PersistentStore: Associated with ManagedServer1a.
    Job Creator deployed on ManagedServer1a
    Job Consumer deployed on ManagedServer2.
    I see the following exception in the ManagedServer2 logs when it tries to consume the message.
    ========8<========8<========8<========8<========8<========8<========8<========8<========8<========8<
    <Mar 19, 2009 5:01:43 PM IST> <Warning> <RMI> <BEA-080005> <Exception thrown by
    rmi server: dispatch
    java.rmi.UnmarshalException: error unmarshalling arguments, count=410, lastMethodId15629, lastRequestType9; nested exception is:
    java.io.UTFDataFormatException.
    java.rmi.UnmarshalException: error unmarshalling arguments, count=410, lastMethodId15629, lastRequestType9; nested exception is:
    java.io.UTFDataFormatException
    at weblogic.messaging.dispatcher.DispatcherServerRef.invoke(DispatcherServerRef.java:232)
    at weblogic.messaging.dispatcher.DispatcherServerRef.handleRequest(DispatcherServerRef.java:141)
    at weblogic.messaging.dispatcher.DispatcherServerRef.access$000(DispatcherServerRef.java:34)
    at weblogic.messaging.dispatcher.DispatcherServerRef$2.run(DispatcherServerRef.java:111)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
    Truncated. see log file for complete stacktrace java.io.UTFDataFormatException
    at weblogic.utils.io.ChunkedDataInputStream.readUTFFromChunk(ChunkedDataInputStream.java:298)
    at weblogic.utils.io.ChunkedDataInputStream.readUTF(ChunkedDataInputStream.java:178)
    at weblogic.workarea.spi.WorkContextEntryImpl.readEntry(WorkContextEntryImpl.java:92)
    at weblogic.workarea.WorkContextLocalMap.receiveRequest(WorkContextLocalMap.java:151)
    at weblogic.jms.common.JMSWorkContextHelper.readWorkContext(JMSWorkContextHelper.java:89)
    Truncated. see log file for complete stacktrace
    >
    <Mar 19, 2009 5:01:54 PM IST> <Warning> <Socket> <BEA-000449> <Closing socket as no data read from it during the configured idle timeout of 5 secs>
    ========8<========8<========8<========8<========8<========8<========8<========8<========8<========8<
    I also notice that after this the persistence store appears to be corrupted. I get the exception:
    ========8<========8<========8<========8<========8<=======
    <Mar 20, 2009 2:15:03 PM IST> <Error> <JMS> <BEA-040123> <Failed to start JMS Server "JDJMSServer" due to weblogic.jms.common.JMSException: weblogic.messaging.kernel.KernelException: Unexpected store exception in messaging kernel recovery.
    weblogic.jms.common.JMSException: weblogic.messaging.kernel.KernelException: Unexpected store exception in messaging kernel recovery
    at weblogic.jms.backend.BackEnd.open(BackEnd.java:999)
    at weblogic.jms.deployer.BEAdminHandler.activate(BEAdminHandler.java:196)
    at weblogic.management.utils.GenericManagedService.activateDeployment(GenericManagedService.java:239)
    at weblogic.management.utils.GenericServiceManager.activateDeployment(GenericServiceManager.java:131)
    at weblogic.management.internal.DeploymentHandlerHome.invokeHandlers(DeploymentHandlerHome.java:591)
    Truncated. see log file for complete stacktrace weblogic.messaging.kernel.KernelException: Unexpected store exception in messaging kernel recovery
    at weblogic.messaging.kernel.internal.PersistenceImpl.recover(PersistenceImpl.java:913)
    at weblogic.messaging.kernel.internal.KernelImpl.open(KernelImpl.java:239)
    at weblogic.jms.backend.BackEnd.open(BackEnd.java:997)
    at weblogic.jms.deployer.BEAdminHandler.activate(BEAdminHandler.java:196)
    at weblogic.management.utils.GenericManagedService.activateDeployment(GenericManagedService.java:239)
    Truncated. see log file for complete stacktrace
    weblogic.store.PersistentStoreException: [Store:280052]The persistent store was not able to read a record.
    at weblogic.store.internal.PersistentStoreRecordImpl.getData(PersistentStoreRecordImpl.java:66)
    at weblogic.messaging.kernel.internal.PersistenceImpl.recoverHeaders(PersistenceImpl.java:1226)
    at weblogic.messaging.kernel.internal.PersistenceImpl.recover(PersistenceImpl.java:888)
    at weblogic.messaging.kernel.internal.KernelImpl.open(KernelImpl.java:239)
    at weblogic.jms.backend.BackEnd.open(BackEnd.java:997)
    Truncated. see log file for complete stacktrace
    java.io.StreamCorruptedException: [Messaging:282000]Unsupported class version 48. Expected a value between 1 and 3 inclusive.
    ================8<================8<================8<================8<================8<
    Any clues on why this error occurs? And how to resolve it?

    Which WLS version are you using?
    CR293674 seems to for issue related to persistent store.
    In certain circumstances, the invocation of a WebLogic Web Service configured for reliable messaging will throw the following PersistentStoreRuntimeException error:
    weblogic.store.PersistentStoreRuntimeException: [Store:280051]The persistent store was not able to create a new record.
    Workaround or Solution:
    When starting the WebLogic Server instance to which the reliable Web Service is deployed, set the following property:
    -Dweblogic.wsee.exclude.properties=weblogic.wsee.ejb.target
    Refer: http://download.oracle.com/docs/cd/E11035_01/wls100/issues/known_resolved.html#wp1056965
    -Akshay

  • How to consume JMS message in oc4j from web logic server 11.1.1.3

    Hi all,
    I would like to know how to consume the JMS messages in oc4j instance from 11.1.1.3 (web logic). Can anyone guide me any documentation? Thanks.
    Soe

    Hi,
    Have a luk at the below link
    http://blogs.oracle.com/TechMusings/2008/08/connecting_to_weblogic_jms_pro.html
    you also have other options like creating foreigh JNDI or JMS bridge.

  • Producer and Consumer  JMS Connections

    Hello,
    I am writing a JMS provider and I notice that Flex creates a
    JMS connection for a Producer and another JMS connection for a
    Consumer in my test application. Is this normal behavior for Flex
    or do I have a problem with my provider that is causing this?
    Thanks,
    Chris Shafer, George Weiss Associates

    If your goal is to have one JMS Consumer which receives
    messages and broadcasts them to Flex clients, you can do this
    without using the JMS adapter. Write some Java code either as a
    "message driven bean" or using the JMS apis directly to grab the
    JMS messages. You can then convert these messages to flex messages
    and send them to an ActionScriptAdapter flex messaging destination.
    See the Feed.java sample for the code necessary to do this. The
    trickiest part of this is getting the JMS messages in the first
    place. We are working on packaging up our JMS consumer apis so you
    can do this more easily in a future release.

  • Consuming JMS ObjectMessages

    Hi!
    I have the following code that is meant to run through a loop until no more objectmessages are in the jms queue.
    Messages are being correctly sent to the jms queue(to test this, i have replaced "receiveNoWait()" with receive() and "Reached here" is been printed to the screen for each object received, but loop does not break) but the loop is always breaking.
    Can you help me fix this?
    Thanks for your help in advance.
    Context jndiContext = new InitialContext();
    ConnectionFactory factory =(ConnectionFactory) jndiContext.lookup("jms/ConnectionFactory");
    Destination dest = (Destination) jndiContext.lookup("jms/Queue");               connection = factory.createConnection();
    Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);     
    MessageConsumer consumer = session.createConsumer(dest);connection.start();
    while (true){
         ObjectMessage m = (ObjectMessage consumer.receiveNoWait();
         if(m == null)
         break;
         System.out.println("Reached here");          
         }

    If you want to drain a queue and be completely sure you get every possible message I'd recommend using the receive(timeout) method with some timeout of a second or two. This is because many JMS providers will make sure receiveNoWait() does not block at all - but that does not always mean that there is not a message on the queue. JMS is designed for high performance with as little blocking and latency as possible - providers typically do things asynchronously, so receiveNoWait() often just means there is no message available in this JVM; not that there is no message on the broker available.
    receive(1000) will typically wait long enough to drain messages from the queue if they are available. Its kinda JMS provider dependent; but most providers should work with receive(1000); many won't for receiveNoWait()
    James
    http://logicblaze.com/

  • Re: Consuming jms queue synchronously in SOA11g

    Hi
    I have the below requirement
    In Queue total 5 messages are there, in those 3 are with same ID and 2 are with same ID.
    My requirement is that for the above 5 messages only two BPEL processes should be created for each ID.
    1st BPEL consumes 3 messages
    2nd BPEL consumes 2 messages
    Please give me idea to do this.
    Thanks in Advance
    Vamsi..

    Hello friend,
    So, according to your scenario...you are producing messages into the Queue using JMS Adapter Outbound Operation ( JMS adapter is on the references side)
    And as we know, in order to read the message from JMS Queue we use JMS Adapter and that would be inbound operation (JMS adapter is on the services side)
    So, when we define a JMS adapter in our composite as consume message operation...then the JMS adapter will be on the services side...then we declare our BPEL interface based on the WSDL of JMS Adapter (Consume operation). SO by default the interface of the BPEL would be one-way i.e., just fire and forget. So, lets say you wrote 10 messages to the Queue. So, the consuming BPEL would take all messages at a time...as you said there would be 10 instances....
    So, if you make the interface of the BPEL to synchronous and also you just need to reply back ( any dummy message) to JMS adapter....just keep a reply activity at the end of the BPEL ...so by doing this...unless and until it gets the response from the synchronous BPEL (consuming BPEL), the JMS adapter doesn't give the next message in the Queue to the BPEL...that means at any point of time only one BPEL instance would be running for you which is what we want to achieve...And you can see this clearly in the Queue in the weblogic admin console...This is called throttling the JMS adapter....This works...
    And one more important thing to be considered is...taking the synchronous process time out thing...as we know by default the client of the synchronous process cannot wait for more than 45 seconds...may be if you want more time to process ...you can change that in EM console...BPEL properties in SOA administration...
    I think it is syncMaxWaitTime..change that may be to 300...
    Try this...Hopefully this should work for you..and let us know ...
    Hope this helps...
    Thanks,
    N

  • Consuming JMS messages Asynchronously

    Can any one let me know how to consume the JMS messages Asynchronously from Queues.
    Thanks,
    Naveen

    well for instance with an MDB
    if you want a long, theoretical explanation here you are http://docs.oracle.com/javaee/5/tutorial/doc/bncgl.html#bncgq
    otherwise some examples with a lot of explanation here http://www.roseindia.net/ejb/example-of-messageBean.shtml

  • Can' t consume JMS messages from remote queue

    Hello.
    We are using Tibco JMS Server as Foreign JMS server from WL server. And WebLoigic (8.1 SP 3) MDBs are receivers. Everything works fine until there is a restart of the Tibco server. Once the queues become unavailabe, we see in the WL log that the destination is unreachable. And also once the Tibco server comes back up, WL log says that the Foreign queues have been re-connected. But still, we don't see any messages being received by the MDB. The MDBs are configured to poll for messages evey 1 second. Still we don't see it happening after the foreign server restart.
    But if we re-start the WL server, it begins to work just fine.
    Any pointers?
    Thanks

    I do have the correct IP address of the syslog server set up. I do not want email logs so have not enabled that.
    My setup is
    remote lan > SA520-remote (192.168.160.1) > [ site to site IPSec VPN over WAN ] > SA520-local (192.168.150.1) > syslog server (192.168.150.25) & local lan
    Firewall is set up to allow ANY IN & OUT to local lan on both routers.
    I have also set up specific rules for UDP 514 Syslog traffic (no difference, currently disabled)
    syslog server has -no- firewall at the moment.
    Syslog server is receiving messages from the local router with no issues.
    Log Severity is set to Information &  Log Facility is set up to send to Syslog.
    I have also setup a SNMP trap on the syslog server & pointed the remote router to it in hopes of diagnosing the issue.
    Both routers have the latest firmware applied.
    Using wireshark on the syslog server I see no traffic on UDP 514 (syslog) or UDP 162 (snmp)
    I can use the WUI for the remote & ping the 160.1 with no problem. Both ping & TLS/TCP traffic show up in wireshark on the syslog server when I do so.
    It looks to me like there is a problem routing the syslog messages out of the router & then back through the VPN.
    Worst case I'll set up another syslog server on an old machine at the remote location & then cron the logs to the central syslog server but it really seems I shouldn't have to.

  • Oracle Service Bus 10.3.1 proxy consuming jms (AQJMS)

    Hi,
    I need to use AQJMS with Oracle Service Bus proxy.
    We have an installation with WLS 10.3 and OSB 10.3.1 and another with WLS 10.3.1 where I defined a JMS Foreign Server like appears in the documentation http://download.oracle.com/docs/cd/E12839_01/web.1111/e13738/aq_jms.htm#JMSAD565.
    I need support to how to define the URI at the OSB configuration.. jms://server:port/XAQueueConnectionFactory/QueueName... because I tried a lot of ways and can't make it work.
    Thank You in Advance...
    Juan Pablo

    Hi,
    Because I want to use the jms protocol... because if I change AQJMS with another JMS Provider the only thing that I must change in OSB is jms://server:port/CF/Q
    In SOA Suite 10.1.3.x I use JMS Adapter for this...
    Thank You.
    JP

  • Distributed topic - JMS adapter consuming duplicate messages

    We have distributed topic thats consumed by a composite (JMSadpter in mediator).
    We see for every one message sent the composite consumes the message twice. (With forwarding policy set to partitioned)
    Is this an expected behavior? and how do we make the consumer (JMS adapter) consume only once per message
    Thanks
    Vijay

    From the documentation (provided here: http://download.oracle.com/docs/cd/E21764_01/integration.1111/e10231/adptr_jms.htm)
    The JMS API specifies three types of acknowledgments that can be sent by the JMS publisher:
    - DUPS_OK_ACKNOWLEDGE, for consumers that are not concerned about duplicate messages
    - AUTO_ACKNOWLEDGE, in which the session automatically acknowledges the receipt of a message
    - CLIENT_ACKNOWLEDGE, in which the client acknowledges the message by calling the message's acknowledge method
    Could you check in the weblogic-ra.xml what acknowledge mode has been configured:
    <property>
        <name>AcknowledgeMode</name>
        <value>AUTO_ACKNOWLEDGE</value>
    </property>
    ...Note that when DUPS_OK_ACKNOWLEDGE is used it can happen that a message is consumed more than once.
    Are you also sure that the message is not produced twice?
    Seminar on Cloud Computing - http://middlewaremagic.com/weblogic/?p=7387

Maybe you are looking for