Oracle Weblogic




Learn Java in just 5 weeks...
Creating a WebLogic Domain and Server

In this tutorial you use the WebLogic Server Configuration Wizard to create a domain and server to deploy and run the MedRec applications.The tutorial also shows you how to start the server. The Avitek Medical Records Development Tutorials guide you through the process of developing, packaging, and deploying real-world J2EE applications with WebLogic Server. MedRec is an educational tool for all levels of J2EE developers; it showcases the use of each J2EE component, and illustrates best practice design patterns for component interaction and client development Requirement: Have Weblogic Application server installed of your choice may be weblogic 10 latest version available as of today. Go to this link: Click Here!


Proc 1: Create the MedRec domain and MedRec server.
The MedRec domain includes a single server that will host the MedRec back-end services, the MedRec Administration application, and the Patient application (both applications are Web applications). 1. Launch the Configuration Wizard:
Start—>All Programs—>BEA Products—>Tools—>Configuration Wizard
2. In the Welcome window, select Create a new WebLogic domain.
3. Click Next.
4. In the Select Domain Source window, select the option that begins Generate a domain configured automatically ...
5. Click Next.
6. In the Configure Administrative Username and Password window, enter:
  • weblogic for User Name
  • weblogic for User Password and Confirm user Password
  • An optional description.
7. Click Next. 8. In the Configure Server Start Mode and JDK window, select:
  • Development Mode for WebLogic Domain Startup Mode
  • Sun SDK 1.5.0_XX @ JDK_location, under the BEA Supplied JDKs option, for JDK Selection
9. Click Next. 10. In the Customize Environments and Services Settings window, select Yes. 11. Click Next. 12. In the Configure the Administration Server window, enter or select:
  • MedRecServer for Name.
  • All Local Addresses for Listen Address.
  • 7101 for Listen Port.
  • The SSL Enabled check box.
  • 7102 for SSL Listen Port.
13. Click Next. 14. Select Next in the following windows without making any changes:
  • Configure Managed Servers
  • Configure Machines
15. In the Review WebLogic Domain window, click on MedRecServer in the left pane and review your choices, then click Next. 16. In the Create WebLogic Domain window:
  • Enter MedRecDomain as the Domain Name.
  • Click Create to create the MedRec domain in the folder displayed in the Domain Location text box. When the Configuration Wizard finishes creating the domain, the Domain Created Successfully! message is displayed.
17. Click Done to close the Configuration Wizard.
  • Do not check Start Admin Server.

Proc 2: Enable log4j for logging application messages.

The MedRec application suite uses log4j for logging application messages. You must copy the log4j properties file from the pre-configured MedRec domain and identify it using a startup option in MedRecServer startup script. You also need to copy the log4j jar files to the lib directory of the MedRec domain. To complete these steps: 1. Copy the log4j properties file from the pre-configured MedRec domain (under the main WebLogic Server installation directory) to the new domain you just created. For example, if you installed WebLogic Server in the c:\bea directory, then enter the following in a command-line shell: prompt> copy c:\bea\weblogic91\samples\domains\medrec\log4jConfig.xml c:\bea\user_projects\domains\MedRecDomain

2. Open the setDomainEnv.cmd script, located in the bin directory of your newly created domain directory, for your new domain in a text editor. For example: prompt> notepad c:\bea\user_projects\domains\MedRecDomain\bin\setDomainEnv.cmd

3. Find the following line in the setDomainEnv.cmd script: if NOT "%LOG4J_CONFIG_FILE%"=="" (

4. Add the following two lines immediately before the line specified in the preceding step: set LOG4J_CONFIG_FILE=c:\bea\user_projects\domains\MedRecDomain\log4jConfig.xml for %%i in ("%LOG4J_CONFIG_FILE%") do set LOG4J_CONFIG_FILE=%%~fsi It is assumed in the preceding text that the MedRecDomain directory is c:\bea\user_projects\domains\MedRecDomain; enter your exact domain directory if it is different.

5. Save the file and exit your text editor.

6. Copy the log4j JAR files from the lib directory of the pre-configured MedRec domain to the lib directory of the new domain you just created: prompt> copy c:\bea\weblogic91\samples\domains\medrec\lib\*.jar c:\bea\user_projects\domains\MedRecDomain\lib All JAR files in the lib subdirectory of a domain directory are automatically added to the WebLogic Server system CLASSPATH when the servers in the domain start up.


No comments:

OTN Discussion Forums: Message List - Database - General

Ask Tom HOT ARTICLES

 
© Copyright 2008 - 2011. All rights reserved to dba-sansar.blogspot.com.
All other blogs, posts and entries are the property of their respective authors.
Please email us for your comments and suggessions Click Here