Pages

Showing posts with label SOA Suite. Show all posts
Showing posts with label SOA Suite. Show all posts

Collapse All in the Flow Trace

With more complex BPM and/or BPEL processes, debugging the flow trace can be kind of slow. However, if you know what you are looking for, there might be a trick to help you get where you want to be quicker.

The flow trace can be very long and scrolling through it, or even scrolling all the way to the end can take quite some time. But there is a right mouse menu if you click the icons on the left. So if you mouse click the mediator we see, called ‘RequestHandler’, there will be a popup menu: 

If you select the ‘Collapse All Below’ option in the menu, it will as you might expect, not only collapse the mediator, but it will collapse all the children and their children. Meaning, once collapsed, you can expand them one by one, going to the correct subprocess where you want to be. 


This means, in complex processes, you can get to where you want to be a lot quicker, because the flow trace performance a lot better with all the items collapsed.  


JDeveloper Shortcut Keys: Go To File

I have been noticing that a lot of developers are either struggling with finding files in JDeveloper or taking a long time to open all the packages and browsing to the files. However, JDeveloper has a lot of shortcut keys that come in handy.

First of, a shortcut key to 'Go To Java Type', I think most developers know this one. It is the 'ctrl' + '-' on windows or '⌘' + 'J' on mac, you will get this window:

However, did you also know the search is CamelCaseSensitive? It is a very neat trick, imagine you have connected your ADF sources and want to look up the PageFlowScopeMap in the 'org.apache.myfaces.trinidadinternal.context' package.
You can open the 'Go to Java Type' screen and start typing page, but a lot of java classes will come up:

As said the search box understands CamelCase, so if you instead start typing the fist capital of each CamelCase word, in this case 'PFSM' (PageFlowScopeMap) JDeveloper will understand:

How cool is that?

Now this is not where it ends, instead of only searching for Java Types, you can search over all your files in JDeveloper, using the shortcut key: 'ctrl' + 'alt' + '-' on windows or '⌥' + '⌘' + '-' on mac. The following window will popup:

In here you can search for any file, but again you can also search CamelCase, for example, in case I want to search my ViewControllerBundle.properties file:

Now, in both windows you can also use wildcards (*), however the CamelCase will not work in combination with a wild card anymore.


Auto Search in the Enterprise Manager through bookmarks

Since 12c when debugging or looking at flow instances in the Enterprise Manager, we have to use the search button to make the flow instances appear. By default the following text is being displayed: 'Conduct a search to display the list of message flows across SOA composites in the SOA Infrastructure'.

When you open the search bar on the right pane and click search, the instances of the last 24 hours are being displayed:

However, there is also a shortcut on this same search pane to 'Generate a bookmarkable link':

If you press this button, a pop-up will be displayed and the generated link will be selected:

Looking at the link, you can see that it holds URL parameters to open the flowInstancesTab and execute the search query. If you copy this link, and paste it in your browser, you will see that it opens the corresponding tab, and start fetching the data:

This means that if you bookmark the URL, from now on you are only one click away from going into the Enterprise Manager, navigating into the flowInstances tab and query the search results:


OOW15: Announcing SoaCS

The Oracle SOA Cloud Service is online and you can check it out on the Oracle SoaCS Cloud page. This SoaCS offers you all the functionality the SOA Suite offers you on premise. In the cloud, Oracle has the same red stack strategy as they have on premise. This means the SoaCS runs on Oracle hardware and the Oracle database. This forces you to have a DbCS as well.

To get the SoaCS, you follow a wizard that guides you through the steps of setting up the Cloud. In here you choose what kind of services you want, Service Bus, SOA Suite, a combination of both or the API Manager. You enter the database credentials to connect to the database in the cloud and select how much CPU and memory you want to run on. You even have control in which data center the cloud is going to be hosted. This whole wizard is based on a webservice API, so if you want you can script and automate this process. 30 to 60 minutes later your SoaCS is ready and you can start using it.


So now you got your automated provisioned & back upped SOA Cloud Service. You can connect to an on premise ldap. You can set up an ssh tunnel, not a vpn yet, although this is on the roadmap. Oracle will apply the patches for you, but you are in control whether you want them or not. There is a precheck whether the patch can be applied or not, but you cannot schedule the patch for now, you can choose to apply or to wait with it, but if you choose to apply the patch, it will be done directly.
Oracle will not force you to upgrade, however, they only support the latest and the latest minus 1 version, so you cannot keep creating older versions once newer versions have come out.

