Deployment on WebSphere

Tools
Tools covers the tools and utilities you use to work with Teradata and its supporting ecosystem. You'll find information on everything from the Teradata Eclipse plug-in to load/extract tools.
Teradata Employee

Deployment on WebSphere

  • Start the WebSphere Console.
  • Once you are connected, expand [Applications] in the left pane.
  • Click on [Install New Application] in the left pane.

Figure 2: Install New Application

  • Select the [Local file system] radio button.
  • Click on the [Browse] button.
  • Browse for others/terajmsa.war on local file system.
  • Enter terajmsa for [Context root].
  • Click on the [Next] button.

Figure 3: Browse File System

  • Click on the [Next] button.

Figure 4: Installation Options

  • Select the Module Teradata JMS Universal Connector.
  • Click on the [Next] button.

Figure 5: Map Modules

  • Select the Web Module Teradata JMS Universal Connector.
  • Click on the [Next] button.

Figure 6: Map Web Modules

  • Click on the [Finish] button.

Figure 7: Summary

  • Click on the [Save] hyperlink.

Figure 8: Save Configuration

  • Select terajmsa_war.
  • Click on the [Start] button.

Figure 9: Display Applications

Logging

Standard Out log files are located in the following directory.

/<INSTALL_DIRECTORY>/AppServer/profiles/AppSrv01/logs/server1

The log file name is SystemOut.log.

Configure Java 2 security

The JMS Universal Connector uses the Teradata Database to authenticate the login users. There is no additional setup on the security of the application servers. However, if you choose to turn on Java 2 Security in the WebSphere Application Server, you need to follow the following steps to successfully start the JMS Universal Connector.

  1. The application is successfully deployed to the application server.
  2. There are 2 files that users need to change: app.policy and was.policy.

    You will find the sample files provided in “Websphere” directory of the downloaded package. Please note that you need to replace the variable "<Teradata jdbc path in your system>" with the right installation path and the variable “<server>” with the name of the Teradata Database server in these sample files.

    app.policy

    Location: <WebSphere-Installation-Root>/profiles/<profile-name>/config/cells/<cell-name>/nodes/<node-name>

    The original app.policy file contains the webComponent block below:

    grant codeBase "file:${webComponent}" {
    permission java.io.FilePermission "${was.module.path}${/}-", "read, write";
    permission java.lang.RuntimePermission "loadLibrary.*";
    permission java.lang.RuntimePermission "queuePrintJob";
    permission java.net.SocketPermission "*", "connect";
    permission java.util.PropertyPermission "*", "read";
    };

    Make the following changes to the original webComponent block as below (inserting the appropriate value for "<server>"):

    grant codeBase "file:${webComponent}" {
    permission java.io.FilePermission "${was.module.path}${/}-", "read, write";
    permission java.lang.RuntimePermission "loadLibrary.*";
    permission java.lang.RuntimePermission "queuePrintJob";
    permission java.net.SocketPermission "<server>", "connect";
    permission java.util.PropertyPermission "*", "read";
    };

    was.policy

    Location:

    • If WAR deployment: <WebSphere-Installation-Root>/profiles/<profile-name>/config/cells/<cell-name>/applications/terajmsa_war.ear/deployments/terajmsa_war/META-INF

    • If EAR deployment: <WebSphere-Installation-Root>/profiles/<profile-name>/config/cells/<cell-name>/applications/Teradata JMS Universal Connector/deployments/Teradata JMS Universal Connector/META-INF

    The original was.policy file contains the default contents below:

    grant codeBase "file:${application}" {
    };
    grant codeBase "file:${jars}" {
    };
    grant codeBase "file:${connectorComponent}" {
    };
    grant codeBase "file:${webComponent}" {
    };
    grant codeBase "file:${ejbComponent}" {
    };

    Make the following changes to the was.policy file as below (inserting the appropriate value for "<server>" and "<Teradata jdbc path in your system>"):

    grant codeBase "file:${application}" {
    permission java.lang.RuntimePermission "stopThread";
    permission java.lang.RuntimePermission "modifyThread";
    permission java.lang.RuntimePermission "modifyThreadGroup";
    };
    grant codeBase "file:${application}" {
    permission java.lang.RuntimePermission "getClassLoader";
    };
    grant codeBase "file:${application}" {
    permission java.io.FilePermission "<Teradata jdbc path in your system>/tdgssconfig.jar", "read";
    permission java.io.FilePermission "<Teradata jdbc path in your system>/terajdbc4.jar", "read";
    };
    grant codeBase "file:${application}" {
    permission java.net.SocketPermission "<server>", "connect";
    };

    grant codeBase "file:${jars}" {
    };
    grant codeBase "file:${connectorComponent}" {
    };
    grant codeBase "file:${webComponent}" {
    };
    grant codeBase "file:${ejbComponent}" {
    };

  3. After both changes are done (app.policy and was.policy), the server needs to be restarted.
  4. As mentioned in the Teradata Download Center, users may see java.security.AccessControlException in the WebSphere SystemOut.log file.  However, this is expected behavior and implies that the user correctly configured Java 2 security with the JMS Universal Connector.
  5. Detailed information on this configuration can be found here.