Unable to compile a composite that contains a Java embedded activity with Maven by Markus Lohn

 

clip_image001Problem

Maven is not compiling the composite when a BPEL process contains java embedding. Just incorporating java embedding makes the maven compilation to fail. If the java embedding is removed then the composite compilation is successful in Maven. This issue can be reproduced  with JDeveloper 12.1.3.x

Research

First I tried to solve this issue by adding dependency declarations for orabpel.jar in the soa maven plugin section and the pom.xml itself. However this approach doesn’t solve my issue. After another research in the Oracle Support system I found two interesting notes:

  • Unable to compile a composite that contains a Java embedded activity with Maven (2050971.1)
  • Failure when compiling a BPEL process in SOA 12c, ‚package com.collaxa.cube does not exist’ (2112178.1)

Both notes describe exactly the issue I currently have. The note 2050971.1 contains a reference to the bug no. 20229616 wherefore no patch is available until now. But it contains a description for a workaround. The workarounds means to put every needed Java library in the folder SOA/SCA-INF/lib. From my perspective that isn’t an appropriate solution, because the missing classes mention by the compiler are in orabpel.jar. This jar file is part of SOA Suite and already available on the infrastructure side. Moreover everything in /SCA-INF/lib is part of the composite and uploaded to MDS. The second support note 2112178.1 references a patch, but it doesn’t also solve the issue. Due to this I build a solution that automates the workaround with SOA/SCA-INF/lib by using Maven plugins.

Solution

The solutions contains 3 steps:

1. Using the Maven Dependency Plugin to copy the orabpel.jar to SOA/SCA-INF/lib folder. The copied orabpel.jar will be renamed to only4compile.jar. Further it is important to bind the execution of the plugin to a phase before running the Maven SOA Plugin. Read the complete article here.

SOA & BPM Partner Community

For regular information on Oracle SOA Suite become a member in the SOA & BPM Partner Community for registration please visit www.oracle.com/goto/emea/soa (OPN account required) If you need support with your account please contact the Oracle Partner Business Center.

Blog Twitter LinkedIn image[7][2][2][2] Facebook clip_image002[8][4][2][2][2] Wiki

ECID propagation between SCA composites and JAX-WS web services by Nicolas Fonnegra

 

clip_image002The Oracle SOA Suite provides an Audit Trail monitor screen where the message flow between the different SCA composites can be tracked. Depending on the audit level, it can provide a very detailed chronology of the different states of the message, including the first component that receives the messages, its correspondent transformation along the way, and the routing it’s final destination. Nevertheless, a SOA platform is intended to integrate not only internal composites but also external components. The question is how to maintain the audit trail consistency in such scenarios?

The Oracle A-team posted a very helpful blog demonstrating how to propagate the ECID between JCA adapter calls in order to maintain the audit trail consistency. This blog is going to demonstrate how to achieve this result with JAXWS web services.

As the reader might have already figured it out, the key to this problem relies with the ECID. The execution context id (ECID) is the mechanism the SOA Suite uses to keep track of the messages as it passes between the different components. If an SCA calls another one, it will pass through the ECID, helping the audit trail to correlate the different component instances into one flow. Also, if instead of a SCA composite a JAXWS web service, the ECID will be passed in the SOAP header, more specifically in the ReplyTo element: Read the complete article here.

SOA & BPM Partner Community

For regular information on Oracle SOA Suite become a member in the SOA & BPM Partner Community for registration please visit www.oracle.com/goto/emea/soa (OPN account required) If you need support with your account please contact the Oracle Partner Business Center.

Blog Twitter LinkedIn image[7][2][2][2] Facebook clip_image002[8][4][2][2][2] Wiki

Using JPA in SCA Spring Beans by Dusan Chromy

When using  Oracle SOA Suite 11g SCA Spring Bean components you will likely be facing a decision about how to interact with your database from within the Spring Beans. The answer will ultimately depend on your overall system architecture. For instance you may wire a Spring Bean directly to a DB adapter, or you can encapsulate the data access inside a web service or an EJB session bean. In my last project we have decided to access the data directly from the Spring Beans, taking advantage of the flexibility provided by Spring’s JDBC abstraction framework. In fact Spring makes JDBC access so simple that it is easy to miss other alternatives, one of them being especially noteworthy – the Java Persistence API.

Java Persistence API has greatly simplified the object-relational mapping in Java. Let’s have a look at how JPA can be incorporated into an SCA application.
The Service
We will create a simple service inspired by my other passion, motorcycles. The service will provide these operations:

  • createBike – creates an entity for a motorcycle with the specified manufacturer and model name and returns the entity’s ID.
  • getBikeDescription – retrieves the description of a motorcycle with the specified ID.

The Project
We start with an empty composite project and add a Spring Bean, following the code-first approach:

  • Create a Java interface for our SCA service: MotoService.java
  • Create a dummy implementation of the above interface MotoServiceImpl.java.
  • Create a Spring Context which uses the classes created in the above steps.
  • Wire the Spring Context to the Exposed Services lane – this step will generate MotoService.wsdl.

Read the complete article here.

SOA & BPM Partner Community

For regular information on Oracle SOA Suite become a member in the SOA & BPM Partner Community for registration please visit www.oracle.com/goto/emea/soa (OPN account required) If you need support with your account please contact the Oracle Partner Business Center.

Blog Twitter LinkedIn image[7][2][2][2] Facebook clip_image002[8][4][2][2][2] Wiki