Skip Headers
Oracle® Application Server Adapter for SAP User's Guide
10g Release 3 (10.1.3.1.0)

Part Number E10044-01
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Index
Index
Go to Master Index
Master Index
Go to Feedback page
Contact Us

Go to previous page
Previous
Go to next page
Next
View PDF

2 Configuring OracleAS Adapter for mySAP ERP

This chapter describes how to use OracleAS Adapter Application Explorer (Application Explorer) to define a target to connect to a MySAP ERP system, view system objects, and create XML schemas and Web services. This chapter also explains how to configure an event adapter.

This chapter discusses the following topics:

Starting Application Explorer

To start Application Explorer:

  1. Start the server where Application Explorer is deployed.

  2. From the Windows Start menu, select Programs, OracleAS_home Adapters, and then Application Explorer.

    On Windows, iaexplorer.bat is located under OracleAS_home\adapters\application\tools, where OracleAS_home is the directory where Oracle Application Server is installed.

    On UNIX, load the script iwae.sh, located under OracleAS_home/adapters/application/tools, where OracleAS_home is the directory where Oracle Application Server is installed.

    Application Explorer starts. You can now define new targets to your mySAP ERP system.

Configuring Settings for BSE or J2CA

You need not configure BSE for a file-based repository because it is configured during the Oracle installation. You also need not configure the OracleAS Adapter J2CA because the ra.xml file is configured automatically during installation.

Configuring BSE

After BSE is deployed to Oracle Application Server, you can configure it through the BSE configuration page. This configuration is required only when using a database repository with BSE.

Note:

Do not use a file repository for BSE in production environments.

To configure BSE:

  1. Display the following page in your browser:

    http://hostname:port/ibse
    
    

    Where hostname is the machine where BSE is installed and port is the HTTP port for Oracle Application Server.

    For example,

    http://localhost:7777/ibse
    

Note:

If you are accessing this page for the first time, it may take longer to load.
  1. Log on when prompted.

    When first installed, the user ID and password are:

    • User name: iway

    • Password: iway

The BSE configuration page is displayed.

Business Services Engine configuration page.
Description of the illustration bse_config.gif

  1. Ensure that the Adapter Lib Directory parameter specifies the path to the lib directory, for example:

    OracleAS_home\adapters\application\lib
    
    

    Where OracleAS_home is the directory where Oracle Application Server is installed.

    After you specify the path, adapters in the lib directory are available to BSE.

  1. For security purposes, enter a new password in the Admin Password field.

Note:

The Repository URL field specifies where the file system repository is located. To use a database repository, you must enter the repository connection information. For the initial verification, use a file system repository. See "Configuring an Oracle Repository" for information on switching to a database repository.
  1. Click Save.

Configuring BSE System Settings

To configure BSE system settings:

  1. Display the BSE configuration page in a browser:

    http://hostname:port/ibse/IBSEConfig
    
    

    Where hostname is the machine where BSE is installed and port is the port number on which BSE is listening.

Note:

The server to which BSE is deployed must be running.

The BSE settings pane is displayed, as shown in the following figure.

BSE configuration page
Description of the illustration ibse_config_page.gif

  1. Configure the system settings.

    The following table lists the parameters with descriptions of the information to provide.

    Parameter Description
    Language Specify the required language.
    Adapter Lib Directory Enter the full path to the directory where the adapter jar files reside.
    Encoding Only UTF-8 is supported.
    Debug Level Specify the debug level from one of the following options:
    • None

    • Fatal

    • Error

    • Warning

    • Info

    • Debug

    Number of Async. Processors Select the number of asynchronous processors.

    The following image shows the Security pane.

    BSE security settings
    Description of the illustration security.gif

  2. Configure the security settings.

    The following table lists the parameters with descriptions of the information to provide.

    Parameter Description
    Admin User Provide a BSE administrator ID.
    Admin Password Enter the password associated with the BSE administrator ID.
    Policy Select the check box to enable policy security.

    The following image shows all fields and check boxes for the Repository pane.

    BSE repository settings
    Description of the illustration ibse_config_repos_loc.gif

  3. Configure the repository settings.

    BSE requires a repository to store transactions and metadata required for the delivery of Web services.

    See "Configuring a File System Repository" and "Configuring an Oracle Repository" for more information.

    The following table lists the parameters with descriptions of the information to provide.

    Parameter Description
    Repository Type Select one of the following repositories from the list:
    • Oracle

    • File (Do not use for BSE in production environments.)

    Repository URL Enter the URL to use when opening a connection to the database.
    Repository Driver Provide the driver class to use when opening a connection to the database (optional).
    Repository User Enter the user ID to use when opening a connection to the database.
    Repository Password Enter the password associated with the user ID.
    Repository Pooling Select the check box to enable pooling.

  4. Click Save.

