+ All Categories
Home > Technology > Deploying to Oracle SOA Suite 12c - Everything You Need To Know

Deploying to Oracle SOA Suite 12c - Everything You Need To Know

Date post: 15-Apr-2017
Category:
Upload: raastech
View: 1,889 times
Download: 0 times
Share this document with a friend
75
Raastech, Inc. 2201 Cooperative Way, Suite 600 Herndon, VA 20171 +1-703-884-2223 [email protected] Deploying to Oracle SOA Suite 12c Everything You Need To Know Monday, December 7, 2015 12:20 - 13:10 Media Suite B
Transcript
Page 1: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

Raastech, Inc.2201 Cooperative Way, Suite 600Herndon, VA [email protected]

Deploying to Oracle SOA Suite 12cEverything You Need To Know

Monday, December 7, 201512:20 - 13:10

Media Suite B

Page 2: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 2 of 75@Raastech

Agenda

1. Introductions

2. SOA Composites

3. OSB Projects

4. BAM Objects

5. MDS Artifacts

6. Alternatives

7. Final Thoughts

Page 3: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 3 of 75@Raastech

Page 4: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 4 of 75@Raastech

About Me

Ahmed Aboulnaga @Ahmed_Aboulnaga

18+ years Oracle experience

Author of “Oracle SOA Suite 11g Administrator’s Handbook”

Author of “Oracle SOA Suite 12c Administrator’s Guide”

OCE (SOA Foundation Practitioner)

OCE (Oracle SOA Architect)

Oracle ACE

Page 5: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 5 of 75@Raastech

About Raastech

Small systems integrator founded in 2009

Headquartered in the Washington DC area

Specializes in Oracle Fusion Middleware

Oracle Platinum Partner 1 in 3,000 worldwide

Oracle SOA Specialized 1 in 1,500 worldwide

Oracle ACEs 2 in 600 worldwide

Page 6: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 6 of 75@Raastech

Why This Presentation

For the administrator

Detail actual deployment instructions in hopes of lowering complexity

Discuss some alternatives

Page 7: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 7 of 75@Raastech

Page 8: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 8 of 75@Raastech

Through Oracle Enterprise Manager Fusion Middleware Control

Must have the JAR file ready to go

Console

Page 9: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 9 of 75@Raastech

Entry logged in soa_server1.out

Service becomes available immediately

– Web service immediately available

– Inbound service starts consuming immediately

Console

[2015-02-01T16:13:18.092-05:00] [soa_server1] [NOTIFICATION]

[] [oracle.integration.platform.blocks.deploy] [tid:

DaemonWorkThread: '2' of WorkManager: 'wm/SOAWorkManager']

[userId: <anonymous>] [ecid: 9027493d-b37d-4795-a996-

331a7c6ae275-00000004,0:513] [APP: soa-infra] Publishing

deploy event for default/HelloWorld!1.0*soa_d91d1c4c-7a7b-

4405-9b6e-6dd5a053bfbb

Page 10: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 10 of 75@Raastech

Create setAntEnv.sh

Ant | Step 1: Create 1-Time Environment Script

export USERNAME=weblogic

export PASSWORD=welcome1

export SOAHOST=soahost1

export SOAPORT=8001

export SOAURL=http://${SOAHOST}:${SOAPORT}

export CODE=/home/oracle/code

export MW_HOME=/u01/app/oracle/middleware

export ORACLE_HOME=$MW_HOME/soa

export JAVA_HOME=$MW_HOME/jdk1.7.0_15

export ANT_HOME=$MW_HOME/oracle_common/modules/org.apache.ant_1.9.2

export PATH=$JAVA_HOME/bin:$ANT_HOME/bin:$ANT_HOME/lib:$PATH:.

Page 11: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 11 of 75@Raastech

Package composite

Ant | Step 2: Package Composite

cd $ORACLE_HOME/bin

ant -f ant-sca-package.xml package

-DcompositeDir=$CODE/HelloW/SOA