Off course one of the great benefits of the cloud is the scaling, so when needed, you can add a node manually. The elastic scaling of nodes is on the roadmap, but not yet there. This means that in the near future you can add rules like ‘If the CPU uses more than 80%, add another one’.
You will have full EM and console access to your cloud instance.

Oracle is working on a white paper with best practices, this should come out soon. But if you can not wait, you can start a 30 days free trail, you will have to go through the JCS set up for this though. Click the ‘Try It’ button on the Java Cloud page for more info.


The order of the assign and transform in the Mediator

In my previous blogpost I pointed out the usage of an assign in a mediator component. This can be useful over the transform in several cases. Besides using one of the two, it is also possible to use them both in the same route. I would not advise using both the assign and the transform to manipulate the same data object, however this is possible.

If you want to do this, it is good to keep in mind in which order the mediator handles the manipulations. I used the same example from the previous blogpost and added an transformation in the mediator.

In the transform, I copy the firstname from the input, to the lastname of the output:
 

Resulting in both a transform and an assign in the mediator:
 

I deployed the service to the Enterprise Manager and will fire the following test:
 

The response already clarifies what happened here, the transform is fired first and only after the transform is done, the assign is being processed, because the input is the same as the output:
 

However, to verify this assumption, we will have a closer look at the flow trace, in the flow trace, we open the instance of the mediator:
 

In here we can clearly see that the xsl transformation is done before the assign.
Keep this in mind when you want to use both the transform as well as the assign option on the same data object in the mediator.


Use the assign instead of a transform in the Mediator

When building less complex services, your BPEL process often uses input and output that is pretty much like the request and response on the wsdl. We would still want to decouple using the mediator component, so there is an extra transformation there which is pretty straight forward.
Sometimes it can be useful, easier and faster to use a assign in the mediator instead of a transform.

Imagine an pretty straight forward xsd:


I created an example BPEL process, also pretty straight forward. The Person is both the input and the output, all the BPEL process does is copy the input to the output and reply it:
 

In the Create Web Service dialog we create a WSDL based on the same XSD, also with a Person as input and output:

As said, because of decoupling, we would still want to have a mediator between the exposed service and our bpel process. We create a mediator and wire it both to the service and to the bpel process.
However, when editing the route, we usually use a transformation to map the input to the output, in this case, we are going to use an assign:

When you click the assign button, this also pop ups and Assign Values dialog, here we can wire the input element to the output element:

This way we use an assign in the mediator instead of creating an xsl transformation for this pretty straight forward transformation.


Switch the Audit Level to Development mode

With JDeveloper 12c it is now possible to run your SOA Suite against the Integrated WLS. However, by default the Audit Level of this server is Production mode which means you do not get to see details when looking at the flow trace of your service.
If you do not change your running mode, the flow trace window will look like this:


We will switch the Audit Level of your local SOA domain to Development mode, to get more info in the flow trace. Right click on your soa-infra, go to the SOA Administration and select the Common Properties:



Change the Audit Level to Development and click Apply:



You do not need to restart your server after this. However, you do need to test your service again. Test your service and again go to the flow trace, the result should now look like this:



You can now press the ‘View Payload’ to see the payload of your transformation:




Run ADF & SOA on the IntegratedWLS in separated domains

In JDeveloper 12c, it is possible to run SOA Suite on the InternalWLS, which is a great feature. However, once you have done this, your domain will be filled with SOA extensions. Meaning the server start up time will increase drastically.
When you do both ADF & SOA development, this can be annoying when you just want to run your ADF application and the IntegratedWLS is busy starting up the SOA domain. One way to avoid this is to run two different JDeveloper instances with two different Jdev Homes configure.
In this blog I will describe you how to set this up.

First of all, I got my ‘normal’ JDeveloper for ADF development, this is installed on my C drive, under: C:\oracle\JDev1213, if you navigating to the Oracle_Home\jdeveloper\jdev\bin folder and open the jdev.boot file, you will see the variable ‘ide.user.dir.var’:


Now I recently installed a second JDeveloper 12c in a different directory, this JDeveloper is installed with the SOA extensions, I installed this on the C drive as well, but in the folder C:\oracle\JDevHomeSOA. Within this JDeveloper folder, there is also a jdev.boot file under the folder ‘\jdeveloper\jdev\bin’, however, I changed the ‘ide.user.dir.var’ to a specific _SOA variable:


Now all that is left to do is to create two new Environment Variables, pointing to different JDevHome directories:


This will create two different domains for each JDeveloper, keeping your environment clean and tidy!

OOW14 summary: Oracle Service Bus

Since I am fairly new to the Oracle Service Bus I gathered a lot of information about this product. Most of it is not shocking and has been mentioned already, but this gave me a nice summarized overview of what 12c has to offer in comparing to 11g.

