Friday, February 18, 2011

Using SAP extension in WebSphere Portlet Factory and WebSphere Application Server Community Edition

I have WebSphere Portlet Factory 7.0 running on Ubuntu Linux 10.10. I also used WAS CE  version 2.1.1.4 as the test environment.

I have to do the following to allow SAP extension

  • Get the SAPJCo from SAP administrator
  • Install the SAPJCO according to the documentation provided by SAP for linux environment
  • Add class path variable into /etc/environment:
           CLASSPATH="/opt/sapjco/sapjco.jar"
  • Add path to the /opt/sapjco folder. (This is also done in /etc/environment file).  The following is the content of my /etc/environment file
                  PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/opt/sapjco"
                      LD_LIBRARY_PATH="/opt/sapjco"
                        CLASSPATH="/opt/sapjco/sapjco.jar"
      • Add "LD_LIBRARY_PATH=/opt/sapjco" at the end of /etc/bash.bashrc file
      • Restart your system
      • Follow the instruction in http://publib.boulder.ibm.com/infocenter/wpfhelp/v6r1m0/index.jsp?topic=/com.bowstreet.designer.doc/get_start/sap_getting_started.htm
      After the above steps, I am able to do a "Test Connection" from the builder, however, when trying to test the application, I got "noclassdeffounderror" for the jco class. In order to fix that, I have to update geronimo.sh file and add /opt/sapjco, into $EXT_DIRS variable.

      Restart your server after that. Then you should be able to test the model

      No comments:

      Post a Comment