-DcompositeName=HelloW

-Drevision=1.0

Page 12: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 12 of 75@Raastech

Deploy composite

Ant | Step 3: Deploy Composite

ant -f ant-sca-deploy.xml deploy

-DserverURL=$SOAURL/soa-infra/deployer

-Duser=$USERNAME

-Dpassword=$PASSWORD

-DsarLocation=$CODE/HelloW/SOA/deploy/sca_HelloW_rev1.0.jar

-Dpartition=default

-Doverwrite=true

-DforceDefault=true

Page 13: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 13 of 75@Raastech

WebLogic Scripting Tool

Set environment and connect to WLST

WLST | Step 1: Start WLST Shell

export MW_HOME=/u01/app/oracle/middleware

export ORACLE_HOME=$MW_HOME/soa

cd $ORACLE_HOME/bin

$ORACLE_HOME/common/bin/wlst.sh

wls:/offline>

wls:/offline>connect()

Page 14: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 14 of 75@Raastech

Package composite

Deploy composite

WLST | Step 2: Package and Deploy with WLST

sca_package ("/home/oracle/code/HelloW/SOA",

"HelloW",

"1.0",

oracleHome="/u01/app/oracle/middleware/soa")

sca_deployComposite ("http://soahost1:8001",

"/home/oracle/code/HelloW/SOA/deploy/sca_HelloW_rev1.0.jar",

true,

user="weblogic",

password="welcome1",

partition="default")

Page 15: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 15 of 75@Raastech

WLST commands actually call underlying Ant scripts

Must use the HTTP protocol

WLST Considerations

Page 16: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 16 of 75@Raastech

Promoting code to higher environments may require modifying URLs

FYI: Configuration plans don’t work with XSLT artifacts

Configuration Plans

Page 17: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 17 of 75@Raastech

Configuration Plans: The Code

<reference name="HelloWorldBPEL_BPEL"

ui:wsdlLocation="http://soa12cdev:8001/soa-infra/services/default/HelloWorldBPEL/HW.wsdl">

<interface.wsdl interface="http://xmlns.oracle.com/SOA12c/HelloWorldBPEL/HW#wsdl.interface(HW)"/>

<binding.ws port="http://xmlns.oracle.com/SOA12c/HelloWorldBPEL/HW#wsdl.endpoint(hw_client_ep/hw_pt)"

location="http://soa12cdev:8001/soa-infra/services/default/HelloWorldBPEL/hw_client_ep?WSDL"

soapVersion="1.1">

<property name="weblogic.wsee.wsat.transaction.flowOption"

type="xs:string" many="false">WSDLDriven</property>

</binding.ws>

</reference>

<reference name="HelloWorld_BPEL"

ui:wsdlLocation="http://soa12cDEV:8001/soa-infra/services/default/HelloWorldBPEL/HW.wsdl">

<interface.wsdl interface="http://xmlns.oracle.com/SOA12c/HelloWorldBPEL/HW#wsdl.interface(HW)"/>

</reference>

composite.xml

Mediator1.componentType

Page 18: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 18 of 75@Raastech

Configuration Plans: The Test Plan

<?xml version="1.0" encoding="UTF-8"?>

<SOAConfigPlan xmlns:jca="http://platform.integration.oracle/blocks/adapter/fw/metadata" ... >

<composite name="*">

<import>

<searchReplace>

<search>http://soa12cDEV:8001</search>

<replace>http://soa12cTEST:8001</replace>

</searchReplace>

</import>

<reference name="*">

<binding type="ws">

<attribute name="location">

<searchReplace>

<search>http://soa12cDEV:8001</search>

<replace>http://soa12cTEST:8001</replace>

</searchReplace>

</attribute>

</binding>

</reference>

</composite>

</SOAConfigPlan>

cfgplan_test.xml

Page 19: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 19 of 75@Raastech

Configuration Plans: The Test Plan

<import>

<searchReplace>

<search>http://soa12cDEV:8001</search>

