WebObjects 5: Converting WebObjects 4.5 Projects

This article explains how to convert WebObjects 4.5 projects to WebObjects 5.0 format with Mac OS X.

These instructions explain how to convert WebObjects 4.5 projects to WebObjects 5.0 format with Mac OS X. They should be used in conjunction with the instructions for using the JavaConverter tool. The JavaConverter instructions, in pdf format, are available at http://developer.apple.com/techpubs/webobjects/JavaConverter.pdf

Have the JavaConverter instructions available when you step through the instructions below.

Converting WebObjects 4.5 Projects to WebObjects 5.0 Format

Step 1

Open /Developer/Applications/ProjectBuilderWO and then open the WebObjects 4.5.x project.

Step 2

In the build pane, click the "clean" button. Close ProjectBuilderWO; it will not be used again during this procedure.

Step 3

Run the JavaConverter according to the instructions in the JavaConverter document. On Mac OS X the JavaConverter is located in /System/Library/WebObjects/JavaApplications. It is possible to run the JavaConverter on Mac OS X as well as Mac OS X Server (1.2 and 10.0). The instructions in the JavaConverter.pdf document work with all these platforms.

Step 4

Open /Developer/Applications/ProjectBuilder.

Step 5 (Primary Version)

Choose Import Project from the File menu.

In the "Import Project Assistant" choose "Import PB.proj" and click Next. Click Set to locate the converted project, or enter its location in the text box.

Once the converted project has been imported, add the JavaJDBCAdaptor.framework by choosing Add Frameworks from the Project menu. This framework is located at /System/Library/Frameworks/JavaJDBCAdaptor.framework. In the sheet that appears, be sure to click on the Application Server Target so that the framework is added to it.

Step 5 (Alternate Version)

You should use this alternate version of the Step 5 instructions only if the Step 5 (Primary Version) instructions do not result in a workable project.

Create a new project of the same type as your converted project. For example, if you convert a "WebObjects Application" you will want to create a project of type "WebObjects Application" within ProjectBuilder.

In the Finder, navigate to the converted project's directory. Drag and drop the needed components, resources, and so forth to the "Groups & Files" section of the new project's window. You will be able to place the files in the appropriate places inside the new project hierarchy. Be sure to select the "Copy items into destinations group's folder (if needed)" checkbox and the "Create Folder References for any added folders" radio button in the sheet that appears when you release the mouse button.

Step 6

Search for the JC_ERROR, JC_WARNING, and JC_INFO messages in the converted project and fix them as needed. This is a manual process and may take some time depending on the size of the project.

Also, be sure to see reference 2628707 at http://developer.apple.com/techpubs/webobjects/ReleaseNotes/ReleaseNotes.html for more information on the conversion, including NSValidation issues.

Step 7

Open the model file and change the connection dictionary information and update the external/internal types. This is a manual process that updates the model file for use with the JDBC adaptor. Depending on your database and original model file, it may be quicker to create a new model file than convert an existing one.

 

Your project should now build successfully.

For information on how to set up the JDBC URL refer to your database's documentation, or refer to article 75145: "WebObjects 5: How to Use Oracle JDBC Drivers".

Published Date: Oct 10, 2016