When you take a look at the SOAJMSModule located at the JMSModules of WebLogic you can see that the module already contains an EDN Queue and an EDN ConnectionFactory.
So you only need to configure SOA Suite so it uses this Queue and Connection Factory. To do so open the enterprise manager application | SOA | soa-infra and open the Common Properties Menu item of the SOA-Infrastructure menu. Click on More SOA-Infra Advanced Configuration Properties
This will open the System MBean Browser. In this we can change the EdnJmsMode and set this to true.
Restart the SOA Server and take a look at the monitoring of the EDN Queue. Here you must see there are some Queue Consumers
Second part of this blog is to publish a event. For this I made a simple Employee Id XSD which can be published.
Create a SOA Project and add a Mediator with a One Way Operation which uses this XSD. Also expose this Mediator so you can invoke this operation from the Enterprise Manager.
Add a routing rule and choose for an Event.
Define an Employee Event.
Add a transformation and map the source and destination elements
Your composite will look like this. Deploy the composite to the SOA Server.
To see the event you need to pause the consumption of the EDNQueue.
Open the Enterprise Manager and test the service of the EDN composite.
Go back to the EDNQueue and look at the JMS Message. It contains some SOA instance tracing elements and has a MessageType JMS Header which defines the EDN mode.
In the following documentation you can read about, how to create a Foreign JNDI provider on your ADF server so you can publish JMS EDN events from an ADF Client.
hey this information is really great regarding oracle fusionware
ReplyDeleteRegards
Ritu
oracle fussion middleware
Nice Post. Thanks.. I've tried the steps. but I can't see the message on the JMSQueue. I've sent the message thru the EM'S test console, but the message is not appearing in the JMSQueue. What must be the problem. Kindly suggest.
ReplyDeleteNote:I'm using same version of SOA Suite and Jdev(11.1.1.5.).
Thanks
Ananth
Hi,
ReplyDeleteDo you see some activity on queue and did you paused the consumption of the queue.
thanks
I Paused the consumption of the queue and there is no activity on queue.
ReplyDeleteHi,
ReplyDeleteJust a few checks , is the mbean attribute still on jms and did you restart all the servers.
Thanks
I set the EdnJmsMode is true. I restarted the SOA Server and Admin Server. Paused the consumption of the queue. but can't see any activities/messages on queue.
ReplyDeleteThanks
If I want to use default AQ implementation for EDN, Do I need to do any configuration changes? and with default AQ implementation,
ReplyDeletehow do I publish Events to EDN using java?
Hi
ReplyDeleteAq is the default. for a java aq client look at this https://guidoschmutz.wordpress.com/2010/01/12/using-the-event-api-to-publish-an-event-to-the-event-delivery-network-edn-the-spring-way/
thanks
Hi Edwin just like Ananth I cant see anything going to the the EDNQueue.
ReplyDeleteJust an observation, you started with the EDNQueue and when you restarted the server after the configuration it changed to SOAJMSModuleEDNQueue ?? Did you rename or is it a new Queue you created?
Please throw some light on this.
my email is naggarwal@gmail.com
Hi,
ReplyDeleteSOAJMSModuleEDNQueue is the name where the real implementation of the queue is running ( jms module / server ), in this case EDNQueue queue is running on the SOAJMSModule.
When you have a distributed queue or targeted on more then one server then you will see more then one
I will retest it.
Thanks
Hi,
ReplyDeleteI retested it with SOA PS3 , normal installation , no developer install and it works perfectly
thanks
I did realise that the QueueName wasn't the issue.
ReplyDeleteBut Not sure what we are doing wrong.
I am running this on a SOA 11.1.1.1.4 with an admin and a managed server on my dev box.
Are the following Queue settings correct ?
Name SOAJMSModule!EDNQueue
ProductionPaused false ConsumptionPaused true
InsertionPaused false
Is there a way to find out what messages have been going to the queue without pausing it/ as its not working for me
Also even though it doesnt look like an issue with the code can you share your code so that I can see if there is anything in the configuration of the Event.
Regards
Nitin Aggarwal
I have managed to get this working... It worked once I deployed the listener code to the server. I presume that it was throwing away the messages if there were no subscribers to the queue.
ReplyDeleteI would recommend you add that to the post.
Thanks for your help
Hi Nitin,
Deleteyou said you deployed the listener code to the server..so, what is the code you are talking about here, is it the mediator service that listens ( subscribes ) to the queue as above or do we need a listener separate code.
My requirement is i have to raise a business event. for this i wrote a JMS client as mentioned here in the post: http://biemond.blogspot.com/2011/06/publish-to-edn-from-java-osb-with-jms.html and could post the message to the queue.
Now I created a mediator component as stated in this post with the configurations set to JMS. Now the mediator component is not listening to the Queue and the message is not getting consumed.
So, do i need to run a separate listener class to subscribe to the queue ? Can't the mediator service consume the message from the JMS.
please advise.
Thanks,
Srini
Can you make a dummy edn produce and consume composite process and see if jms edn works.
Deletethanks
Hi Edwin,
DeleteDummy EDN produce and consume composite process works with JMS.
1.) From EM console I did set the EdnJmsMode to true.
2.) Created the Event Definition File.
3.) created a composite with Mediator to subscribe to the events and deployed the composite.
4.) From the EM console, published the Business Event with sample payload.
5.) In the JMS queue i could see the message coming in and being consumed by the Mediator composite.
Next is, i want to publish the Business Event from a JMS client, not from the EM console as we did in step 4 above and want to consume the message with the same Mediator Component we created above.
So,I created a JAVA client to post the message to EDNJMSQueue (jms/fabric/EDNQueue ).
referred: http://biemond.blogspot.com/2011/06/publish-to-edn-from-java-osb-with-jms.html
Now as in step 5 above i could able to see the message in the Queue but not being consumed by the Mediator composite.
Do i need to change any configuration in the Mediator Composite ? or Do i need to write a separate listener code to consume the message from the Queue.
Since the message is being posted to the same EDNJMSQueue, can't the Mediator Composite consume it as in step 5 above.
I might be missing something here, your help is appreciated.
Thanks,
Srini.
hi
Deletecan you check the message and jms header properties this should be same as your dummy produce. and are you connecting to the soa server. you can also use a qbrowser to put the message direct in the queue.
thanks
Edwin,
DeleteI am connecting to the soa server. Following are the header properties.
The MessageType differs and the Sidecar content differs and i am using the same JMS client as in your other post, no change..
Publishing via EM console.
Sidecar: ns:ErrorEventNotification-sidecar XX_TEST/SubscribeToErrorNotificationEvent!1.0*soa_e4d1ccf2-209f- 4506-94ef-50dff4bd8f49SubscribeToErrorNotificationEvent $publisher ccaein
Message Type: IntOneAndOnlyOne
JMSXDeliveryCount: 0
Publishing via JMS client:
Sidecar:: ns:ErrorEventNotification-sidecar
Message Type: Remote
JMSXDeliveryCount: 0
Thanks,
Naga
Hi Edwin,
DeleteI am connecting to the SOA server.
Publishing via EM console.
Sidecar: ns:ErrorEventNotification-sidecar XX_TEST/SubscribeToErrorNotificationEvent!1.0*soa_e4d1ccf2-209f- 4506-94ef-50dff4bd8f49SubscribeToErrorNotificationEvent $publisher ccaein
Message Type: IntOneAndOnlyOne
JMSXDeliveryCount: 0
Publishing via JMS client:
Sidecar:: ns:ErrorEventNotification-sidecar
Message Type: Remote
JMSXDeliveryCount: 0
when using the qbrowser i the message is sitting in the Queue, but there the Message Type is missing.
Please advise.
Thanks,
Srini
Hi,
DeleteMessage Type is always remote when you do it from outside the soa suite. Can you use exactly the same Sidecar and see if that works.
and then remove some data until it fails.
thanks
Ok, thanks
ReplyDeletePublishing from java or OSB should lead to message in a queue and activity . This by passes SOA code.
From edn publishing composite can be clever and detects there are no listeners
Hi Edwin,
ReplyDeleteI followed the steps given in developer guide to publish events to remote web logic. I have created foreign JNDI as said. But Messages are not getting posted to remote weblogic EDN queue.
Please throw some light on this.
If you have any documents related to this please share.
Regards
PavanKumar.M
Hi,
ReplyDeleteDo you have a composite listening for edn events and can you try to publish it from java.
http://biemond.blogspot.com/2011/06/publish-to-edn-from-java-osb-with-jms.html
thanks
Hi Edwin,
ReplyDeleteI am able to successfully publish the events to the JMS queue, using a BPEL process, but I tried all the steps you menetioed for Mediator, but it did not work not sure why.
Anyways I have a question why the "Consumers Total" is 1458 in your above picture.
In my case it is increasing after every second and it is now 6703, I believe these are the instances of the MDB's listing to this queue. but how come it is increasing after every second..
Awais
Hi,
DeleteCan you deploy the mediator first and test the EDN event in the EM and after that deploy the BPEL producer.
Crazy numbers indeed , looks like the soa JMS implementation is not so well developed. Does it stays so high and keep increasing.
Thanks
The event is created, in SOAJMSModule!EDNQueue the message is there, but its subscriber does not read (composite does not start)
ReplyDeleteHi Edwin,
ReplyDeleteI got a question that you might be able to answer.
I have been playing with WLS 12.1.3 and SOA 12.1.3. I have an ADF application and would like to publish Business Events on the EDN using JMS. Since SOA 12c, the event subscribers consume JMS messages from the EDNTopic instead of EDNQueue.
So, I created and defined a new business event on an ADF BC entity. In Foreign JNDI Providers, I defined a new entry with "weblogic.jndi.WLInitialContextFactory" "t3://mysoaserver:8001" and weblogic credentials. I added 4 links (jms/fabric/EDNConnectionFactory, jms/fabric/EDNQueue, jms/fabric/EDNTopic, jms/fabric/xaEDNConnectionFactory). When I create a new instance of my entity in my ADF application, it publishes my JMS message to the EDNQueue instead of EDNTopic and events are not consumed on the SOA server...
I tried the JAVA way and used "BusinessEventConnectionFactorySupport.findRelevantBusinessEventConnectionFactory(true);" to resolves the connection factory (from the edn.jar) and it just works! It looks up the right config:
[2014-10-15T10:15:33.197+00:00] [loyco_server1] [NOTIFICATION] [] [oracle.integration.platform.blocks.event.jms2.EdnJmsConnection] [tid: [ACTIVE].ExecuteThread: '3' for queue: 'weblogic.kernel.Default (self-tuning)'] [userId: sgi] [ecid:
0051NDdQVJ7Fc5w5wFl3iW0005eh001agF,0:1] [APP: ADFApplication] [DSID: 0000K^JGwC4F^6w5wF0FyW1KFZDp000001] Looked up JMS Config = [oracle.fabric.blocks.event.JmsConfig@2da588b0 [remote=false, jmsType=WLJMS, durable=false, xa=false, conn
ectionName=eis/wls/EDNLocalTxTopic, topicName=jms/fabric/EDNTopic]].
So my question is: is there a way to setup my ADF application to publish EDN events to my EDNTopic without writing any extra Java code and overriding ADF BC Java classes?
Thank you!
Also, you are doing a great job with this blog (and your other projects), thanks for that.
Hi im also encountering this issue.
ReplyDeleteThe event is created, in SOAJMSModule!EDNQueue the message is there, but its subscriber does not read (composite does not start)
Hi Edwin, i've a issue with EDN, I send a just request to Publisher, but a Mediator Subscriber consumes this same Event multiples times,
ReplyDeleteHi Edwin...
ReplyDeleteThanks for explaining the concept so well.
can you help in initiating an edn from plsql api in soa 12c..
Hi Edwin,
ReplyDeleteCan we use mediator as subscriber EDN to JMS topic.
Thanks