<replace>http://soa12cTEST:8001</replace>

</searchReplace>

</import>

<reference name="*">

<binding type="ws">

<attribute name="location">

<searchReplace>

<search>http://soa12cDEV:8001</search>

<replace>http://soa12cTEST:8001</replace>

</searchReplace>

</attribute>

</binding>

</reference>

cfgplan_test.xml

Page 20: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 20 of 75@Raastech

Deploy composite

Ant – Using a Configuration Plan

ant -f ant-sca-deploy.xml deploy

-DserverURL=$SOAURL/soa-infra/deployer

-Duser=$USERNAME

-Dpassword=$PASSWORD

-DsarLocation=$CODE/HelloW/SOA/deploy/sca_HelloW_rev1.0.jar

-Dpartition=default

-Doverwrite=true

-DforceDefault=true

-Dconfigplan=/tmp/cfgplan_test.xml

Page 21: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 21 of 75@Raastech

Page 22: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 22 of 75@Raastech

Through Oracle Service Bus Console (http://host:7001/servicebus)

Must have the JAR file ready to go

Right-click on “All Projects” and navigate to “Import > Config Jar”

Console

Page 23: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 23 of 75@Raastech

Console only deployment? Really?!

Page 24: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 24 of 75@Raastech

WLST | Step 1: Set Up Environment

Page 25: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 25 of 75@Raastech

WLST | Step 2: Create Customization File

Page 26: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 26 of 75@Raastech

WLST | Step 3: Create Property File

Page 27: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 27 of 75@Raastech

WLST | Step 4: Download import.py

Page 28: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 28 of 75@Raastech

WLST | Step 5: Import OSB Service

Page 29: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 29 of 75@Raastech

Similar to configuration plans for SOA composites

Not a search-replace like SOA configuration plans, but rather a

‘replace’ only

OSB Customization Files

Page 30: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 30 of 75@Raastech

OSB Customization Files

<cus:customization xsi:type="cus:EnvValueActionsCustomizationType">

<cus:actions>

<xt:replace>

<xt:envValueType>Service URI Table</xt:envValueType>

<xt:value xsi:type="tran:URITableType" xmlns:tran="http://www.bea.com/wli/sb/transports">

<tran:tableElement>

<tran:URI>jms://soa12cDEV:8001/weblogic.jms.XAConnectionFactory/jms/OrderQ</tran:URI>

</tran:tableElement>

</xt:value>

</xt:replace>

<xt:replace>

<xt:envValueType>Service Retry Count</xt:envValueType>

<xt:value xsi:type="xs:string" xmlns:xs="http://www.w3.org/2001/XMLSchema">3</xt:value>

</xt:replace>

</cus:actions>

</cus:customization>

Page 31: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 31 of 75@Raastech

Initially create a customization file through the OSB Console

Click on “Admin” then “Create Configuration File”

OSB Customization Files – Creating

Page 32: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 32 of 75@Raastech

Apply a customization file through the OSB Console post-deployment

Click on “Create” then “Admin” then “Execute Configuration File”

OSB Customization Files – Applying via Console

Page 33: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 33 of 75@Raastech

Page 34: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 34 of 75@Raastech

BAM development begins on the server (i.e., via the BAM Console)

Deployment involves exporting then importing

BAM artifacts include: data objects, business queries, KPIs, business

views, dashboards, alerts, parameters

BamCommand (12c) is the successor of ICommand (10g/11g)

To migrate between major releases:

http://docs.oracle.com/middleware/1213/core/FUPSS/bam.htm#FUPSS256

BAM Deployment Overview

Page 35: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 35 of 75@Raastech

Step 1: Set up Environment

export CODE=/home/oracle/bamcode

export MW_HOME=/u01/app/oracle/middleware

export JAVA_HOME=$MW_HOME/jdk1.7.0_15

export PATH=$MW_HOME/soa/bam/bin:$PATH:.

Create setBAMEnv.sh

Page 36: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 36 of 75@Raastech

Step 2: Update Configuration File

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>

<BAMCommandConfig>

<host>bamhost1</host>

<port>9001</port>

<username>weblogic</username>

<password>welcome1</password>

<!-- Below fields only needed when using -migrate -->

<dbusername>DEV_SOAINFRA</dbusername>

<dbpassword>welcome1</dbpassword>

<dburl>jdbc:oracle:thin:@soadb:1521:orcl</dburl>

</BAMCommandConfig>

Edit BAMCommandConfig.xml

Located in $MW_HOME/soa/bam/bin

Page 37: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 37 of 75@Raastech

Step 3: Export/Import BAM Artifacts

source setBAMEnv.sh

bamcommand -cmd export -name "Hello/World" -file "$CODE/World.zip"

bamcommand -cmd import -file "$CODE/World.zip"

In 12c, it no longer needed to explicitly specify the object type

Page 38: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 38 of 75@Raastech

BAM Command File

vi command.xml

<?xml version="1.0" encoding="utf-8"?>

<OracleBAMCommands continueonerror="1">

<Export name="Test/Hello World" file="Hello World.xml" contents="0" />

<Rename name="Test/Foo" newdisplayname="Bar" />

<Delete type="EMS" name="ApacheLog" />

</OracleBAMCommands>

source setBAMEnv.sh

bamcommand -cmdfile "command.xml"

Perform multiple operations using the BAM command file

Limited to <Export>, <Delete>, and <Rename>

Page 39: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 39 of 75@Raastech

Page 40: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 40 of 75@Raastech

Shared XSD, WSDL, DVM, WADL, XQuery, and XML files are stored in the MDS

Accessible via the ORAMDS protocol from the code. For example:

Local DVM in XSL file:dvm:lookupValue("LANGUAGECODE.dvm", "EBIZ", "", "RETAIL", "")

Shared DVM in XSL file:dvm:lookupValue("oramds:/apps/AIAMetaData/dvm/LANGUAGECODE.dvm",

"EBIZ", "", "RETAIL", "")

Local XSD in WSDL file:<xsd:import namespace="http://xmlns.oracle.com/bpel"

schemaLocation="xsd/Customer.xsd"/>

Shared XSD in WSDL file:<xsd:import namespace="http://xmlns.oracle.com/bpel"

schemaLocation="oramds:/apps/shared/Customer.xsd"/>

What are MDS artifacts?

Page 41: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 41 of 75@Raastech

Step 1: Exporting MDS Artifacts

source setAntEnv.sh

cd $ORACLE_HOME/bin

ant -f ant-sca-deploy.xml exportSharedData

-DserverURL=$SOAURL/soa-infra/deployer

-Duser=$USERNAME

-Dpassword=$PASSWORD

-DjarFile=SOAMetaData.jar

-Dpattern=**

Output is a SOAMetaData.jar file

Page 42: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 42 of 75@Raastech

Step 1: Defining Patterns

For example:

/apps/SOAMetaData/dvm/**

/apps/SOAMetaData/faultPolicies/**

**

Delimiter is ;

Page 43: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 43 of 75@Raastech

Step 2: Zip Local Content to SOAMetaData.jar

cd /tmp/svn

zip -r SOAMetaData.jar SOAMetaData

Page 44: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 44 of 75@Raastech

Step 3: Import to MDS

source setAntEnv.sh

cd $ORACLE_HOME/bin

ant -f ant-sca-deploy.xml deploy

-Dwl_home=$MW_HOME/wlserver

-Doracle.home=$ORACLE_HOME

-DserverURL=$SOAURL/soa-infra/deployer

-Duser=$USERNAME

-Dpassword=$PASSWORD

-Doverwrite=true

-DforceDefault=true

-DsarLocation=SOAMetaData.jar

Page 45: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 45 of 75@Raastech

Transfer to MDS from JDeveloper

* Screenshots courtesy of https://technology.amis.nl/2014/06/27/soa-suite-12c-deploying-shared-artifacts-to-run-time-mds-the-official-approach-and-the-quick-short-cut

Page 46: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 46 of 75@Raastech

Page 47: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 47 of 75@Raastech

Custom Developed Solution – MDS Artifacts

Page 48: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 48 of 75@Raastech

Custom Developed Solution – Oracle SOA Suite

Page 49: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 49 of 75@Raastech

Custom Developed Solution – Oracle SOA Suite

build,MyApp-Release1.1

MDS,Ahmed.xsd,mds/ApplicationObjectLibrary/Common,129

SOA,HelloWorldBPEL,default,1.0,true,soa/trunk/HelloWorldBPEL,126

OSB,HelloWorldOSB.jar,osb/trunk/HelloWorldOSB,527

DEP,Create JMS distributed queue: jms/OrderQ

SQL,sql/trunk/CreateErrorTable.sql,527

BAM,/Project1/ErrorDO,bam/trunk/ErrorDO.xml,dataobject,true,527

BAM,/public/Report/Error Report,bam/trunk/Report1.xml,report,false,549

BAM,/private:usr/Rule/My Alert/Error,bam/trunk/Error.xml,rule,false,919

Deploy List; creates a bundled deployment

Page 50: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 50 of 75@Raastech

Custom Developed Solution – Oracle SOA Suite

Page 51: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 51 of 75@Raastech

Custom Developed Solution – Oracle SOA Suite

Page 52: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 52 of 75@Raastech

Custom Developed Solution – Oracle SOA Suite

Page 53: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 53 of 75@Raastech

Custom Developed Solution – Oracle SOA Suiteoracle@soadevhost:/home/oracle/deploy> ./deploy.sh soa-dev

╔══════════════════════════════════════════════════════════════════════════════╗

║ Deployment Process Started ║

╚══════════════════════════════════════════════════════════════════════════════╝

┌───────────────────────────────────────────────────────────────────────────────

│ Deployment Facts

├───────────────────────────────────────────────────────────────────────────────

│ TARGET: soa-dev

│ LOGS HOME: /home/oracle/deploy/log_logs/deploy.sh_20151126_190104_18088

│ PROCESS_LIST: /home/oracle/deploy/CodeList.txt

└───────────────────────────────────────────────────────────────────────────────

┌───────────────────────────────────────────────────────────────────────────────

│ SOA build START for row #1

├───────────────────────────────────────────────────────────────────────────────

│ CHECKOUT: HelloWorld

│ ERROR: Unable to checkout. Check: /home/oracle/deploy/log_logs/deploy.sh_20151126_190121_1348/01_checkout.log log file for errors.

│ USER INPUT: Continue remaining deployments yes or no? [N]Y

├───────────────────────────────────────────────────────────────────────────────

│ SOA build COMPLETE for row #1

└───────────────────────────────────────────────────────────────────────────────

┌───────────────────────────────────────────────────────────────────────────────

│ Build Cleanup Started

├───────────────────────────────────────────────────────────────────────────────

│ USER INPUT: Remove build logs yes or no? [Y]N

├───────────────────────────────────────────────────────────────────────────────

│ Build Cleanup Completed

└───────────────────────────────────────────────────────────────────────────────

Page 54: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 54 of 75@Raastech

Custom Developed Solution – Oracle SOA Suiteoracle@soadevhost:/home/oracle/deploy> ./deploy.sh soa-dev

╔══════════════════════════════════════════════════════════════════════════════╗

║ Deployment Process Started ║

╚══════════════════════════════════════════════════════════════════════════════╝

┌───────────────────────────────────────────────────────────────────────────────

│ Deployment Facts

├───────────────────────────────────────────────────────────────────────────────

│ TARGET: soa-dev

│ LOGS HOME: /home/oracle/deploy/log_logs/deploy.sh_20151126_190145_5390

│ PROCESS_LIST: /home/oracle/deploy/CodeList.txt

└───────────────────────────────────────────────────────────────────────────────

┌───────────────────────────────────────────────────────────────────────────────

│ SOA build START for row #1

├───────────────────────────────────────────────────────────────────────────────

│ CHECKOUT: HelloWorld

│ DETOKENIZE: HelloWorld

│ DEPLOY: HelloWorld

├───────────────────────────────────────────────────────────────────────────────

│ SOA build COMPLETE for row #1

└───────────────────────────────────────────────────────────────────────────────

┌───────────────────────────────────────────────────────────────────────────────

│ Build Cleanup Started

├───────────────────────────────────────────────────────────────────────────────

│ USER INPUT: Remove build logs yes or no? [Y]N

├───────────────────────────────────────────────────────────────────────────────

│ Build Cleanup Completed

└───────────────────────────────────────────────────────────────────────────────

Page 55: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 55 of 75@Raastech

http://flexagon.com/category/flexdeploy/

FlexDeploy from

Page 56: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 56 of 75@Raastech

Maven Plug-In

Oracle SOA Suite Maven plug-in

Requires a POM (Project Object Model) file (pom.xml)

Maven plug-in goals:

– compile (scac)

– package (sar)

– deploy

– test (sca-test)

– undeploy

Maven 3.0.5 included in Oracle Fusion Middleware installation here:

$MW_HOME/Oracle_Home/oracle_common/modules/org.apache.maven_3.0.5

Page 57: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 57 of 75@Raastech

Maven – Project

Page 58: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 58 of 75@Raastech

Maven – Compilation

Page 59: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 59 of 75@Raastech

Maven – Deployment

Page 60: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 60 of 75@Raastech

Maven – OSB App from a Maven Archetype

To create a new Oracle Service Bus application (containing an OSB

Project and an OSB System Resources project) using the OSB

Application Maven archetype, execute a command similar to the

following:

mvn archetype:generate

-DarchetypeGroupId=com.oracle.servicebus

-DarchetypeArtifactId=oracle-servicebus-application

-DarchetypeVersion=12.1.3-0-0

-DgroupId=org.mycompany

-DartifactId=my-servicebus-application

-Dversion=1.0-SNAPSHOT

-DprojectName=my-project

Page 61: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 61 of 75@Raastech

Maven – OSB App from a Maven Archetype

After creating your application, it contains the following files:

Page 62: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 62 of 75@Raastech

Maven – OSB App from a Maven Archetype

To build the SBAR file, execute the following command:

The preceding command creates an SBAR file from your project and

places it in:

To deploy the SBAR file, execute the following command:

mvn package -DoracleHome=/path/to/osbhome

project/.data/maven/sbconfig.sbar

mvn pre-integration-test

-DoracleServerUrl=http://osbdev:7001

-DoracleUsername=weblogic

-DoraclePassword=welcome1

Service Bus archive

Page 63: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 63 of 75@Raastech

Why Maven?

Maven better at managing dependencies (and can download

dependencies over the network)

Ant is better at controlling of build process

Ant adopted Apache Ivy to help in dependency management– http://ant.apache.org/ivy/

When to use Maven When to use Ant

Large team of “creative” developers and need structure

No need for fine-grained dependency management

Building a product-like application Quick or one-off development

Many dependent modules Not much modularized code

Page 64: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 64 of 75@Raastech

Maven | Some Cool Links

https://redstack.wordpress.com/2014/10/22/soa-12c-maven-

demonstration-from-openworld-2014/

http://biemond.blogspot.nl/2014/06/maven-support-for-1213-service-

bus-soa.html

https://svgonugu.wordpress.com/2015/02/18/soa-12c-using-maven-for-

soa-projects-deployment/

* Maven screenshots borrowed from the links above

Page 65: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 65 of 75@Raastech

Ant Tokenization/Detokenization

<reference name="HelloWorldBPEL_BPEL"

ui:wsdlLocation="@SOAServer@/soa-infra/.../>

<interface.wsdl interface="http://xmlns.oracle.com/SOA12c/.../>

<binding.ws port="http://xmlns.oracle.com/SOA12c/HelloWorldBPEL/..."

location=" @SOAServer@/soa-infra/services/..."

soapVersion="1.1">

<property name="weblogic.wsee.wsat.transaction.flowOption"

type="xs:string" many="false">WSDLDriven</property>

</binding.ws>

</reference>

Developers tokenize code before checking it in

Page 66: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 66 of 75@Raastech

Ant Tokenization/Detokenization

<reference name="HelloWorldBPEL_BPEL"

ui:wsdlLocation="http://soa12cdev:8001/soa-infra/.../>

<interface.wsdl interface="http://xmlns.oracle.com/SOA12c/.../>

<binding.ws port="http://xmlns.oracle.com/SOA12c/HelloWorldBPEL/..."

location="http://soa12cdev:8001/soa-infra/services/..."

soapVersion="1.1">

<property name="weblogic.wsee.wsat.transaction.flowOption"

type="xs:string" many="false">WSDLDriven</property>

</binding.ws>

</reference>

Admins detokenize code before packaging/deployment

Page 67: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 67 of 75@Raastech

Ant Tokenization/Detokenization

Use standard Any replace functionality to tokenize/detokenize code

ant -f build.soa.xml detokenizeComposites -Dtargetenv=${env}

Can apply to all file types

<replace dir="${svn.localdir}/soa/${folder.name}" summary="true">

<include name="**/*.xsd"/>

<include name="**/*.XSD"/>

.

.

<replacefilter token="@SOAServer@" value="${SOAServer}"/>

<replacefilter token="@OSBServer@" value="${OSBServer}"/>

.

.

</replace>

Page 68: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 68 of 75@Raastech

Ant Tokenization/Detokenization

Ant script reads a token file

<property file="${basedir}/props/soa-token-${targetenv}.props"/>

Property file for each environment maintains all values

Used in lieu of configuration plans and customization files

Single token file can apply to SOA, OSB, etc. projects.

SOAServer = http://soadev:8001

OSBServer = http://soadev:8011

SOAServerJMS = jms://soadev:8001

MDSSchema = dev_mds

MDSPassword = welcome1

Page 69: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 69 of 75@Raastech

Page 70: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 70 of 75@Raastech

Offline deployments

– While the AdminServer and managed servers are down

– Deployment done at startup

Bundle deployments

– Cannot control deployment order, so don’t lump dependent SARs

New in Oracle SOA Suite 12c

Page 71: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 71 of 75@Raastech

SOA composite deployment – Ant the way to go

OSB service deployment – No choice but WLST

BAM object deployment – Fortunately simple

MDS artifact import – Don’t forget about this!

Build a reusable front-end to your scripts, or consider a product such

as FlexDeploy

Undeployments not detailed here, but very similar in concept

Recap

or Maven

Page 72: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 72 of 75@Raastech

Consistentizing (“to make consistent”, real word?) the

detokenization and deployment of SOA, OSB, BAM, and

MDS is unfortunately impossible, but think along the lines of

a single property file

Have to worry about new components such ESS and ORIBA

(Oracle Realtime Integration Business Analytics)

Just get a tool… don’t waste your time reinventing the wheel

Maven will pick up steam

Final Thoughts

Oracle needs to drive this

Page 73: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 73 of 75@Raastech

This presentation is based off of

Chapter 5 of Oracle SOA Suite 12c

Administrator’s Guide

https://www.packtpub.com/applicatio

n-development/oracle-soa-suite-

12c-administrators-guide

My Book

Page 74: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 74 of 75@Raastech

Contact Information

Ahmed Aboulnaga

Technical Director

@Ahmed_Aboulnaga

[email protected]

Page 75: Deploying to Oracle SOA Suite 12c - Everything You Need To Know

© Raastech, Inc. 2015 | All rights reserved. Slide 75 of 75@Raastech

Q&A


Recommended