Configuring a File System Repository

If you do not have access to a database for the repository, you can store repository information in an XML file on your local machine. However, a file system repository is less secure and efficient than a database repository. When BSE is first installed, it is automatically configured to use a file system repository.

Note:

Do not use a file repository for BSE in production environments.

The default location for the repository on Windows is:

OracleAS_home\j2ee\OC4J_CONTAINER\applications\ws-app-adapter \ibse\ibserepo.xml

On other platforms, use the corresponding location.

If you are using a file system repository, you are not required to configure any additional BSE components.

Configuring an Oracle Repository

To configure an Oracle repository:

  1. Contact your database administrator to obtain an Oracle user ID and password to create the BSE repository.

    This user ID should have rights to create and modify tables as well as the ability to create and run stored procedures.

  2. Open a command prompt and navigate to the setup directory. The default directory location on Windows is:

    OracleAS_home\adapters\application\etc 
    
    

    For other platforms, use the corresponding location.

    This directory contains SQL to create the repository tables in the following file:

    iwse.ora
    

    Note:

    If Oracle is not on the same machine as the Oracle Application Server, copy the iwse.ora file to the Oracle machine. Then, from a command prompt on the Oracle machine, navigate to the directory containing the iwse.ora file.
  3. Enter the following command:

    sqlplus userid/password @database @ iwse.ora
    

Configuring J2CA

During the J2CA deployment of OracleAS Adapter for MySAP ERP, OC4J generates a deployment descriptor called oc4j-ra.xml. This descriptor provides OC4J-specific deployment information for resource adapters. See Chapter 3, "OC4J Deployment and Integration" for more information on J2CA deployment and configuration.

No configuration changes are necessary if you are using the default file based repository with J2CA deployment.

Configuring a Database Repository for J2CA

To configure a database repository for J2CA:

  1. Execute the iwse.ora SQL statement on the machine where the database is installed.

  2. Create the jcatransport.properties file and save it in the following directory:

    OracleAS_HOME\adapters\application\config\jca_sample
    
    
  3. Enter values for iwafjca.repo.url, iwafjca.repo.user and iwafjca.repo.password fields in the newly created jcatransport.properties file. For example:

    iwafjca.repo.url=jdbc:oracle:thin:@90.0.0.51:1521:orcl
    iwafjca.repo.user=scott
    iwafjca.repo.password=scott1
    
    
  4. Open the oc4j-ra.xml file in a text editor.

  5. Provide the JDBC connection information as a value for the IWAYRepo_URL property.

  6. Provide a valid user name for the IWAYRepo_User property.

  7. Provide a valid password for the IWAYRepo_Password property.

  8. Save your changes to the oc4j-ra.xml file.

  9. Alter the JDBC driver path in Application Explorer's lcp. For example:

    lcp=..\lib\orabpel-adapters.jar;C:\jdev\jdbc\lib\ojdbc14.jar;C:\jdev\jdbc\lib\nls_charset12.jar;%lcp%
    to
    lcp=..\lib\orabpel-adapters.jar;..\..\..\jdbc\lib\ojdbc14.jar;..\..\..\jdbc\lib\nls_charset12.jar;%lcp%
    
    

Password Encryption

When creating J2CA configurations, you can also encrypt a password using Application Explorer and use this value in the jcatransport.properties and oc4j-ra.xml files for added security.

Configuring Password Encryption

To encrypt a password:

  1. Open Application Explorer.

  2. Click Help and select Encryption.

    The Encryption dialog box is displayed.

  3. Type a password in the Password field and click OK.

    An encrypted version of the password displays in the Encryption field.

  4. Copy the password.

  5. In the jcatransport.properties file, which is used during design time, replace the existing password with the encrypted value.

    The following is a sample of the jcatransport.properties file where the password is replaced:

    iwafjca.log.level=DEBUGiwafjca.repo.url=jdbc:oracle:thin:@172.30.166.100:1521:orcliwafjca.repo.user=scottiwafjca.repo.password=ENCR (318931973183297321831293164323332123227)
    
  6. In the oc4j-ra.xml file, which is used during run time, replace the existing password with the encrypted value for the IWayRepoPassword element.

  7. Restart the Oracle Application Server.

Creating a Repository Configuration

Before you use Application Explorer with OracleAS Adapter for mySAP ERP, you must create a repository configuration. You can create two kinds of repository configurations, Web services and J2CA, depending on the container to which the adapter is deployed.

During design time, the repository is used to store metadata created when using Application Explorer to configure adapter connections, browse EIS objects, configure services, and configure listeners to listen for EIS events. The information in the repository is also referenced at runtime.