JDeveloper
Since the 12.1.3 release, you don’t need eclipse anymore to create your service bus projects. Just as for the SOA Suite you can do everything from JDeveloper. When creating a service bus project, you will get an sboverview file in your project. This file describes the entire application assembly of proxy services, business services, pipelines, and split-joins. There is one overview file for each Service Bus project.

Debugger
Not only are the Service Bus projects within JDeveloper, they also run on the Integrated WebLogic server. This way it becomes easier to debug the service bus. You can just place breakpoints in your source files and choose the debug command. A breakpoint marks a point in a pipeline or split-join where message processing pauses. This lets you examine the values of some or all of the message variables.

EM FMW Control Console
With the move of the service bus towards JDeveloper, it is now also integrated into the Enterprise Manager Fusion Middleware Control Console as we know it from the SOA Suite. However, there still is the sbconsole as we know it. The layout of the sbconsole has been moved towards the Oracle standard, with that the functionality as you know it from 11g might be displayed a bit different but it is all still there.

Rest/json support
The Service Bus now supports the use of REST service. Meaning you can create rest enabled endpoint with the service bus. However, the Service Bus only provides a virtualization layer to support REST, which means that only proxy and business services are REST-based. These REST services invoke, or are invoked by, a WSDL-based pipeline or split-join. REST proxy services convert the REST native payload to SOAP before invoking a pipeline or split-join, while REST business services invoked by a pipeline or split-join convert the payload from SOAP to REST. The internal interface is WSDL-based, while the external business and proxy services expose REST endpoints.
Read more in the Service Bus documentation.

Pipeline templates
You can create pipeline templates. These templates  are living entities, when creating a new pipeline you can base these on the template. When creating these new pipeline you can decide whether you want it to be linked or unlinked.
If you decide to link the template to your pipeline this means that when the template changes, these changes will be rolled out to the linked pipelines and these will be updated. If you decide to unlink a template, the template will be used as a starting point to create the pipeline, but it will not be updated anymore if the template changes.

Xpath/xquery support
Where you might be used to xpath in the SOA Suite and xquery in the Service bus. With the release of 12.1.3 you can now use both xpath and xquery in the Service Bus as well as the SOA Suite.

Tracing
You can now trace an instance going through both the service bus and the soa suite back and forth. The first service that your instance hits will generate an ecid, this ecid will be used throughout the whole instance. This also works if your SOA Suite and Service bus run on a different domain.

Splitted Pipeline & Proxy Service
You can have a generic pipeline to multiple proxies, this way you can have multiple interfaces, for example to support both an xml and a json interface, but use the same generic pipeline.

Upcoming New Feature
There were a few demos of new features coming in the next release (12.2).
From 12.2 there will be a native end to end support for json, meaning the service bus will no longer translate the json to xml internally. Next to that, there will be a JavaScript action available which you can use in the pipeline to manipulate data. With the help of EX4 this JavaScript expression builder will also be available to manipulate xml, meaning that JavaScript will be a powerful tool within the Service Bus.

Available online resources


What I learned at Oracle Open World 2014

Oracle Open World was once again very inspiring, last week I’ve been summarizing my own notes. I decided to share them with the world, if not only for me to find them back in my own blog archive in the (near) future.

As you might have guessed, there was a lot going on about the cloud. So much, it was almost confusing. The most interesting clouds that stayed with me after OOW14 where:
  • The Integration Cloud Service (ICS).
  • The Java Cloud Services (JCS) in combination with the Developer Cloud Service (DCS).
  • Mobile Cloud Service (MAX).

However, since I am not really working with any cloud related product, my main focus was on the on-premise Oracle FMW stack. So if you want to know more about the cloud, there are plenty of other, better blogs to tell you more about these details.

SOA Suite Upgrade to 12c
First of all, very impressive, you can smoothly upgrade from 11g to 12c. There is an extensive upgrade manual that you can follow, to upgrade from your 11g to the new 12.1.3. release. If you follow the step by step guide, the upgrade will even work if you have running instances on your production environment.
This upgrade has been proven to work on multiple customer cases.

API Management
Oracle will be announcing two new product which will help you with your API management, this features will be on top of the Oracle Service Bus. There are two sides of this product, which are actually separated products. One is to help out with your catalog of services, which are you running on the service bus. This information can be harvested from the bus and will be available in a catalog.
The second product is to help you with managing the consumers of your services. Your consumers must explicitly subscribe to your service in order to get an API key. They must use this API key in the http header when they call the service in order to get a result. Using this feature you get a complete overview of the consumers calling your service.

