Extending AIA Services Extending Existing Transformations in AIA

Working with AIA Design Patterns 25-15 Solution To allow you to extend the EBO or Enterprise Business Message EBM schemas in a nonintrusive manner, the complex type defined for every business component and the common component present in each of the EBO or EBM schemas has an extension placeholder element called Custom at the end. The data type for this custom element is defined in the schema modules allocated for holding customer extensions in the custom EBO schema files. In Example 25–1 the custom element added at the end of the complex type in the Schema-A acts as a place holder to bring the customer extensions added in the Custom Schema-A. Here the Schema- A is AIAComponents\EnterpriseObjectLibrary\Industry\Telco\EBO\ CustomerParty\V2\CustomerPartyEBO.xsd Example 25–1 Custom Element Acting as Placeholder xsd:complexType name=CustomerPartyAccountContactCreditCardType xsd:sequence xsd:element ref=corecom:Identification minOccurs=0 xsd:element ref=corecom:CreditCard minOccurs=0 xsd:element name=Custom type=corecustomerpartycust:CustomCustomerPartyAccountContactCreditCardType minOccurs=0 xsd:sequence xsd:attribute name=actionCode type=corecom:ActionCodeType use=optional xsd:complexType Example 25–2 shows the Custom Schema - A: AIAComponents\EnterpriseObjectLibrary\Industry\Telco\Custom\ EBO\CustomerParty\V2\CustomCustomerPartyEBO.xsd Example 25–2 Adding an Extension to EBO or EBM Schemas -- ================================================================== -- -- ============== CustomerParty Custom Components ================ -- -- ============================================================ -- xsd:complexType name=CustomCustomerPartyAccountAttachmentType xsd:complexType name=CustomCustomerPartyAccountContactType xsd:complexType name=CustomCustomerPartyAccountContactCreditCardType -- CUSTOMERS CAN ADD EXTENSIONS HERE ... xsd:complexType xsd:complexType name=CustomCustomerPartyAccountContactUsageType

25.3.2 Extending AIA Services

Problem The delivered services may not be sufficient to address some of your specific business functionality. You may want to add some validation logic, enrich the existing content in the service, or add some processing logic in between the existing service implementation. Adding this logic in the existing service code would not ensure upgrade safety because the upgrade process would overwrite the existing service code 25-16 Developers Guide for Oracle Application Integration Architecture Foundation Pack with new functionality added as part of the upgrade. So, there is a need for a service extension model. Solution AIA recommends introducing various extension points at logical points during the service implementation. Figure 25–11 illustrates that there are four logical extension points identified in the ABCS to perform customer-specific validations, content enrichment or message alteration, and any additional logic that you would like to implement with the given payload at that extension point. Typically there are two pre-processing and two post-processing extension points identified: pre-processing ABM, post-processing ABM, pre-processing EBM and post-processing EBM. The number of extension points may be more or less than four depending on the type of service implementation and the type of message exchange pattern used by that service. These extension points can be enabled or disabled based on whether you want to implement those custom extension points. Figure 25–11 Extending AIA Services Working with AIA Design Patterns 25-17

25.3.3 Extending Existing Transformations in AIA

Problem The delivered transformations with existing schemas may not be sufficient for some of your specific business operations. You may want to add elements to the existing schemas and then add transformation maps for the newly added elements to transfer the information from one application to the other in an upgrade safe manner. This would not be possible by just adding the customer-specific transformations in an existing XSL files so the transformations extension model is needed. Solution To extend the transformations in a nonintrusive manner, the call template statement is defined for every business component mapping present in each of the XSL transformation files which calls the Custom Template defined in the custom XSL transformation. Example 25–3 is the example to add new transformations for the custom elements added by the customer: The main XSL mapping XformListOfCmuAccsyncAccountIoToCreateCustomerPartyListEBM.xsl would import the custom XSL file and have call template statement to the extension template for each complex type or business component like this: Example 25–3 Adding New Transformations for Customer-defined Custom Elements ?xml version = 1.0 encoding = UTF-8? ..……………………………………….. xmlns:dvm=http:www.oracle.comXSLTransformjavaoracle.tip.dvm.LookupValue xsl:import href=XformListOfCmuAccsyncAccountIoToCreateCustomerPartyListEBM_ Custom.xsl ..……………………………………….. xsl:value-of select=aia:getServicePropertyConfigServiceName, Routing.CustomerPartyEBS.CreateCustomerPartyList.CAVS.EndpointURI, false corecom:DefinitionID xsl:if xsl:call-template name=MessageProcessingInstructionType_ext xsl:with-param name=currentNode select=. xsl:call-template corecom:MessageProcessingInstruction Example 25–4 shows the custom XSL file that has the template definition where you can add your custom mappings for the newly added custom elements or existing elements which are not mapped in the main transformation. Example 25–4 Custom XSL Template Definition -- HEADER CUSTOMIZATION -- xsl:template name=MessageProcessingInstructionType_ext xsl:template name=EBMHeaderType_ext xsl:param name=currentNode -- Customers add transformations here -- xsl:template xsl:param name=currentNode -- Customers add transformations here -- xsl:template 25-18 Developers Guide for Oracle Application Integration Architecture Foundation Pack -- DATA AREA CUSTOMIZATION -- xsl:template name=ContactType_ext xsl:param name=currentNode -- Customers add transformations here -- xsl:template

25.3.4 Extending the Business Processes in AIA