A default J2CA repository is created for the default ManagedConnectionFactory. The name of this configuration is jca_sample.

Web services and BSE refer to the same type of deployment. See "Adapter Features" for more information.

Creating a Configuration for BSE

To create a configuration for BSE using Application Explorer, you must first define a new configuration.

Defining a New Configuration for BSE

To define a new configuration for BSE:

  1. Right-click Configurations and select New.

    The New Configuration dialog box is displayed.

  2. Enter a name for the new configuration, for example, SampleConfig, and click OK.

    BSE new configuration
    Description of the illustration app_exp_new_config_type.gif

  3. From the Service Provider list, select iBSE.

  4. In the iBSE URL field, accept the default URL or replace it with a different URL with the following format:

    http://hostname:port/ibse/IBSEServlet
    
    

    Where hostname is the machine on which your application server resides and port is the port number where the application server is listening.

  1. Click OK.

    A node representing the new configuration appears beneath the root Configurations node.

    sample config
    Description of the illustration sampleconfig.gif

    The Web service repository configuration file is stored in OracleAS_home\j2ee\home\applications\ws-app-adapter\ibse.

Creating a Configuration for J2CA

To create a configuration for OracleAS Adapter J2CA using Application Explorer, you must first define a new configuration.

Defining a New Configuration for J2CA

To define a new configuration for J2CA:

  1. Right-click Configurations and select New.

    The New Configuration dialog box is displayed.

  2. Enter a name for the new configuration, for example, SampleConfig, and click OK.

    select new JCA configuration
    Description of the illustration new_jca_config.gif

  3. From the Service Provider list, select JCA.

  4. In the Home field, enter a path to your J2CA configuration directory where the repository, schemas, and other information is stored, for example:

    OracleAS_home\adapters\application
    
    
  5. Click OK.

    A node representing the new configuration appears beneath the root Configurations node.

    sample configuration
    Description of the illustration sampleconfig.gif

    The OracleAS Adapter J2CA configuration file is stored in OracleAS_home\adapters\application\config\configuration_name

    Where OracleAS_home is the directory where Oracle Application Server is installed and configuration_name is the name of the configuration you created; for example, SampleConfig.

Connecting to a BSE or J2CA Configuration

To connect to a new configuration:

  1. Right-click the configuration to which you want to connect, for example, SampleConfig.

  2. Select Connect.

    Nodes appear for Adapters, Events, and Business Services (also known as Web services). The Business Services node is only available for BSE configurations. If you are connected to a J2CA configuration, you will not see the Business Services node.

    Events are not applicable when using a BSE configuration. You can configure events using a J2CA configuration only. As a result, you can disregard the Events node that appears for a BSE configuration.

    The following is an example of a BSE configuration named SampleConfig:

new configuration
Description of the illustration new_config.gif

  • Use the Adapters folder to create inbound interaction with mySAP ERP. For example, you use the mySAP ERP node in the Adapters folder to configure a service that updates mySAP ERP.

  • Use the Events folder to configure listeners that listen for events in mySAP ERP.

  • Use the Business Services folder (available for BSE configurations only) to test Web services created in the Adapters folder. You can also control security settings for the Web services by using the security features of the Business Services folder.

You can now define new targets to mySAP ERP.

Establishing a Connection (Target) for mySAP ERP

Defining the application includes adding a target for OracleAS Adapter for mySAP ERP. Setting up the target in Application Explorer requires information that is specific to the target.

To browse the available business functions, you must first define a target to mySAP ERP. After you define the target, it is automatically saved. You must connect to the mySAP ERP system every time you start Application Explorer or after you disconnect.

When you launch Application Explorer, the left pane displays (as nodes) the application systems supported by Application Explorer, based on the adapters that are installed.

Defining a Target to mySAP ERP

To connect to mySAP ERP for the first time, you must define a new target. OracleAS Adapter for mySAP ERP supports mySAP ERP standard security and the additional protocol of SNC. Once connected to the mySAP ERP application server, application security is managed by user ID, roles and profiles. For more information on SAP application security, see the appropriate SAP documentation.

