To be able to connect to SAP from App Connect Professional, you need to install SAP libraries into App Connect and install the App Connect Secure Connector on a computer on your network with access to the SAP system.

Procedure

  1. Install SAP library files for use in App Connect Professional
  2. Install the App Connect Secure Connector

What to do next

When later trying to connect to SAP, if you get an Unable to Connect error you can usually restore connectivity to SAP by checking and updating the installed SAP library files.

Installing SAP library files for use in App Connect Professional

To be able to connect to SAP, App Connect Professional needs a few SAP JCO libraries installed.

Procedure details

About this task

  • To be able to run integration projects in an App Connect environment in the cloud, the SAP JCO libraries need to be installed into the environment through the web management console.
    Tip: The same SAP libraries need to be installed into the App Connect Secure Connector, when you install the Secure Connector.

    To get the SAP JCO libraries, contact your SAP system administrator who can download the libraries files from the SAP support site. Have these files available on the computer where you are developing the project. The list of SAP libraries are given below:

    • sapjco3.jar
    • sapjco3.dll
    • sapidoc3.jar
  • Occasionally, the com.approuter.module.jcaconnectors.sap.tp-1.0.0.jar in the Studio needs updating to be able to connect to SAP from the Studio when developing and testing integration projects.
    Tip: This JAR file only needs updating sometimes after downloading the Studio, and if needed, you can download this JAR file from the web management console.

The following steps use the files on a Windows computer, with the web management console, to install the SAP JCO libraries into the App Connect runtime environment (Production) in the cloud.

Procedure

  1. Log in to IBM® App Connect Professional

    This displays the web management console, showing the tabs for Create, Modify, and Run; the three main steps to get your integration solution running.

    Figure 1. The web management console after logging in to IBM App Connect Professional on Cloud

  2. In the web management console, select the Production environment, into which the SAP libraries are to be installed.

    1. Click Settings
    2. In the Settings window, click Edit for Libraries Environment
    3. Select the libraries environment Production, and then select Save

    This step specifies that the SAP libraries are to be added to, and used from, the Production environment.

  3. Add the SAP library files into the Production environment

    1. Select the Production environment tab
    2. Select System > Connector Libraries
    3. In the Update Connector Libraries window, select SAP as shown below.
    4. Click on the “+” symbol, and then browse to and add the three files one by one.
    5. Select Update, to add the files to the environment.

    After a short while, the library files are added to the environment.

    In the System > Connector Libraries view of the Production tab, you can see the files are listed under the Installed Files section for SAP.

    Figure 2. SAP libraries installed into App Connect Professional

Results

The SAP JCO library files are installed in the Production environment, as shown in the web management console.

(Any need to install other SAP files into the Studio is occasional, and only if indicated when trying to connect to SAP.)

What to do next

If you haven’t already done so, install the App Connect Secure Connector (including the same SAP JCO library files), as described in Installing the App Connect Secure Connector.

Installing the App Connect Secure Connector

The App Connect Secure Connector provides secure bidirectional data transfer between App Connect Professional on Cloud and SAP (or other endpoints) that are located behind a firewall.

Procedure details

About this task

  1. Create a secure connector in the Production environment of the web management console.
  2. Download the secure connector configuration file and secure connector installer.
  3. Install the App Connect Secure Connector on a computer behind your firewall.
  4. Download and install vendor-supplied libraries to use with the App Connect Secure Connector.

The following steps are based on a scenario where IBM App Connect Professional is to connect to a SAP system behind a firewall, as part of a data sync solution between SAP and Salesforce.com.

Figure 3. Example scenario: Data sync between SAP and Salesforce, through App Connect Professional and secure connector

