C H A P T E R  9

Using BEA WebLogic Servers With the IDE

The standard installation of Sun ONE Studio includes Sun ONE Application Server 7, Standard Edition configured as the default application server. However, you can use other application servers with the IDE. This chapter describes how to configure the IDE environment to use WebLogic Servers.

The IDE installation includes support for two versions of the BEA WebLogic servers: BEA WebLogic Server versions 6.1 SP4 and 7.0 SP2.

This chapter describes:


Configuring the WebLogic Environment

The WebLogic Server Plug-in module is installed with the IDE installation, but is not enabled. To use BEA WebLogic Server 6.1 or 7.0, you must do the following:


procedure icon  To Enable the WebLogic Server Plug-in Support



Note - Do not have any directories containing J2EE platform components mounted in the IDE's filesystem when performing this procedure.



1. Start the IDE.

See for this information.

2. In the main IDE windows, choose Tools right arrow Setup Wizard.

The Setup Wizard opens and displays the General Sun ONE Studio Settings page.

3. Click Next.

The Module Installation page displays.

4. Expand the J2EE Support node.

A list of modules with version information and whether the module is enabled appears.

5. Find WebLogic Server Deployment Module and set the Enabled column to True.

6. (Optional, but recommended) If you are not using the Sun ONE Application Server, disable it by toggling the value in the enabled column to False.

Disabling this unused plug-in support reduces performance overhead while running the IDE.

7. Click Finish.

The IDE is initially installed with the WebLogic Server 7 support as the default, so completing this step enables the general WebLogic Server support and creates an entry for WebLogic Server 7 in the Server Registry.

8. (For WebLogic Server 6.1) To enable the WebLogic Server 6.1-specific plug-in, follow these steps:

a. Choose Tools right arrow Options.

The Options page displays.

b. Expand the Debugging and Executing node and select WebLogic Plugin Options entry.

The property sheet values display in the right hand side of the page.

c. Set the WebLogic Server 6 Support property to True.

d. ((Optional, but recommended) If you don't intend to use WebLogic Server 7, set the WebLogic Server 7 Support to False.

Disabling this unused plug-in support reduces performance overhead while running the IDE.

e. Click Close.

f. Now, continue to To Set the WebLogic Server as the Default Application Server.


procedure icon  To Set the WebLogic Server as the Default Application Server

1. In the IDE Explorer window, select the Runtime tab and expand the Server Registry/Installed Servers node.

The enabled WebLogic Server nodes are visible.

2. Right-click the WebLogic Server node and choose Properties.

The property sheet for the WebLogic server appears.

3. Select the WebLogic Home property.

4. Type the applicable value for the property and close the property sheet. For example on a Microsoft Windows system, type:

Replace the variable bea-install-dir with the pathname to your WebLogic Server installation directory.

5. Add a WebLogic server instance by right-clicking the appropriate WebLogic Server node and choosing Add Server Instance.

6. Set the password value in the property sheet by following these steps:

a. Right-click the WebLogic server instance you just created and choose Properties.

The property sheet for the instance appears.

b. Select the Password property and type the password you specified during the WebLogic server installation as the property's value.

c. (WebLogic Server 7 only) Set the RootDirectory property to the location of the server's config.xml file.

For example, bea-install-dir/user_projects/mydomain

d. Close the property sheet.

7. Right-click the WebLogic Server Instance 1 and choose Set As Default Application Server.

The WebLogic server is now the default application server used by the IDE.



Note - WebLogic Server 7.0 requires that the data sources for CMP beans are TxDataSources rather than DataSources. This requirement differs from WebLogic Server 6.1 requirements and is indicated by a message when the application is deployed to the WebLogic Server 7.0. For more information, see the BEA web site at http://edocs.bea.com/wls/docs70/faq/jdbc.html.




procedure icon  To Configure the IDE to Start the WebLogic Server

To start the WebLogic server from the IDE, you must set the Startup Java Options property.

1. In the IDE, select the Explorer's Runtime tab.

2. Expand the Server Registry node and expand the Installed Servers subnode.

3. Expand the WebLogic Server node to see the instance nodes.

4. Select the instance you want to change and right-click the WebLogic Server Instance node and choose Properties.

The Properties window appears for this instance.

5. Locate the Startup Java Options property and enter the following in the text field:

-Djavaplugin.enabled=true

6. (Optional) If needed, specify additional Java class paths or native libraries for the WebLogic Server using the properties: Extra Class Path and Extra Library Path.

These properties are found on the WebLogic Server property sheet accessed as described above in Step 4.

7. (Optional) If your WebLogic server uses external resources, such as the examples PointBase server included with the WebLogic installation, make sure these resources are available before starting the WebLogic server from the IDE.

The IDE does not automatically detect the external dependency. See for details on configuring an external PointBase installation.


WebLogic Support in a Multiuser Environment

A command-line configuration script is provided to assist system administrators in enabling the WebLogic Plug-in support in a multiuser environment. System administrators setting up a multiuser environment can use the command-line facility to enable WebLogic Server support and disable Sun ONE Application Server 7 for all users.



Note - This procedure must be performed before the IDE is started for the first time.




procedure icon  To Enable WebLogic Plug-in Support for a Multiuser Environment

1. Become a superuser.

2. Change to the IDE installation directory.

# cd s1studio-install-directory/bin

On a Solaris system, the default s1studio-install-directory is /opt/studio5_se.

3. Execute the configuration script with the enable option.

# ./plugin_config.sh -enable weblogic

4. To disable Sun ONE Application Server 7 on a Solaris system, use the disable option, for example:

# ./plugin_config.sh -disable S1AS