To define a target:

  1. In the left pane, expand the Adapters node.

    The application systems supported by Application Explorer appear as nodes based on the adapters that are installed.

    expanded adapter list
    Description of the illustration adapterexpandedpartial.gif

  2. Right-click the mySAP node and select Add Target.

    SAP add target
    Description of the illustration addtarget.gif

    The Add Target dialog box is displayed. Provide the following information:

    1. In the Name field, enter a descriptive name, for example, SAPTarget.

    2. In the Description field, enter a description for the target (optional).

    3. From the Type list, select the type of target you are connecting to. The supported target types include Message Server or Application Server (default).

      Note:

      For load balancing purposes, application servers from one mySAP ERP system are usually configured in logon groups, where each group serves a particular kind of user. The application servers in each group are assigned to users by a least-heavily-loaded strategy. This load balancing is done by message servers. Each mySAP ERP system has exactly one message server, which can be reached through TCP on a specific message server port.
  1. Click OK.

    The Application Server dialog box is displayed.

    Add Target dialog box
    Description of the illustration addtarget_dialogbox.gif

    The following tabs are available:

    • User (Required)

    • System (Required)

    • Advanced

    • Security

  2. For the User tab (required), enter the appropriate information for your mySAP ERP target based on the information in the following table.

    Table 2-1 User Tab Parameters

    Target Parameter Description

    Client

    The client number defined for the mySAP ERP application for client communications.

    User

    A valid user ID for the mySAP ERP application.

    Password

    A valid password for the mySAP ERP application.

    Language

    A language key. EN (English) is the default.

    Codepage

    A character code page value.

    Authentication Mode

    The authentication mode you want to use when connecting to your mySAP ERP system. By default, Password is selected from the drop-down list.

    If you are using a Secure Network Communications (SNC) adapter with SAP, select Logon ticket (SSO2).

    If you are using an SNC adapter with SAP, select Logon ticket (X509).


    Secure Network Communications (SNC) provides protection for the communication links between the distributed components of an ERP system. Using SNC, mySAP ERP can support products that adhere to the GSS-API Version 2 standard. SNC supports application level (end-to-end security), Smartcard authentication, and Single Sign-On (SSO).

    Depending on the mySAP ERP system release, logging on using SSO or X.509 certificates is supported.

    • For SSO, specify the user to be $mySAPSSO2$ and pass the base64 encoded ticket as the passwd parameter.

    • For X509, specify the user to be $X509CERT$ and pass the base64 encoded certificate as the passwd parameter.

    For more information, see your mySAP ERP system documentation.

  3. For the System tab (required), enter the appropriate information for your mySAP ERP target based on the information in this section.

    System tab
    Description of the illustration system_tab.gif

    The System tab enables you to provide the application server name, system number, and connection pooling information for the mySAP ERP system to which you are connecting.

    Table 2-2 System Tab Parameters

    Target Parameter Description

    Application Server

    The host name or IP address for the computer that is hosting the mySAP ERP application.

    System number

    The system number defined to mySAP ERP for client communications.

    Connection pool name

    The name of your mySAP ERP connection pool. A default value, p1, is already provided.

    Connection pool size

    The number of client connections in a pool you want to make available to mySAP ERP for Web service calls. A default connection pool size of 2 is available by default.

    Important: The default value of 1 does not create a connection pool. Instead, a single mySAP ERP connection with sequential processing is shared. A pooled connection invokes multiple connections to mySAP ERP with parallel processing.

    If you are using Application Explorer to create Web services, the connection pool size value is used by your Web service during runtime. As a result, ensure that the connection pool size is sufficient for your purposes.

    Connection timeout(min)

    The timeout value for your connection pool in minutes. The default value is 10 minutes.

    Connection wait time(sec)

    The wait time for your connection poolin seconds. The default value is 30 seconds.

    Connections to an ERP server take up valuable resources on both the client and the remote server. You can create a pool of connections to minimize the resource and time constraints. In estimating the size of the pool, you may calculate pool size by the amount of server resources to be consumed, the number and size of the documents to be received, and the size of your Java Virtual Machine. The section of SAP documentation ÒMemory Management (BC-CST-MM)Ó explains in detail the resources required on the mySAP ERP system.


  4. For the Advanced tab (optional), enter the appropriate information for your mySAP ERP target based on the information in this section.

    The Advanced tab enables you to specify your EDI and IDoc versions, and configure error handling.

    Advanced tab
    Description of the illustration advanced_tab.gif

    Table 2-3 Advanced Tab Parameters

    Target Parameter Description

    Edi version

    The Electronic Data Interchange (EDI) document version you are using with the adapter. Version 3 is the default value.

    IDOC release

    The IDOC versioning you want to use for your connection.

    IDOC release provider

    The IDOC release provider for your connection. Select IDOC DOCREL field (default), SAP release, or user input from the drop-down list.

    Error Handling

    From the list In the event of an exception, you can select Creates Error Document or Throws Exception. To receive more detailed error messages, select Creates Error Document.

    As a rule:

    • If your application is Java centric, select Throws Exception so that code components can catch the exception and react accordingly.

    • If your application is document based, select Creates Document to create an XML document that contains the Java exception.

    It is up to your application to read the XML document and obtain the error.

    Commit with Wait

    If a high degree of accuracy is required in your application, select the Commit with Wait check box.

    The adapter waits until all records are physically written to the database before returning from the function call. The ÒCommit With WaitÓ has a performance impact on adapter performance, so consider carefully before selecting it. The commit behavior of BAPIs is described in the SAP documentation under ÒBAPI Programming Guide and Reference (CA-BFA).Ó

    All SAP Business Objects that change data must commit work to the database. Some BAPIs developed in version 3.1 of the R/3 system use an internal commit behavior, and their commit behavior cannot be changed by the adapter. As soon as they are called, they commit the work they did.

    BAPIs developed since release 3.1 use the external commit method. The adapter issues a commit command, and the commit is put in the database queue. If there is an application error in the first part of the commit, the error message ÒPosting could not be carried outÓ is returned, and the adapter rolls back the transaction. If in writing to the database, a database error occurs, a short dump is issued in the database records of SAP, but no message is returned to the adapter about the failure.

    This option is disabled by default.

    SAP trace

    Select this option to enable traces.


  5. For the Security tab (optional), enter the appropriate information for your mySAP ERP target based on the information in this section.

    Security tab
    Description of the illustration security_tab.gif

    The Security tab enables you to specify Secure Network Communication (SNC) information for the mySAP ERP system to which you are connecting.

    Table 2-4 Security Tab Parameters

    Target Parameter Description

    SNC mode

    By default, SNC is disabled. To enable SNC, select 1 from the list.

    SNC partner

    Enter the name of the RFC server or message server (load balancing) that provides the SNC services.

    SNC level

    From the list select the version of the SNC library.

    SNC name

    Enter the name of the SNC library you are using.

    SNC library path

    Enter the path to the SNC library.


    SNC provides protection for the communication links between the distributed components of an mySAP ERP system. Using SNC, mySAP ERP can support products that adhere to the GSS-API Version 2 standard. SNC supports application level (end-to-end security), Smartcard authentication, and single sign-on (SSO).

    If you are using SAP Enterprise Portal, the J2EE engine generates the SAP logon ticket automatically. A possible SNC scenario would be from SAP Enterprise Portal to OracleAS Adapter for mySAP ERP.

    If you want to use SAP logon tickets to enable SSO to non-SAP components, consult the SAP documentation regarding Pluggable Authentication Services. A possible SNC scenario in this case would be from a non-SAP Enterprise Portal to OracleAS Adapter for mySAP ERP.

  6. When you have provided all the required information for your target, click OK.

    After the extraction finishes, the new target, mySAPTarget, appears under the mySAP adapter node.

    Disconnected target to SAP
    Description of the illustration connect1.gif

    You can now connect to your mySAP ERP target.

    See "Creating XML Schemas" for information on how to create schemas for the adapter.