Procedure

  1. Log in to IBM® App Connect Professional

    This displays the web management console, showing the tabs for Create, Modify, and Run; the three main steps to get your integration solution running.

    Figure 4. The web management console after logging in to IBM App Connect Professional on Cloud

  2. In the web management console, select the Production environment tab, which is to be used to connect to SAP.
  3. Create a Secure Connector

    1. Display the Secure Connectors pane. Select System > Secure Connectors
    2. Click New Secure Connector
    3. Provide a name for the new Secure Connector. For example: SC4SAPConnectivity

      Remember: Remember the name for the new Secure Connector. You specify this name later when configuring the SAP endpoint in the Studio.
    4. Optional: Provide a description for the Secure Connector. For example: Secure Connector for SAP connectivity
    5. Click Save

      The secure connector is displayed in the Secure Connector page.

      Figure 5. Creating a new secure connector in the web management console
      Creating a new secure connector in the web management console
  4. Download the secure connector configuration file and secure connector installer.

    Important: Although you can place the installer file into a temporary directory, you must save the configuration file into a directory that is persistent. During the installation, the configuration file is not copied. Instead, a reference to the file is created and used whenever the Secure Connector starts, so the file must be in a known location for as long as the Secure Connector might be used.
    1. From the Secure Connectors page, click the Secure Connector name. The Edit Secure Connector dialog box shows the authentication key for the Secure Connector.

      Figure 6. Edit Secure Connector, showing its authentication key
      Edit Secure Connector, showing its authentication key
    2. Click Download Secure Connector Configuration, and then click Download Now.
    3. Save the file to your computer.

      The name of the file includes the environment name (Production) and the connector name (SC4SAPConnectivity, that you provided); for example: SecureConnector-Production_SC4SAPConnectivity-Configuration

    4. In the Edit Secure Connector dialog box, click Download Installer, and then the link for the operating system that you want the Secure Connector to run on.

      In this example, the Windows 32-bit installer was downloaded, and has the file name windows-secure-connector-installer.exe.

  5. Install the Secure Connector on Windows

    Ensure that the configuration and installer files are available to the computer where you want to install and run the Secure Connector.

    Complete the following steps on the computer where you want to install and run the Secure Connector.

    1. Start the installer. Click the installer file executable (windows-secure-connector-installer.exe).
    2. If a Security Warning panel is display, click the option to allow the installer to continue.
    3. In the Welcome panel, click Next.

      Figure 7. Secure Connector installer, page 1
      Secure Connector installer, page 1
    4. Read and accept the Licensing Agreement, and then click Next.
    5. Specify the installation path Either accept the default path or specify your own path. In this example, use the following path: C:\IBM\Secure_Connector_1.7.5.2.0 If it does not already exist, you are informed that the target directory will be created. Click OK, and then click Next to continue.
    6. Choose the shortcuts. Accept the default settings, and then click Next.

      The installer starts the installation, and finishes in a few minutes. When finished, the progress bar looks as shown in the following figure.

      Click Next to continue.

      Figure 8. Secure Connector installer, installation finished
      Secure Connector installer, installation finished
    7. Specify the location of the downloaded configuration file Click Browse to find and select the configuration file SecureConnector-Production_SC4SAPConnectivity-Configuration.

      Tip: You might need to expand the installer window to see the Browse button.
      Figure 9. Secure Connector installer, configuration file
      Secure Connector installer, configuration file

      Click Next to continue.

      The installation wizard reads the configuration file and displays the user data.

    8. In the User Data window, ensure the ports used are OK, then click Next to continue.

      Ensure that the listener port, which defaults to 2500, is not already in use in your system. If required, change the port to a port that is not in use.

      Tip: Note that the Name parameter matches the name that you specified when you created the Secure Connector in the web management console.

      If you need to do so, you can click Previous to select a different configuration file.

      Figure 10. Secure Connector installer, user data
      Secure Connector installer, user data
    9. If your computer cannot connect directly to the Internet, but is using a proxy, you can specify the proxy details, including password.

      This example does not need to specify a proxy.

      Click Next to continue.

    10. If you want to run the Secure Connector as a Windows service, specify the details.

      This example starts the Secure Connector manually, so do not enable this option.

      Click Next to continue.

    11. On the Install Vendor Supplied Libraries page, install any library files needed to connect to the target system

      Figure 11. Secure Connector installer, Install Vendor Supplied Libraries page
      Secure Connector installer, Install Vendor Supplied Libraries page
      In this example, install the three SAP library files:

      • sapjco3.jar
      • sapjco3.dll
      • sapidoc3.jar

      To get the SAP library files, contact your SAP system administrator who can download the files from the SAP site.

      To install the SAP library files into the secure connector, complete the following steps:

      1. Under Connector, select SAP. The message The selected connector is SAP is displayed
      2. Under Files to Add, click Add, and then browse to and add the three files one by one.
      3. Click Update, to add the files to the connector.

      The SAP libraries have been installed into the secure connector.

      Figure 12. Secure Connector installer, SAP libraries installed successfully
      Secure Connector installer, SAP libraries installed successfully
    12. On the Installation Finished page, click Done.

Results

The App Connect Secure Connector has been installed onto your Windows computer, and you have added the SAP library files that the connector needs to connect to SAP.

What to do next