Oracle Stream Explorer
Oracle Stream Explorer (OSX) is a tool that can help you with getting information out of Oracle Event Processing (OEP). OSX can help you transforming lots of data into information. Stream Explorer can not only listen to edn, but also get input from csv files, database tables and other sources. It is a standalone product that helps you manipulate streams of data (events). Once the data is transformed into information, Stream Explorer can publish this again, for example to a JMS queue.
You can build a custom ADF UI to present this information or you can use Oracle Business Activity Monitoring (BAM).

Mobile Application Framework
The Oracle Mobile Application Framework (MAF) 2.0 is out and it starts to become a really mature product, one of the key things is the new release cycle for MAF. They intend to release every 2 months from now on.
One of the most named down sides of MAF is that it still runs on Java 4. However, not in the upcoming, but the release after that (meaning early next year), MAF will be upgraded to use Java 8. If you ever doubted on starting to investigate on MAF, now might be a good time.
The skills for a ADF developer are pretty transferable, MAF does not use JSF and does not have the ADF lifecycle as we know it from his big brother, but we do have java, taskflows, data controls and the binding layer.

Mobile Cloud Service 
In the session ‘Next-Generation Application Development’, Chris Tonas said “The cloud is not just a deployment platform anymore”. Chris announced the coming of the Mobile Cloud Service (MCS), which is coming soon.
In a fifteen minute demonstration Chris showed how you can create an online mobile application, using the  Mobile Application Accelerator (MAX) for Mobile Cloud Service. An application based on reusable MAF components you can deploy to either Android or iOS devices.

Service Bus & ADF
For both Service Bus & ADF I gathered so much info that I decided to create two separated blogs for these subject.

Online available resources


Access your MDS-SOA repository from your ADF application

In our Enterprise Landscape the SOA Services and our Canonical Data Model (CDM) live on a different WebLogic Server than our ADF application. But often we want to use these services and CDM in our ADF application. 
Calling WebServices from an ADF application is not that difficult, however, we often want to manipulate the result that comes from this WebService. In 90 percent of the time, this are little adjustments to the existing CDM that are UI specific. This knowledge is not something we want to put in our CDM or in our WebService, but in the ADF application. We decided to create an UI specific XSD and map the result from the WebService in CDM to this UI specific XSD. 
To accomplish this, we created an XSD that extends the existing XSD from the CDM. The problem with this approach was to reach the XSD from the CDM that lives on the SOA Server from our ADF Application that lives on our ADF Server. 

It turns out, you can configure the MetaData Repositories on your WebLogic Server to look at different servers. When logged in to the Enterprise Manager, you can go to the MetaData Repositories, now if you click on an existing MDS, you can go through to menu to Administration -> Register/Deregister:


In here you see an overview of both the database and the file based repositories.
Now you can click the Register button to register a new database MDS repository.


This will bring up the screen to register a database based metadata repository in which you need to provide the information of your SOA MDS where the CDM is found.


After filling in the information, press query and enter the repository name ‘mds-soa’ and fill in the correct password. Pressing the OK button will register this mds-soa metadata repository and will bring up the next screen:


In here it is very important not to forget to target the correct server on which you ADF application is running.
Once this has been set up, your ADF application will be able to connect on run time to your CDM that lives inside the soa-mds repository under the /soa-infra partition. Next you need to configure your ADF application to actually look for this repository. You do this in the adf-config.xml:


In the adf-config file you see the mds-config, here you tell the application to look for any mds repository starting with /apps to look in the ‘mstore-usage_2’ this mstore is defined below in the metadata-store-usage section.
You need to enter the partition-name, which is ‘soa-infra’, the metadata-path is used locally and points to an environment variable. When deploying this application from JDeveloper, the deployment wizard understand that the MDS needs to be configured and it brings up the Deployment Configuration wizard:


In this wizard we select the mds-soa repository and select the correct repository and the correct partition. After this your ADF application will be able to resolve oramds urls and you can import XSDs from the CDM. As a result your ADF application specific XSD will be able to understand an import like this:


Meaning you can extend any XSD type defined in the CDM and make it UI specific for your needs.

Disabling and Enabling the Auto Map for XSL

When working with more complex XSL files, it can sometimes be useful to disable the Auto Map option. This can easily be achieved in the Auto Map Preferences popup you get when drawing lines in the design view of an XSL Map.


However, once disabled, you will not get this popup anymore to re-enable the Auto Map option. You need to do this through the Tools -> Preferences menu in JDeveloper. On the bottom of the list you see the XSL Maps menu with a submenu for Auto Map properties.


Here you can re-enable the Auto Map option for you XSL maps.