Connecting to a Defined mySAP ERP Target

To connect to an existing target:

  1. In the left pane, expand the Adapters node.

  2. Expand the mySAP node.

  3. Click the target name under the mySAP node (for example, mySAPTarget).

    The Connection dialog box displays the values you entered for connection parameters.

  4. Verify your connection parameters.

  5. Provide the correct password.

  6. Right-click the target name and select Connect.

    The x icon disappears, indicating that the node is connected.

    Connected SAP target
    Description of the illustration saptarget2.gif

Managing a Connection to mySAP ERP

To manage mySAP ERP connections, you can:

  • Disconnect from a connection that is not currently in use.

    Although you can maintain multiple open connections to different transaction processing systems, it is recommended to disconnect from connections not in use.

  • Edit a target.

    You can modify the connection parameters when your system properties change. After you disconnect, you can modify an existing target.

  • Delete a connection that is no longer needed.

Disconnecting from a Connection to mySAP ERP

To disconnect a target:

  1. Expand the Adapters node.

  2. Expand the mySAP node.

  3. Right-click the target to which you are connected, for example, mySAPTarget, and select Disconnect.

    Disconnecting from target
    Description of the illustration disconnecting_fromtarget.gif

    Disconnecting from the mySAP ERP target drops the connection with mySAP ERP, but the node remains.The x icon appears, indicating that the node is disconnected.

    Disconnected target
    Description of the illustration disconnected_target.gif

Modifying Connection Parameters

After you create a target for mySAP ERP using Application Explorer, you can edit any of the information that you provided previously.

To edit a target:

  1. Verify that the target you want to edit is disconnected.

  2. Right-click the target and select Edit.

    Editing a target
    Description of the illustration edit_target.gif

    The Application Server dialog box displays the target connection information.

  3. Change the properties in the dialog box as required and click OK.

Deleting a Connection to mySAP ERP

To delete a target:

  1. Locate the target you want to delete.

  2. Right-click the target (for example, SAPTarget), and select Delete.

    Deleting a target
    Description of the illustration deleting_target.gif

    The node disappears from the list of available connections.

