Expand my Community achievements bar.

Dive into Adobe Summit 2024! Explore curated list of AEM sessions & labs, register, connect with experts, ask questions, engage, and share insights. Don't miss the excitement.
SOLVED

Integrate AEM and Oracle Eloqua

Avatar

Level 2

Hi All,

 

We have a requirement to integrate AEM content management system with Oracle Eloqua Campaign Management Tool.

 

I have been looking for some help over google, but unfortunately found nothing.

 

Can you please guide me how to integrate AEM with Oracle Eloqua.

 

Thanks in advance.

 

--

Regards,

Pavan Bukka.

1 Accepted Solution

Avatar

Correct answer by
Level 10

You are correct - there is no OOTB feature that will do this. You will have to write your own logic to convert the segments. 

View solution in original post

7 Replies

Avatar

Administrator

Hi

There is no integration or connector component between these two products. You would have to create a custom AEM service/Component and integrate with oracle Eloqua using its Rest API - which it supports. Here are community articles on how to hook a Restful service into AEM. To hook into a third-party service - you write an CQ OSGi bundle that contains operations that can invoke the third party service. In your custom OSGI service -- you can wrap a Java API that knows how to invoke operations of the third-party service.

 

Option 1 :-

Creating Adobe Experience Manager bundles that invoke third party Restful web services

http://helpx.adobe.com/experience-manager/using/creating-cq-bundles-consume-web.html

http://helpx.adobe.com/experience-manager/using/integrating-livecycle-cq-applications.html

Oracle eloqua Web API :- https://docs.oracle.com/cloud/latest/marketingcs_gs/OMCAB/#Developers/RESTAPI/REST-API.htm%3FTocPath...

 

Create a OSGI service or Sling Servlets and write a code to send HTTP request GET/POST in it.

Example Code :-

import org.apache.commons.httpclient.HttpClient;
import org.apache.commons.httpclient.methods.PostMethod;

String url = "http://www.google.com";
        InputStream in = null;

        try {
            HttpClient client = new HttpClient();
            PostMethod method = new PostMethod(url);

            //Add any parameter if u want to send it with Post req.
            method.addParameter("p", "apple");

            int statusCode = client.executeMethod(method);

            if (statusCode != -1) {
                in = method.getResponseBodyAsStream();
            }

 

I hope this would help you.

 

Thanks and Regards

Kautuk Sahni



Kautuk Sahni

Avatar

Level 2

Kautuk Sahni, thank you for your response.

I am facing one more problem here, let me explain.

We are receiving the Segments defined in Oracle Eloqua as JSON response, the sturcture of these Segment is different than the Segments which are defined in AEM.

So, AEM Segment manager might not understand the Segments returned from Eloqua.

Could you please let me know if there is any converter which converts the Segments returned by Eloqua to the Segments which can be understood by AEM.

I have attached some Segment xml defined defined in AEM and the JSON which we get from Eloqua.

If you see those xmls there are lot of differences in the Segment structure.

If you have any idea on how to handle this please let me know.

Thanks in advance.

Avatar

Administrator

Hi

As you are saying Eloqua is returning a JSON response.

Option1:-

We can write a JSON parser at JSP level and can use the information accordingly.

Link:- https://helpx.adobe.com/experience-manager/using/using-jsonwriter-objects-display-cq.html

 

Option2:-

Call Third party REST APIs from the component/Service and parse their response according to your need.

Link:- https://helpx.adobe.com/experience-manager/using/using-jsonwriter-objects-display-cq.html

//

HttpGet getRequest = new HttpGet("http://maps.googleapis.com/maps/api/distancematrix/json?origins=Vancouver%20BC&destinations=San%20Fr...");

            getRequest.addHeader("accept", "application/json");
 
            HttpResponse response = httpClient.execute(getRequest);
 
            if (response.getStatusLine().getStatusCode() != 200) {
                            throw new RuntimeException("Failed : HTTP error code : "
                                    + response.getStatusLine().getStatusCode());
                        }
 
            BufferedReader br = new BufferedReader(new InputStreamReader((response.getEntity().getContent())));
 
            String output;
             String myJSON="" ;
                while ((output = br.readLine()) != null) {
                    //System.out.println(output);
                    myJSON = myJSON + output;
                }
 
              
            httpClient.getConnectionManager().shutdown();
            return myJSON ;

Its all java. As we can integrate REST from java, same we can achieve with AEM. Here also we can cater any response getting from third party APIs.

 

I hope it answers your question.

 

Thanks and Regards

Kautuk Sahni 



Kautuk Sahni

Avatar

Level 2

Kautuk Sahni, thank you for your response.

The actual problem is converting the received JSON of the Segment which was defined in Eloqua, to the Segment node format of the JCR and persist in JCR at /etc/segmentation/PorjectXYZ/.

Since these two are different systems the structure of a Segment in Eloqua is different from structure of a Segment defined in JCR of the AEM.

For example, the operators used while defining a Segment in Eloqua is different from the operators being used in AEM.

Segments of Eloqua are not compatible whith AEM Segments, hence we need some converter which converts JSON of Eloqua Segments to JCR of AEM segment.

I hope you understood the problem statement, please let us know if you have any idea.

Thanks in advance.

  

Avatar

Administrator

Pavan Bukka wrote...

Kautuk Sahni, thank you for your response.

The actual problem is converting the received JSON of the Segment which was defined in Eloqua, to the Segment node format of the JCR and persist in JCR at /etc/segmentation/PorjectXYZ/.

Since these two are different systems the structure of a Segment in Eloqua is different from structure of a Segment defined in JCR of the AEM.

For example, the operators used while defining a Segment in Eloqua is different from the operators being used in AEM.

Segments of Eloqua are not compatible whith AEM Segments, hence we need some converter which converts JSON of Eloqua Segments to JCR of AEM segment.

I hope you understood the problem statement, please let us know if you have any idea.

Thanks in advance.

  

 

Hi

Please have a look at the this pld forum post:-

Link:- http://help-forums.adobe.com/content/adobeforums/en/experience-manager-forum/adobe-experience-manage...

//

Op1:-

Step 1:  convert JSON to Java object using 'GSON' or 'Jackson'

Step 2: convert java object to jcr node using 'Jcrom'

 

Op2:-

Bundle A

1. Convert JSON to Object o1 using jackson (annotation based)

2. pass o1 to bundle B

Bundle B

1. Map the object o1 to Object o2 which is annotated for Jcrom (This was needed as there was some business logic needed before storing it in nodes)

2. convert o2 to jcr nodes using JCROM (annotation based)

In this way Bundle B can accept object from any bundles. Convert/Map them to the object value which needs to be stored.

 

I hope this will help you.

Thanks and Regards

Kautuk Sahni



Kautuk Sahni

Avatar

Level 2

Kautuk Sahni, thank you for your response.

If i follow this approach i will have to write my conversion logic, if the Segments defined Eloqua are complex converting them to JCR node is difficult.

I just wanted know if there is already some conversion engine available which can take care of doing this conversion.

Regards,

Pavan Bukka.

Avatar

Correct answer by
Level 10

You are correct - there is no OOTB feature that will do this. You will have to write your own logic to convert the segments.