Step 6: Installing the payments cassette plug-in in the runtime server

In this part of the tutorial you will learn how to install your new payment plug-in to an existing WebSphere Commerce instance.

  1. Ensure that WebSphere Commerce is installed and a WebSphere Commerce instance is created and started.
  2. Stop your target WebSphere Commerce application:
    1. Open the WebSphere Application Server administrative console by entering the following URL in a Web browser: http://your_fully_qualified_server_name:port/ibm/console
      where:
      • your_fully_qualified_server_name is the name of your target machine.
      • port is the port number of the administration console for the profile where WebSphere Commerce instance is deployed.
    2. Click Applications > Enterprise Applications to see a list of installed applications.
    3. Select your WebSphere Commerce application, for example WC_demo, and click Stop.
  3. Copy the plug-in JAR file to the temporary location:
    C:\tempdir\Payments-Plugin-MyWCPayments.jar.
  4. Export a backup copy of the EAR file, so that you can revert to the old version in the future if you want to. To export a backup copy of the EAR file:
    1. In the WebSphere Application Server administrative console, click Applications > Enterprise Applications to see a list of installed applications.
    2. Select your WebSphere Commerce application, for example WC_demo, and click Export.
    3. Follow the wizard and save your EAR file in a backup directory. If the EAR file is large, this action might take some time.
  5. Add the EJB module to the EAR project:
    1. In the WebSphere Application Server administrative console, select the application name, for example WC_demo, and click Update.
    2. Select Single Module.
    3. In the Relative path to module field, type Payments-Plugin-MyWCPayments.jar.
    4. Select Local file system and specify the path to the Payments-Plugin-MyWCPayments.jar file. For example, drive:\ImportTemp\ Payments-Plugin-MyWCPayments.jar.
    5. Click Next.
    6. In the Prepare for the application installation screen, leave all default values and click Next.
    7. On the Application Security Warnings screen, click Continue.
    8. On the Install New Application screen, click Step 10: Summary.
    9. A summary of changes is displayed. Click Finish.
    10. When the update is completed successfully, click Save to Master Configuration.
    11. On the Enterprise Applications screen, click Save to save your changes to the master configuration. All your changes are saved.
    12. Close your WebSphere Application Server administration console.
  6. Copy the deployment descriptor file and other required configuration files (profiles for this tutorial) to the following location:WC_eardir/xml/config/payments/ppc/plugins/MyWCPaymentsPlugin/<FileName> Where:
    • MyWCPaymentsPlugin represents the name of the plug-in. (Be sure to create a subdirectory with the plug-in name.)
    • <FileName>

      (Required) PluginDeployment.xml to store the configuration information of this plug-in.
      (Optional) PluginProperties.xml to store the parameters of merchant configuration information should be encrypted.
  7. Ensure that the name of the plug-in inside the deployment descriptor matches the name of the directory in which you placed the deployment descriptor.
  8. Configure the payment plug-in for WebSphere Commerce server according to step 4 of this tutorial.
    Stop and start WebSphere Application Server to pick up the changes that you made:
    1. At a command prompt, navigate to WC_profiledir\bin.
    2. Stop the WebSphere Application Server. For example, on the Windows operating system, type stopServer server1. The server has stopped successfully when you see the message: Server server1 stop completed.
    3. Start the WebSphere Application Server. For example, on the Windows operating system, type startServer server1. Wait until you see a message similar to: Server server1 open for e-business; process id is 3740.
    4. Navigate to WC_profiledir\logs\server1.
    5. Examine the SystemOut.log file. Check that the server started successfully without errors.
Now you can place orders with the new payment method and the new payment plug-in.