Maximo Development Environment Setup

First install your development environment. You can use eclipse version 3.2 or above or another development workbench like Rational Application Developer Version 7. Download and install your workbench. For eclipse it is just a matter of unzipping the zip file into a local directory.

For eclipse you will need to additionally install a jre. You can use the jre already installed in your Websphere installation. Just copy the <install location>\Websphere\AppServer\java\jre to <eclipse install dir>\eclipse\jre.
Configuring the eclipse or RAD workspace

Turn off “Build automatically” setting using preferences->general->Workspace->Build automatically.

Turn off “Scrub Output folders” setting using Java->Compiler->Building->Scrub output folders when cleaning projects

Turn off “Limit console Output” setting using Run/Debug->Console->Limit Console output.

On RAD only you will want to turn off “Perform Incremental Deployment” under preferences->java ee


Turn off “Automatic Publishing” under preferences->Server-> Launching-> Automatically publish when starting servers.

Set the correct java compiler under Preferences-> java ->compiler->Use java compliance settings.
The right Java compiler must be selected:

·  Maximo 6: Java 1.4

·  Maximo 7: Java 1.5

·  Maximo 7.5: Java 1.6

· 

If the compiler you need is not listed, you can add a new java compiler by installing the java version on your development workstation and then adding it to the list. Go to Window -> Preferences -> Java -> Installed JREs and then Add a new JRE pointing to the directory where Java is installed (<install location>\Websphere\AppServer\java\jre).


Project Setup
Create an empty Java project let’s call it test

Right click on the project and select build path -> add libraries.

On the next screen select User Libraries

Click next

Select User libraries

Select new


Enter a name for the library.

Select Add jars

Navigate to <SMP install dir >\maximo\applications\maximo\lib and select all the jars in the directory, then hit ok. The jars should be added to the library.

Next navigate to <smp install dir>/maximo/deployment/default and unzip the maximo.ear file into the workspace.

Select Add jars again and navigate to the directory where the ear has been expanded. Select the businessobjects.jar and the maximouiweb.war file and add it to the library. Click ok to return to the package explorer.

Test the setup

Right click on the project test and select new->package.

Add a package call it mycust.app.ci.

Right click on the package and select new->add class

Name it MyCi

Add some code to it such as this:

package mycust.app.ci;

import psdi.app.ci.CI;

import psdi.mbo.MboSet;

import psdi.util.MXException;

import java.rmi.RemoteException;

public class MyCi extends CI {

public MyCi(MboSet ms) throws MXException, RemoteException{

super(ms);

}

public void modify() throws MXException, RemoteException{

setValue("changeby", "GEORGE",NOACCESSCHECK);

}

}

Verify the class compiles.


Setting up the output folders
Since we will want to rebuild the ear file to deploy the code, we will want the compiled classes to reside in the <smp install dir>/maximo/applications/businessobjects/classes directory. This way we can just call the buildmaximoear.cmd to build a new ear file with our new classes in it.

Right click on the test project and select Properties ->java build path

Check Allow output folders for source folders.

Select the browse button

Select create new folder

Click Advanced

Check link to folder in the file system

Click on Variables

Click New

Define a variable called tpae and set the location to the <smp install dir>/maximo/applications/maximo/bussinessobjects/classes

Click ok on all the screens to create the new output location.

Try a test build and verify the class files are created in the correct path.