Thursday, September 25, 2014

Not able to create the session in OSB console - Could not create directory /osb/config/sessions/weblogic

Sometimes we may receive the error "could not create directory <DOMAIN_HOME>/osb/config/sessions/weblogic" in the OSB console while trying to create the session.

There will be a multiple reason for this issue, in our case the root cause of the exception is the space is full for the mount  point

To resolve the issue add extra space to the mount point or clear some of the unwanted files and make the required space.

Monday, September 22, 2014

XML-22036: (Error) Cannot convert result tree fragment to NodeSet - Oracle SOA 11g

We are getting the below exception in runtime while passing the parameter and accessing the same in XSLT.

The following exception occurred while attempting to execute operation copy at line 139
-<exception class="com.collaxa.cube.xml.xpath.XPathException">
-<parsererror style="display: block; white-space: pre; border: 2px solid #c77; padding: 0 1em 0 1em; margin: 1em; background-color: #fdd; color: black">
<h3>This page contains the following errors:</h3>
<div style="font-family:monospace;font-size:12px">
error on line 7 at column 1: Extra content at the end of the document
<h3>Below is a rendering of the page up to the first error.</h3>
XPath expression failed to execute.
An error occurs while processing the XPath expression; the expression is ora:doXSLTransformForDoc('xsl/DistinctPayload.xsl', $inputVariableLocal.payload, 'FlowSubscriberVar2', $FlowSubscriberVar2).
The XPath expression failed to execute; the reason was: javax.xml.transform.TransformerException: oramds:/deployed-composites/default/PPDSOM_EventManager_rev1.0/xsl/DistinctPayload.xsl<Line 8, Column 82>: XML-22036: (Error) Cannot convert result tree fragment to NodeSet..
Check the detailed root cause described in the exception message text and verify that the XPath query is correct.

The actual issue is, the xsl:param name in the XSLT is different from the parameter name send from BPEL.

The issue got resolved after changing the xsl:param in XSLT as same as the parameter name in BPEL.

Wednesday, September 17, 2014

SCAC-50012 - Oracle SOA 11g

This error will occur most of time compiling the BPEL process with java embedded activity, If there is any issue with the java code this exception will be thrown.

We were facing the SCAC-50012 exception with the following code.

String orderID  =  ((oracle.xml.parser.v2.XMLElement) getVariableData("inputVariable","payload",'/client:process/client:input')).getFirstChild().getNodeValue();
String Title=("OrderID: " +orderID);                                        

The actual  issue with the XPATH expression specified within the single quote(copy paste issue), the compilation became successful after converting the single quotes to double quotes.

String orderID  =  ((oracle.xml.parser.v2.XMLElement) getVariableData("inputVariable","payload","/client:process/client:input")).getFirstChild().getNodeValue();
String Title=("OrderID: " +orderID);                                        

Monday, September 1, 2014

Dynamic Endpoint Implementation through DB Table –Oracle SOA

The below document explain the approach to store change the endpoints of the service dynamically.

Download Load_Balancer_Probe_SOA-INFRA.pdf

Friday, August 29, 2014

Programmatically creating Nodes in Adobe CQ

We can programmatically create the nodes in Adobe CQ5, the below code snippet will help us to create the nodes in CQ5.

private static final String DEFAULT_PRODUCTS_PATH = "/etc/commerce/products/sample";

//Get the Resource of the root node
ResourceResolver resolver = request.getResourceResolver();
Resource target = resolver.getResource(DEFAULT_PRODUCTS_PATH);

//Get the session
Session session = resource.getResourceResolver().adaptTo(Session.class);

//Create the Node
Node node = JcrUtil.createPath(DEFAULT_PRODUCTS_PATH+"/"+code, JcrConstants.NT_UNSTRUCTURED, session);

//Set the required properties
node.setProperty("name", "sample");
node.setProperty("description", "sample");

//Save the session;

While creating the NT_UNSTRUCTURED node make sure the parent folder is sling:folder, the node will not be created if the parent node is of type nt::folder.

Friday, July 25, 2014

Thursday, July 24, 2014

Cipher not initialized exception while invoking the Salesforce service through OSB

We are getting the "Cipher not initialized" exception wile invoking the Salesforce services through OSB.

We are able to invoke the URL successfully and able to receive the session id, also this exception was thrown only for a particular sandbox but the all other sandbox invocation is successful.

The "Cipher not initialized" exception will be thrown when there is no common Ciphers available between the client and server while negotiating the SSL communication.

We have raised a case with Salesforce regarding this and receive the response as "We recently upgraded our Cipher suites for SSL. To resolve the issue upgrade latest version of Java Cryptography Extension (JCE) Unlimited Strength Jurisdiction Policy Files- 6 for JDK1.6 on middleware."

After upgrading the Unlimited Strength Jurisdiction Policy Files in all the servers nodes we are able to invoke the service successfully.

Follow the below steps to resolve the issue

  • Download the Unlimited Strength Jurisdiction Policy Files from Additional Resources" section), for java 1.6 use
  • Unzip the downloaded zip 
  • Copy local_policy.jar and US_export_policy.jar to the $JAVA_HOME/jre/lib/security in all the OSB nodes.
  • Restarts the servers.
Now you will be able to invoke the service successfully.