![]() ![]() ![]() ![]() ![]() ![]() |
This tutorial describes how to set up and use the new MedRec server instance in development mode. WebLogic Server provides two distinct server modes—development mode and production mode—that affect default configuration values and subsystem behavior for all server instances in a domain.
Development mode enables you to use the demonstration trusted CA certificates for security, and also allows you to deploy the MedRec applications directly from a development environment. (You will create the development environment in the next set of tutorials). For these reasons, you should always use development mode when building or testing your own applications.
Note: | Because newly installed WebLogic Server instances use development mode by default, the steps in this tutorial are not strictly required. However, later tutorials that describe how to move from a development to a production environment depend on the changes you make now. |
The tutorial includes the following sections:
Create the MedRec server domain. See Tutorial 1: Creating a WebLogic Domain and Server Instance for Development. You will modify the server start script that was created during that tutorial.
To put the MedRec server in development mode:
You must shut down the MedRec server because you edit its start script to explicitly place the server in development mode.
If the server is not currently running, go to Step 2: Edit the server startup file.
http://
host
:7101/console
where host
refers to the computer on which MedRecServer is running. If your browser is on the same computer as MedRecServer, then you can use the URL http://localhost:7101/console
.
weblogic
for both the username and password and click Log In.MedRecServer(admin)
.MedRecServer
.Note: | Because you are shutting down the Administration Server, which is what you connect to when you invoke the Administration Console, you will get message in your browser once the server actually shuts down, saying it is no longer available. |
Development mode (or production mode) is set for all servers in a given domain by supplying a command line option to the domain's Administration Server. Because the MedRec tutorials use two stand-alone servers in separate domains, you must edit each server's startup script to add the command line option.
prompt> cd c:\bea\user_projects\domains\MedRecDomain\bin
setDomainEnv.cmd
(Windows) or setDomainEnv.sh
(UNIX) script in a text editor:prompt> notepad setDomainEnv.cmd
PRODUCTION_MODE
script variable:set PRODUCTION_MODE=
PRODUCTION_MODE
variable to ensure the server starts in development mode:set PRODUCTION_MODE=false
Reboot the server to ensure that it starts up in development mode:
prompt> c:\bea\user_projects\domains\MedRecDomain\startWebLogic.cmd
<Dec 9, 2005 11:35:57 AM PST> <Notice> <WebLogicServer> <BEA-000331>
<Started WebLogic Admin Server "MedRecServer" for domain "MedRecDomain" running in Development Mode>
weblogic.Server
command-line arguments -DProductionModeEnabled=true | false
to set the server mode.
The MedRec application uses the sample trusted CA certificates installed with WebLogic Server to enable SSL authentication and demonstrate WebLogic Server security features in later tutorials. Development mode allows you to use the sample certificate files when you work through later security tutorials.
In the next series of tutorials, you will create a development directory structure for MedRec that shows how to manage source code and compiled code separately when developing Enterprise Applications with WebLogic Server. Development mode allows you to deploy applications directly from the development directory, without having to package applications into .jar
files or exploded .jar
directories.
![]() ![]() ![]() |