Viewing Application System Objects

As you connect to mySAP ERP, Application Explorer enables you to explore and browse mySAP ERP business objects that are used to support existing business processes.

Note:

Depending on the release or service pack installed, certain RFCs, for example, RFC_CUSTOMER_GET, may not exist in your particular mySAP ERP system. Therefore, the examples included in this documentation may not be relevant to your system. If this is the case, you should use the examples as a general reference for adapter functionality and choose an RFC that exists within your mySAP ERP application environment.As described in SAP Release Note 109533, SAP Function Modules (RFCs) can be delivered with different release statuses. SAP supports only RFCs that are awarded the Released for Customer status. There is no claim to the release independencies of the interfaces and the continued existence/functionality of the modules. For more information on the status of a specific function module, consult your SAP Service Marketplace.

Creating XML Schemas

After you explore the mySAP ERP business function library and select an object, you can use Application Explorer to create the XML request schema and the XML response schema for that function.

To create request and response schemas for a mySAP ERP business function.

  1. Connect to a mySAP ERP target as described in "Connecting to a Defined mySAP ERP Target".

  2. Expand the Business Object Repository node.

  3. Click the icon to the left of the Financial Accounting node.

  4. Scroll down and click the icon to the left of the CompanyCode business object.

  5. Scroll down and select the BAPI named GetDetail.

    The following screen appears on the right.

    Schema tabs
    Description of the illustration schema1.gif

  6. To view the XML for each schema type, click the appropriate tab.

Generating WSDL (J2CA Configurations Only)

The Web Service Definition Language (WSDL) description of a service enables you to make the service available to other services within a host server. You use Application Explorer to create both request-response (outbound) and event notification (inbound) J2CA services of the adapter.

Note:

The Create Inbound JCA Service (Event) option is only available when the selected node supports events.

To generate a WSDL file for request-response service:

  1. After you create a schema, right-click the respective object.

    The following menu is displayed:

    Right-click BAPI_COMPANYCODE_GETDETAIL node
    Description of the illustration bpel_40.gif

  2. Select Create Outbound JCA Service (Request/Response).

    The Export WSDL dialog box is displayed.

    Export WSDL dialog box
    Description of the illustration bpel_41.gif

  3. Accept the default name and location for the file.

    The .wsdl file extension is added automatically. By default, the names of WSDL files generated for request-response services end with _invoke, while those generated for event notification end with _receive.

    Note:

    You can organize your WSDL files in subfolders, creating your own WSDL hierarchy structure. Create the folders under OracleAS_home\adapters\application\wsdls\. The WSIL browser in JDeveloper will display the full tree structure of your WSDL hierarchy.
  4. Click OK.

    The WSDL file is saved in the specified location.

The procedure for generating WSDL for event notification is similar to request-response. To generate WSDL for event notification, you must first create a channel for every event. See "Generating WSDL for Event Notification" for a detailed example.

Creating and Testing a Web Service (BSE Configurations Only)

Using Application Explorer, you can explore the business function repository and generate Web services (also known as a business service) for the mySAP ERP functions you want to use with the adapter. The following procedure uses the mySAP ERP BAPI method called BAPI_MATERIAL_GETLIST as an example and returns a list of materials from mySAP ERP.

Note:

In a J2EE Connector Architecture (J2CA) implementation of the adapter, Web services are not available. When the adapter is deployed to use the OracleAS Adapter J2CA, the Common Client Interface provides integration services using the adapter.

Creating a Web Service

To create a Web service for a mySAP ERP business function:

  1. Connect to your mySAP ERP target and expand the Business Object Repository node.

  2. Select the BAPI_MATERIAL_GETLIST method from the Business Object Repository.

  3. Right-click the node from which you want to create a business service and select Create Web Service.

    The Create Web Service dialog box is displayed. You can add the business function as a method for a new Web service or as a method for an existing one.

    Create Web Service dialog box
    Description of the illustration create_webservice_2.gif

    Perform the following steps:

  1. Click Next.

    The License and Method dialog box is displayed.

    Provide the following information:

    1. In the License Name field, select one or more license codes to assign to the Web service. To select more than one, hold down the Ctrl key and click the licenses.

    2. In the Method Name field, enter a descriptive name for the method.

    3. In the Method Description field, enter a brief description of the method.

    4. In the DTD Directory field, specify the location of the DTD you want to use. The following default location is provided: OracleAShome\adapters\application\tools\

  2. Click OK.

    Application Explorer switches the view to the Business Services node, and the new Web service appears in the left pane.

Testing a Web Service

After a Web service is created, you can test it to ensure it functions properly. A test tool is provided for testing the Web service.

