
SOA Suite on EC2
One of the things on my To Do list was to move my local SOA Suite 11g R1 to
The Cloud. It seemed a good idea to save my laptop some resources (to spare some for JDeveloper) with only a limited investment. Besides that it can be a good way to demo applications, and work together with my colleagues on these demos.
During the last months I noticed that there are several good blogpost on the subject. In this post I’ll show you the ones I used and provide some additions to them.
Setting up Amazon Web Services (EC2 and S3)
This arcticle on OTN guided me while signing up for:
- Amazon AWS
- Amazon S3 – Simple Storage Service
- Amazon EC2 – Elastic Compute Cloud
and to setup PuTTY. The only hick-up here was that I’m using the PortableApps version of PuTTY that doesn’t come with the puttygen – Key Generator.
Provisioning a SOA Server on Amazon EC2
This blogpost guided me in the provisioning of the AMI (Amazon Machine Image).
- AMIs are per region: The Amazon Machine Instance (AMI) for SOA Suite (id = ami-acb557c5) is only available in the US East (Northern Virginia) Region.
- Don’t bother to setup the Elastic Block Store (EBS) Volume. It is scripted in the latest version of the AMI, as described in step 5 of “SSH to your image and accept license”. The EBS Volume is seeded using a snapshot (id = snap-dd980db4) that is provided. This volume will be used to persist your data across sessions and AMI start/stop.
- When launching the image (during the Configure Firewall step) set the SecurityGroup to accept HTTP traffic on port 7001 in case you want to use the SOA Suite from outside the Image.
Categories: Architecture, BPEL, Database, JDeveloper, Life hack, Oracle, SOA Suite, Service Bus, WLS
Tags: 11g, cloud, EC2, Fusion Middleware, JDeveloper, SOA Suite, WebLogic, WLS
Although there were already several posts on querying AQ, like “in the queue” and “enqueue“, the next one is great when monitoring queues. We are using this to monitor AQ, especially for Oracle ESB (hence the commented addition):
1
2
3
4
5
6
7
8
9
| SELECT aq.name
, aq.queue_table
, aq.queue_type
, v$aq.*
FROM v$aq
, all_queues aq
WHERE aq.qid = v$aq.qid
-- use if looking for ESB AQ: and aq.queue_table = 'ESB_JAVA_DEFERRED';
; |
The query will result in something like:

It contains the following metrics:
- Waiting – Number of waiting message;
- Ready – Number of messages with status ready;
- Expired – Number of expired messages;
- Total Wait – Total waiting time per queue;
- Average Wait – Average waiting time per queue.
A describtion of the AQ and Streams views can be found here.
Whether or not your Oracle Advanced Queue (AQ) will enqueue and dequeue messages can be determined with a simple query:
1
2
3
4
5
6
7
8
| SELECT name
, queue_table
, enqueue_enabled
, dequeue_enabled
, max_retries
, retry_delay
FROM user_queues
; |
The query example is based on user_queues and in that case it has to be performed as the owner of the queue. The result wil be something like:

AQ enqueu dequeue
As a quick follow up on the previous post… If you are using a JMS queue with Oracle´s Advanced Queueing or Streams (as they have been extended to) the previously described tool can´t help you out.
For this case a blog by a former colleague helps us out. This approach boils down to…
Find the queue you want to monitor.
1
2
3
4
5
| SELECT owner
, queue_table
, type
, user_comment
FROM all_queue_tables |
Perform a query.
1
2
3
4
5
6
| SELECT msgid
, enq_time
, enq_uid
, qt.user_data.text_vc
FROM my_queue_table qt --alter the table name
WHERE q_name = 'MY_QUEUE' --alter the queue name |