CWK_Technical Overview4

Download Report

Transcript CWK_Technical Overview4

Technical Overview
http://aboutcoursework.stanford.edu
Academic Computing
Stanford University Libraries
System Requirements
•
•
•
•
•
Solaris or Linux operating system (recommended)
Java 1.3 or later
Java Servlet Container
Oracle 8i or later
Apache Web Server (recommended)
Servlet
Container
JDBC
Oracle
DB
http://aboutcoursework.stanford.edu
Academic Computing
Stanford University Libraries
Version History
Major releases each Fall, minor
maintenance updates in Winter and Spring:
–
–
–
–
–
–
–
Version 1.0 released Fall 2001.
Version 1.1 released January 2002.
Version 1.2 released March 2002.
Version 2.0 released September 2002.
Version 2.1 scheduled for January 2003.
Version 2.2 scheduled for March 2003.
Version 3.0 scheduled for September 2003.
http://aboutcoursework.stanford.edu
Academic Computing
Stanford University Libraries
Java Web Application
•
Installs as a Web Application Archive (WAR) file.
•
Runs in a Java Servlet Container
–
We use Tomcat 3.2.3
•
Java Servlet Specification 2.2
•
Plans to update to Tomcat 4 and Servlet Spec 2.3
•
Uses only servlets, no JSPs.
•
We use Apache Web Server/Tomcat combination
–
mod_jk
http://aboutcoursework.stanford.edu
Academic Computing
Stanford University Libraries
Oracle Database
• Oracle 8i (8.1.7)
• Oracle 8i JDBC drivers (classes12.zip)
– Thin Driver or OCI-8 driver.
– OCI-8 requires installation of Oracle client on app server.
• Oracle 8i Connection Pool implementation
• Single user schema
http://aboutcoursework.stanford.edu
Academic Computing
Stanford University Libraries
CourseWork Web Application
•
Core packages
–
–
•
Tool packages
–
–
–
•
edu.stanford.coursework.core
edu.stanford.coursework.common
edu.stanford.coursework.coursehome
edu.stanford.coursework.announcements
Etc
Dynamic Templating Language (DTL)
–
edu.stanford.coursework.dtl
•
Servlets
•
DTL Templates
http://aboutcoursework.stanford.edu
Academic Computing
Stanford University Libraries
Core Objects
• Person, Nexus, Tool, Content
Tool
Person
Nexus
Content
http://aboutcoursework.stanford.edu
Academic Computing
Stanford University Libraries
Core Objects (continued)
• Person Object
– Represents a user in CourseWork
• Nexus Object
– Represents a course, a section, a department, etc.
– Grouping of people, tools, and content.
– Definable NexusTypes.
• Tool Object
– A tool that shows up in the navigation bar
– Allows tools to be turned on/off for each Nexus
• Content Object
– A single piece of content that is used in a Nexus.
– Referenced by URL and/or filepath.
http://aboutcoursework.stanford.edu
Academic Computing
Stanford University Libraries
Person Object (example object
model)
• Person.java
– fields map to database fields
– get and set methods for each field
– toDTLObject method
• PersonController.java
– Methods to get, create, save, remove object in DB
– Other static methods to use/manipulate object
•
PersonSQL.java
– SQL query strings used in preparedStatements to interact with
the database
http://aboutcoursework.stanford.edu
Academic Computing
Stanford University Libraries
Dynamic Templating Language
(DTL)
• Developed at Highwire Press, Stanford University
• Installs as a JAR file
• Parsed HTML Templates with rich variable replacement
capabilities
• Also provides date/time display functionality and
configuration file parsing functionality for CourseWork
• Simple Examples:
[[VARDEF $COLOR]]#CCCCCC[[/VARDEF]]
This font color is <FONT COLOR=[[$COLOR]]>grey</FONT>.
Or in Java Code:
DTLObject mainDTL = new DTLObject();
mainDTL.put(“COLOR”, “#CCCCCC”);
http://aboutcoursework.stanford.edu
Academic Computing
Stanford University Libraries
Tool Model
•
Two servlets – student view and admin view
– Eg, Announcements.java and AdminAnnouncements.java
•
edu.stanford.coursework.<toolname> package.
– Uses same object model as core object
•
DTL Templates
•
Database tables
http://aboutcoursework.stanford.edu
Academic Computing
Stanford University Libraries
CourseWork Documentation Site
http://coursework-dev.stanford.edu/docs
–
–
–
–
Javadocs
Database Schemas
DTL Javadocs and instructions
3rd party packages used by CourseWork (oreilly, etc)
http://aboutcoursework.stanford.edu
Academic Computing
Stanford University Libraries