To test a Web service:

  1. Click the Business Services node to access your Web services.

  2. Expand the Services node.

  3. Select the name of the business service you want to test.

    The business service name appears as a link in the right pane.

  4. In the right pane, click the named business services link.

    The test option appears in the right pane. If you are testing a Web service that requires XML input, an input field appears.

  5. Enter the appropriate input.

  6. Click Invoke.

    Application Explorer displays the results.

Identity Propagation

If you test or run a Web service using a third party XML editor, the Username and Password values that you specify in the SOAP header must be valid and are used to connect to mySAP ERP. The user name and password values that you provided for mySAP ERP during target creation using Application Explorer are overwritten for this Web service request. The following is a sample SOAP header that is included in the WSDL file for a Web service:

<SOAP-ENV:Header>
  <m:ibsinfo xmlns:m="urn:schemas-iwaysoftware-com:iwse">
    <m:service>String</m:service>
    <m:method>String</m:method>
    <m:license>String</m:license>
    <m:disposition>String</m:disposition>
    <m:Username>String</m:Username>
    <m:Password>String</m:Password>
    <m:language>String</m:language>
  </m:ibsinfo>
</SOAP-ENV:Header>

You can remove the <m:disposition> and <m:language> tags from the SOAP header, since they are not required.

Configuring an Event Adapter

Events are generated as a result of activity in a database or in an application system. You can use events to trigger an action in your application. For example, an update to a database can reflect an update to customer information. If your application must perform when this happens, your application is a consumer of this event.After you create a connection to your application system, you can add events using Application Explorer. To create an event, you must create a port and a channel.

Note:

If you are using a J2CA configuration, you must create a new channel for every event and select this channel when you generate WSDL. Creating a channel is required for J2CA configurations only.

Note:

OC4J currently conforms to J2CA 1.0, which does not call for event capabilities. When conforming to J2CA 1.0, only service interactions are supported.

Creating and Editing an Event Port

Application Explorer enables you to create event ports from the Adapters node or from the Events node.

Events are not applicable when using a BSE configuration. You can configure events using a J2CA configuration only.

Note:

You are not required to create event ports for J2CA configurations. You must create event ports for BSE configurations only.

Creating an Event Port from the Adapters Node

You cannot create an event port from the Services node; you must create it from the Adapters node.

To create an event port directly from the Adapters node:

  1. Right-click a node under BAPI, RFC, or IDOC.

  2. Select Create Event Port.

    Create Event Port
    Description of the illustration create_eventport.gif

    The Create Event Port dialog box is displayed. Perform the following steps:

    1. Enter a name for the event port and provide a brief description.

    2. From the Protocol drop-down list, select the required disposition, for example, File.

    3. Enter the disposition URL.

    4. Specify the location of your Web service.

  3. Click OK.

    See "Creating an Event Port from the Events Node" for information on configuring port dispositions.

Creating an Event Port from the Events Node

The following procedures describe how to create an event port from the Events node for various dispositions using Application Explorer. You can switch between a BSE and a J2CA deployment by choosing one or the other from the menu in the upper right of Application Explorer.

See "Creating an Event Port from the Adapters Node" for information on creating an event port directly from the Adapters node.

Creating an Event Port for the File Disposition

To create a specific event port for File:

  1. Click the Events node.

    BSE configuration with Events node expanded
    Description of the illustration adapterexpandedpartial2.gif

  2. Expand the mySAP node.

  3. Right-click the Ports node and select Add Port.

    The Add Port dialog box is displayed. Provide the following information:

    1. Enter a name for the event port and provide a brief description.

    2. From the Protocol list, select File.

    3. In the URL field, specify a destination file to which the event data is written using the following format:

      file://location
      
      

      The following table defines the parameters for the disposition.

      Parameter Description
      location Full directory path and file name to which the data is written.

  4. Click OK.

    The port appears under the ports node in the left pane. In the right pane, a table appears that summarizes the information associated with the event port you created.

    You can now associate the event port with a channel. See "Creating and Editing a Channel" for more information.

Editing an Event Port

To edit an event port:

  1. In the left pane, select the event port you want to edit.

  2. Right-click the port and select Edit.

    The Edit Port pane is displayed.

  3. Make the required changes and click OK.

Deleting an Event Port

To delete an event port:

  1. In the left pane, select the event port you want to delete.

  2. Right-click the port and select Delete.

    A confirmation dialog box is displayed.

  3. To delete the event port you selected, click OK.

    The event port disappears from the list in the left pane.

Creating and Editing a Channel

The following procedure describes how to create a channel for your event. All defined event ports must be associated with a channel.

Events are not applicable when using a BSE configuration. You can configure events using a J2CA configuration only.

