JSP Server Integrated with Oracle8i - PowerPoint PPT Presentation

About This Presentation
Title:

JSP Server Integrated with Oracle8i

Description:

Send the explicit data back to client (HTML) ... To access your account settings, click A HREF='Account-Settings.html' here. /A /SMALL ... – PowerPoint PPT presentation

Number of Views:48
Avg rating:3.0/5.0
Slides: 12
Provided by: yiz55
Category:

less

Transcript and Presenter's Notes

Title: JSP Server Integrated with Oracle8i


1
JSP Server Integrated with Oracle8i
  • Project2, CMSC691X
  • Summer02
  • Ching-li Peng
  • Ying Zhang

2
Outline
  • Introduction
  • Servlet and JSP
  • Oracle and JDBC
  • Project
  • Goal
  • Installation of JSP server
  • Installation of Oracle8i

3
Servlet
  • Read explicit data sent by client (form data)
  • Read implicit data sent by client (request
    headers)
  • Generate the results
  • Send the explicit data back to client (HTML)
  • Send the implicit data to client (status codes
    and response headers)

4
JSP
  • Java Server Pages (JSPs)
  • Use regular HTML for most of the page
  • Mark dynamic content with special tags
  • lt!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0
    Transitional//EN"gt
  • ltHTMLgt
  • ltHEADgtltTITLEgtWelcome to Our Storelt/TITLEgtlt/HEADgt
  • ltBODYgt
  • ltH1gtWelcome to Our Storelt/H1gt
  • ltSMALLgtWelcome,
  • lt!-- User name is "New User" for first-time
    visitors --gt
  • lt Utils.getUserNameFromCookie(request) gt
  • To access your account settings, click
  • ltA HREF"Account-Settings.html"gthere.lt/Agtlt/SMALLgt
  • ltPgt
  • Regular HTML for rest of on-line stores Web page
  • lt/BODYgtlt/HTMLgt

5
Oracle
  • Client/Server
  • Large databases
  • Support concurrent accesses from a large number
    of users
  • High transaction processing performance
  • High availability
  • Openness, industry standards 
  • Manageable security
  • Distributed system

6
JDBC
  • Java Database Connectivity
  • A standard or open application programming
    interface (API) for accessing a database from
    JAVA programs.
  • Allow Java to run and process SQL
  • Select, Update, Insert, Delete, and
  • Oracle JDBC Thin driver
  • Use Java socket to connect directly to Oracle
  • Provide its own implementation of a TCP/IP
    version of Oracles Net8

7
Project Goal
  • Install
  • Linux Redhat7.2
  • JSP server Tomcat3.3
  • Database Oracle8i (8.1.7)
  • Write a test servlet
  • Retrieve the data from database and show the
    result on clients browser

8
JSP Server Tomcat
  • Installation
  • Download Tomcat3.3
  • Unzip it
  • Make sure the path includes the JDK bin
    directory.
  • Update the CLASSPATH to include
  • install_dir\lib\servlet.jar
  • install_dir\lib\jasper.jar
  • Problems
  • NONE!
  • What we learned
  • TOMCAT is great!

9
Oracle8i
  • Pre-Installation
  • Create group dba and oinstall
  • Create user oracle and add it to these two groups
  • Make sure jdk1.1.8_v3 is installed under
    /usr/local
  • Create installation directory, /u01, with
    ownership of oracle
  • Login in as oracle and modify the .bash_profile
    file under its home directory(/home/oracle)

10
Oracle8i (Cont.)
  • Installation
  • Download oracle8.1.7 and unzip it
  • Run the universal installer, runinstaller.sh
  • Follow the instructions on the screen to finish
    the installation of Oracle Enterprise Edition
  • Problems
  • The installation files are actually buggy
  • Oracle9i requires large memory and disk space
  • What we learned
  • Installing Oracle8i on Redhat7.2 is reasonably
    tough

11
Test Servlet
  • Function
  • Establish network connection to Oracle via JDBC
    driver
  • Retrieve all the records of table Employ in
    Oracle 8.1.7
  • Show the retrieved data from Oracle in a HTML
    table in users browser
Write a Comment
User Comments (0)
About PowerShow.com