background image
<< Adding Stub Files | The wl_deploy Build Folder >>
<< Adding Stub Files | The wl_deploy Build Folder >>

Deploying Stubs to a Running Server

Deploying Stubs to a WebLogic Application Server
61
10
Delete the .class files from the JAR file.
11
Add the stubbed .class files to the JAR file:
a
Click the
Add
icon on the Winzip toolbar.
b
Navigate to the stub directory and make sure that
Save full path info
is checked.
(It's in
Folders
options.)
c
Select all three .class files and then click
Add
.
d
Close the archive file.
12
Copy the modified JAR file to the appropriate WebLogic directory, for example:
<
WebLogic Home
>
\myserver\RatlBankAcct
, for WebLogic 5.1.
<
BEA Home>\wlserver6.1\config\examples\applications
, for WebLogic 6.1.
13
Before executing any test scripts and stubs, be sure that you have met the
requirements discussed in Requirements for EJB Testing on page 31, particularly the
classpath requirements for WebLogic and the classpath requirements for playback
from TestManager.
14
Restart the WebLogic application server to deploy the stubs.
Deploying Stubs to a Running WebLogic Server (Hot Deployment)
After you generate stubs and lookup tables (see Generating Stubs and Lookup Tables for
the Unit Test
on page 56), you need to deploy the stubs to the WebLogic server before
you can actually run the test script associated with the stub.
With WebLogic, it is possible to deploy these stubs to a WebLogic server without
stopping the server. This is known as hot deployment. With this feature, you can deploy
your generated stubs and test your deployed EJBs right away, before they are
deployed permanently to the WebLogic server. Any EJBs that you hot deploy to the
WebLogic server are only deployed temporarily for staging and testing purposes.
Once you stop and restart the server, the EJBs will no longer be deployed.
The following procedures use the Rational Bank Account sample application as an
example. For information about how to permanently deploy the Rational Bank
Account sample application to a WebLogic server, see Deploying the Sample Application
to a WebLogic Application Server
on page 45. For information about permanently
deploying stubs to a WebLogic server, see Deploying Stubs Permanently to a WebLogic
Server
on page 60
.