Verify that the App Connect Secure Connector can be started.

  1. Either select the Start menu option IBM > App Connect Secure Connector xxxx > Start Secure Connector or run the runclient_osgi file, in this example:
    C:\IBM\Secure_Connector_1.7.5.2.0\runclient_osgi.bat
    Note: Start the connector with administrator access (Run as Administrator).
  2. In the console opened, you should see the message that the connector started successfully:
    2017-03-17 15:33:46 INFO Finished loading connector modules 2017-03-17 15:33:46 INFO Secure connector name: SC4SAPConnectivity, Tenant ID: 8 949B362740D64F53EB68378F5D34557, Environment ID: AA4BDC1B88BDAEB0420037DE76A24CE 3 2017-03-17 15:33:47 INFO Secure Connector started successfully
    
  3. In the web management console, check the status of the connector:
    Figure 13. Web management console, Secure Connector status RUNNING
    Web management console, Secure Connector status RUNNING
Note: Before you start an orchestration/project that is to use a secure connector, ensure that the secure connector is created, installed, configured, and is in running state. One secure connector can be used by more than one endpoint/orchestration.

Checking and updating installed SAP library files

Sometimes, when trying to connect to SAP you might get an Unable to Connect error. In such cases, you can usually restore connectivity to SAP by checking and, where needed, updating the installed SAP library files.

Procedure details

Procedure

  • Check and, where needed, update the installed SAP library files

    • Unable to connect to Secure Connector SC4SAPConnectivity while trying to do activate. Error is: Connection refused. Attempt 1 of 5. Will try again in 3 second(s)

      (When trying to connect to SAP through the App Connect Secure Gateway, usually when running an integration project in the web management console.)

      Stop, and then reconfigure the Secure Connector to update the three SAP libraries files used when installing the App Connect Secure Connector; for example:

      1. Select Start > All Programs > IBM > App Connect Secure Connector x.x.x.x > Secure Connector Configuration
      2. Click Next several times until the Install Vendor Supplied Libraries page
      3. Add the three SAP library files, and then click Update
      4. Clicke Next and then click Done.

      Restart the Secure Connector to use the updated SAP library files.

    • Unable to connect to Secure Connector SC4SAPConnectivity while trying to do activate. Error is: java.lang.ClassNotFoundException: com.sap.conn.jco.JCo. Attempt 1 of 5. Will try again in 3 second(s)

      (When trying to connect to SAP through the App Connect Secure Gateway, usually when running an integration project in the web management console.)

      Add the SAP library file, sapjco3.dll to the Java bin directory. You can get this file from the SecureConnector-Production-libraries package downloaded from the web management console.

    • Unable to Connect: Required SAP JCO native library is not found. Install version 3.x SAP JCO native library(.dll or .so based on platform). Detail: Could not initialize class com.sap.conn.jco.JCo 

      (Usually when trying to connect to SAP from the Studio.)

      There are several things to try. After trying one solution, reload the project into the Studio and then try to connect to SAP again.

      • If the Secure Connector was not running, start it.
      • Reconfigure the Secure Connector to update the SAP library files. (See above.)
      • Add the SAP library file, sapjco3.dll to the Java bin directory. (See above.)
    • Unable to Connect: Required SAP JCO jars are not found. Install version 3.x SAP JCO jars.

      (Usually when trying to connect to SAP from the Studio.)

      Check if the following two SAP files are present in the Studio install path and that the files are each larger than 1 MB; for example:

      C:\Users\IBM_ADMIN\AppData\Roaming\castiron\castiron.ibmcloud.com\install com.approuter.module.jcaconnectors.sap.tp.native-1.0.0.jar    3,772 KB com.approuter.module.jcaconnectors.sap.tp-1.0.0.jar           1,541 KB

      Sometimes a copy of the com.approuter.module.jcaconnectors.sap.tp-1.0.0.jar file smaller than 1 MB is downloaded with the Studio and needs to be replaced. You can get this file from the SecureConnector-Production-libraries package downloaded from the web management console.

  • Download the SecureConnector-Production-libraries package from the web management console

    You can download the SecureConnector-Production-libraries package, to get copies of the following SAP library files:

    com.approuter.module.database.tp-1.0.0.jar com.approuter.module.jcaconnectors.sap.tp-1.0.0.jar native\libsapjco3.so native\sapjco3.dll

    To download the SecureConnector-Production-libraries package, in the web console select Production > System > > Download libraries.

Join The Discussion

Your email address will not be published. Required fields are marked *