Note:

If you are using a J2CA configuration, you must create a new channel for every event and select this channel when you generate WSDL. Creating a channel is required for J2CA configurations only.

Creating a Channel

To create a channel:

  1. Click the Events node.

    BSE configuration with Events node expanded
    Description of the illustration adapterexpandedpartial2.gif

  2. Expand the mySAP node.

    The ports and channels nodes appear in the left pane.

  3. Right-click Channels and select Add Channel.

    The Add Channel dialog box is displayed.

    Add Channel dialog box
    Description of the illustration addchanneldialog2.gif

    Provide the following information:

    1. Enter a name for the channel, for example, TEST_CHANNEL.

    2. Enter a brief description.

    3. From the Protocol list, select SAP Channel -- Msg Server or SAP Channel -- App Server.

    4. Select an event port from the list of available ports. To select more than one, hold down the Ctrl key and click the ports.

    5. Click >> to transfer the port(s) to the list of selected ports.

  1. Click Next.

    The Message Server dialog box is displayed. The following tabs are available:

    • User (Required)

    • System (Required)

    • Security

    • Advanced

  2. For the User tab, enter the appropriate information for your mySAP ERP channel based on the information in the following table.

    Table 2-5 User Tab Parameters

    Target Parameter Description

    Client

    The client number defined for the SAP application for client communications.

    User

    A valid user ID for the SAP application.

    Password

    A valid password for the SAP application.

    Language

    A language key. EN (English) is the default.

    Code page

    A character code page value.

    Authentication Mode

    The authentication mode you want to use when connecting to your mySAP ERP system. By default, Password is selected from the drop-down list.

    If you are using a Secure Network Communications (SNC) adapter with SAP, select Logon ticket (SSO2).

    If you are using an SNC adapter with SAP, select Logon ticket (X509).


  3. For the System tab, enter the appropriate information for your mySAP ERP channel based on the information in the following table.

    Table 2-6 System Tab Parameters

    Target Parameter Description

    Gateway host

    A host name for the mySAP ERP Gateway.

    Gateway service

    A service for the mySAP ERP Gateway.

    Program ID of the server

    A mySAP ERP program ID you want to use for this channel.

    Message Server

    A host name for the message server.

    R/3 name

    A mySAP ERP name.

    Server group

    A mySAP ERP server group.


  4. For the Security tab (optional), enter the appropriate information for your mySAP ERP channel based on the information in the following table.

    Table 2-7 Security Tab Parameters

    Target Parameter Description

    SNC mode

    By default, SNC is disabled. To enable SNC, select 1 from the list.

    SNC partner

    Enter the name of the RFC server or message server (load balancing) that provides the SNC services.

    SNC level

    From the list select the version of the SNC library.

    SNC name

    Enter the name of the SNC library you are using.

    SNC library path

    Enter the path to the SNC library.


  5. For the Advanced tab (optional), enter the appropriate information for your mySAP ERP channel based on the information in the following table.

    Table 2-8 Advanced Tab Parameters

    Target Parameter Description

    IDOC Format

    Select an IDOC type from the list.

    IDOC release

    The IDOC versioning you want to use for your connection.

    IDOC release provider

    The IDOC release provider for your connection. Select IDOC DOCREL field (default), SAP release, or user input from the drop-down list.

    SAP trace

    Select this option to enable traces.

    Processing Mode

    Select the type of synchronous processing from the list. Possible values include REQUEST and REQUEST_RESPONSE.


  6. Click OK.

    The channel appears under the channels node in the left pane.

    Channel node
    Description of the illustration sapchannel4.gif

    An X over the icon indicates that the channel is currently disconnected. You must start the channel to activate your event configuration.

    Note:

    If you are using OracleAS Adapter for MySAP ERP with BPEL Process Manager, do not start the channel, as it is managed by the BPEL PM Server. If you start the channel for testing and debugging purposes, stop it before runtime.
  7. Right-click the channels node and select Start.

    The channel you created becomes active.

    Activated channel
    Description of the illustration sapchannel5.gif

    The X over the icon disappears.

  8. To stop the channel, right-click the connected channel node and select Stop.

    The channel becomes inactive and an X appears over the icon.

Editing a Channel

To edit a channel:

  1. In the left pane, locate the channel you want to edit.

  2. Right-click the channel and select Edit.

    The Edit Channel pane is displayed.

  3. Make the required changes to the channel configuration and click Finish.

Deleting a Channel

To delete a channel:

  1. In the left pane, locate the channel you want to delete.

  2. Right-click the channel and select Delete.

    A confirmation dialog box is displayed.

  3. To delete the channel you selected, click OK.

    The channel disappears from the list in the left pane.