Docsity

Database-stored Emails: Faster Access, No Corruption - Prof. Francis T. Marchese, Study Guides, Projects, Research of Software Engineering

Partial preview of the text

Download Database-stored Emails: Faster Access, No Corruption - Prof. Francis T. Marchese and more Study Guides, Projects, Research Software Engineering in PDF only on Docsity!

(mail)

n

Elaboration Three

CS

Fall 2004

Dr. Marchese

December 22, 2004

Prepared by:

Elias Rosero

Jwalant Dholakia

Joseph Aulisi

Vision

Revision History

Version Date Description Author(s)

Final

Inception

Document

December 22, 04 Final Draft. No major modifications

from the first draft submitted on

October 27, 04 have been identified.

Joseph Aulisi

Elias Rosero

Jwalant

Dholakia

Introduction

Our team sees (mail)

n

as an email program designed to house all the email received by an

organization and its users in a form that is easily searchable, expansive, and permanent.

Positioning

Business Opportunity

Organizations today have a wide variety of email systems from which to choose, though

none of them guarantee against data loss, and many are prohibitively expensive to

employ and maintain. Although many systems offer users the ability to view their email

via a client program installed on the user’s machine, or via a web-based client, email

itself is stored in proprietary data files, or plain text files, which can grow quite large,

thus becoming unwieldy, and can have an adverse effect on the speed at which mail is

retrieved and read.

Problem Statement

Email systems today are not secure and can potentially lose the data they were designed

to store. Many systems that store email messages in a proprietary format keep mail in a

single file, which, over time, is at a high risk of corruption. When this corruption occurs,

users can expect to lose all of their messages. Some systems, due to their omnipresence,

are often exploited by malicious virus attacks, which can compromise a client machine

and propagate around the world in a matter of minutes, leaving a path of infected

computers with no chance of recovering data.

Product Position Statement

(mail)

n

is designed for use by small to mid-sized organizations that are looking for an

email system that provides its users with the ability to view their email securely from any

web browser. Each user’s email is stored in a database, which offers a virtually unlimited

mailbox size for each user, and offers the ability to quickly locate past emails. Apart from

being a rock-solid email program, (mail)

n

offers a convenient contact management tool,

and a task database, which allows corporate users the ability to schedule inter-office

meetings.

Alternatives and Competition

Currently, there are many alternatives to (mail)

n

, including Microsoft Exchange, Lotus

Notes, and even outsourced email services. One of the problems with outsourcing email

and will need to collaborate with an external mail service, and a database, as shown in

figure Vision-1.0.

Figure Vision-1.0. (mail)n system context diagram

Summary of Benefits

Because (mail)

n

is web-based, the system is accessible from anywhere in the world. Users

are able to login and access all the information they need. An employee will be able to

save every correspondence they receive and send while working at an organization. Since

the system is regularly backed up, there is no need to fear loss of emails. (mail)

n

is not

prone to virus attacks, so the data remains safe. People using (mail)

n

will already be

familiar with point navigating web sites, so there is no need to train them to use this

system.

Summary of System Features

  • all data is stored in a database, which allows for fast searches, and eliminates the

possibility of email file corruption

  • there is no need to delete emails
  • users can store all contact information in the system
  • users can set up meetings by sending an email to fellow employees. If fellow

employees agree to meet at the specified date and time, the tasks for the agreeing

employees are updated to reflect this appointment

  • the contact module easily interfaces with mail module, which makes addressing

emails easy

Other Requirements and Constraints

For an in-depth look at the design constraints, functionality, usability, reliability and

performance, see the Supplementary Specification and Use Case models.

(mail)

n

<>

Database

Service

<>

Mail Service

<>

Web Service

Calls upon

services

Calls upon

services

services

Employee

Administrator

Use-Case Model

The use-case model used in this document to describe (mail)

n

is accomplished using the

‘fully dressed’ format. Given the nature of the system, it is empirical to enumerate as

many details as possible about the system for completeness.

Before presenting the use-case scenarios, we must illustrate the relations between actors

and their goals. Namely:

Actors Goals

Web-server Inter-median between the database and the mail server

and the user. It also provides an interface for the user.

Mail-server This is where the emails are stored at first. They are

held there until they are read and processed into the DB

Database Stores mail messages, contact information, and task

information. Also returns information when queried.

User Must be able to send, receive, read, and store emails.

Must also be able to manage contact groups and tasks.

Administrator To create, or delete an account within the system.

Having identified the set of ‘actors’, and their respective goals, we continue to map out

the first use case scenario, in which the primary actor is a user.

Use Case UC1: Processing Messages

Primary Actor: User

Stakeholders and Interests:

  • User: Wants to navigate through the email system easily and be able to send, receive

and store emails. In addition, the user also wants the ability to manage contact groups,

and edit tasks.

  • Administrator: Wants to be able to create, modify or delete accounts.
  • Company: (given that (mail)

n

is used within a corporation, although it could be used

by anyone.) Wants to ensure that all of the employees using the system can easily do

so without the need of someone to assist the employees. Also, the system has to be

virus resistant, because employees will rely on having the ability to store information.

The information must be guarded for safe retrieval.

Preconditions: User is connected online, and is using a modern web browser.

Success Guarantee (Post conditions): Emails are sent, received and stored. Tasks are

correctly managed, and contact information is correctly updated. Administrators have full

control over the user accounts.

6b. The user enters an incorrect email address in the recipient’s box:

  1. The system will email the user shortly after the message has been sent, notifying

the user that the email address does not exist.

  1. The user wants to send an email attachment larger than 10MB:
    1. The system will display an error message stating that the attachment exceeds

10MB (the limit size of attachment per email).

  1. The administrator wants to enter a new user’s information:
    1. The new username must not exceed 12 alphanumeric characters.
    2. The new password must not exceed 8 alphanumeric characters.
  2. The user wants to add a new task:
    1. The user may not add a new task that takes place earlier than the present time at

which the user wants to add the new task.

  1. An error message is presented stating that the task must be set to a future date.

Special Requirements:

  • The front end of (mail)

n

requires a modern web browser that understands Dynamic

HTML and Cascading Style Sheets.

  • Users are required to have an Internet connection.
  • User-friendly front end.

Frequency of Occurrence: The system could be used as frequently as needed.

Open Issues:

  • What can be customized for using the system within corporations versus using it

publicly?

This particular fully dressed Use Case pinpoints the various ‘paths’ that a given

user may take when using (mail)

n

. It illustrates the ‘happy path’ as well as all of the areas

in which the system may display an error message due to an improper use. It is explicit

in pointing out the system’s limitations, as well as the user’s limitations. This

information is essential that is needed to have a formal set of system constraints.

Supplementary Specification

Revision History

Version Date Description Author(s)

Final

Inception

Document

December 22, 04 Final Draft. No major modifications

from the first draft submitted on

October 27, 04 have been identified.

Joseph Aulisi

Elias Rosero

Jwalant

Dholakia

Introduction

This section documents various (mail)

n

requirements and specifics not captured in the use

cases.

Functionality

Logging and Error Handling

Make a log of all identified errors for future review.

Pluggable Business Rules

Depending upon the requirement of client Company some minor modifications in the

look and feel of the system (like changing menu system, color, adding company logo etc)

can be added.

Security

(mail)

n

is a web-based e-mail system. So, in order to ensure that only company

employees who have the right to use the system are using it, and no one else, user

authentication is of prime importance.

Usability

Human Factors

  • (mail)

n

is going to be used in an office environment by employees and company

administrators. The employees might end up spending a good deal of time using

(mail)

n

in any given day. So, it is extremely important that (mail)

n

is user friendly.

  • The text size should be large enough so that it does not get difficult and

cumbersome to read messages after an entire day in front of the computer screen.

  • The employee should be given an audible signal when a new mail arrives because

he might not be constantly monitoring the (mail)

n

browser to check for new mails

(Proposed).

  • It is also important that the new incoming messages do not take too much time to

open up as this might increase the frustration and stress on part of the employees

using (mail)

n

.

Free Open Source Components

(mail)

n

makes heavy use of open source components. PostgreSQL is an open source

database. The pages of (mail)

n

are served with Tomcat, an open source Java environment

from the Apache Software Foundation. The heart of the send and receive functions of the

system are built with JavaMail, which is free to use.

Interfaces

Noteworthy Hardware and Interfaces

  • Server
  • Internet Connection Hardware

Software Interfaces

  • Web Browser

Domain Rules

ID Rule Changeability Source

RULE 1 User Authentication required

before showing (mail)

n

mails

page

Low (mail)

n

policy

RULE 2 Idle connections for more than

15 minutes automatically

logged out of (mail)

n

Depending upon business

rules of a company for

which (mail)

n

is set up,

modification can be

made into the system to

disable this feature

Company policy

RULE 3 Once browser window is

closed, the user is

automatically logged out of the

system. Re-authentication

required to login again

To enhance security of

(mail)

n

we keep

changeability of this rule

to Low

(mail)

n

policy

Legal issues

Making sure all terms and conditions specified in the open source software user-

agreement are satisfied.

Strictly enforce (mail)

n

user agreement upon client companies.

Information in Domains of Interest

Network connectivity

If the Local Area Network on the client company site goes down, all local machines on

the company network might not be able to access mail using (mail)

n

even if the Internet

Network and (mail)

n

server are up and running. In this case, the company might be

willing to invest in a stand-alone computer that is directly connected to an outside

network to access important messages.

Term Definition and Information Aliases

To The addressee of a new mail message recipient

From The original sender of a mail message

CC Additional recipients of a mail message

BCC Blind carbon copy, which conceals recipients of a

message from other recipients

Flag An attribute of a mail message

Attachment A separate file that is part of a mail message

Forward The action of sending a received message to another

party

Reply The action of answering a received message with a

response the to the sender

Reply All The action of answering a received message with a

response to the sender and all parties to which the

message was addressed

Flagged An attribute of a message that has been distinctly

marked, as to alert the user that this message needs

additional attention

Body The part of an email that carries the actual semantic

message

Subject The part of an email that contains a summary of the

body of the message

Timestamp The date and time a message was sent or received

Read (pronounced reed) The action of opening an email

message and reading its contents

Read (pronounced red) The state of a message after it has

been opened and scrutinized

Unread The state of a message before it has been opened

Mail-id A unique identifier for each mail message mailid

Group A user-defined list of intended recipients of messages

Invitation A message sent to a group of employees asking them to

attend a meeting

Envite, evite,

invite, nvite

Public A contact that is visible to all users of (mail)

n

Private A contact that is visible to only the user that created the

contact

Category An attribute of the Contacts table that records if a

contact is public or private

Domain Model

Conceptual Class Category Examples

physical or tangible objects

Physical Network, Internet Access

Terminals, and Server

specifications, designs, or

descriptions of things

System Documentation, Prototypes,

and Interface Design

Places Company Offices, and Physical Server

Location

roles of people Administrator, and User

containers of other things Server Storage Drives

things in a container Data (e-mails, contact information etc)

other computer or electro-mechanical

systems external to the system

Internet, Web Servers, and Browsers

abstract noun concepts Workaholic, and Technical

Organizations End User Company

Events Mail Sent, Mail Received, Mail

Deleted etc

processes

(often not represented as a concept,

but may be)

New user account Created

rules and policies Terms and Conditions of E-mail

Service use, Certificate of Liability

records of finance, work, contracts,

legal matters

Contract signed with Customer

Company

Catalogs Special Features of (mail)n listed for

access to potential buyer companies

manuals, documents, reference

papers, books

User Guide/Manual, Documentation,

Troubleshooting Manual, FAQ’s

Finding Conceptual Classes using Main Success Scenario

The following Conceptual Classes have been identified from Main Success Scenario

(Basic Flow) and other alternative scenarios for (mail)

n

specified in the Inception

Document

  • User
  • Internet
  • (mail)

n

website

  • Username / password
  • Database system
  • Inbox
  • Options
    • Reply, CC
    • Subject
    • Body
    • Send
    • Logout
    • User Groups
    • (mail)

n

Database

The following is a graphical representation of (mail)

n

Domain model specified without

attributes and associations:

Figure 2.0 Refined Domain Model

User

User-Id

Name

Add

Mail

Mail-Id

Administrators

To / Cc / Bcc

Email Add

Subject

Text

Body

Text

Mail Server

(mail)

n

website

Username/pwd

Username

Password

Internet

Inbox / Sent /

Erase /

New_Folder(s)

Mails

Tasks

Date

Time

Contacts

Name

Add

Reply/Send

Msg/ Forward

Options

Is-associated-with

can-create

can-have

can-create

has-access-to

consists-of

contains

is-connected-to

Interfaces-with

is-associated

  • with

can-create

logs-on-to

User Groups

can-create

(mail)

n

Database

is-connected-to

is-connected-to

Can-Search

Design Model: Use-Case Realizations

So far, we have used SSDs to illustrate the system boundary and identify the system

events. Then we used those system events to elaborate the operation contracts, which

shows the system operations associated with the domain model.

Now, we are going to present Use- Case Realizations. The system events are going to be

used once again. But within interaction diagrams, which illustrate how objects interact to

complete the tasks that the system must be able to perform.

As described in the SSD, the most important system events are:

♦ Process Message: read(), send()

For each system even, we are going to create a sequence diagram, as follows:

fetch() …

read()

postgresql

:DBServer

send()

postgresql

:DBServer

:Mail Server

:Mail Server

Solution

Security is provided through a call to the database, to check the provided username and

password against the database. If a match is found, a session variable is created to hold

these values. If no match is found, the intruder is locked out of the system, and shown

only the initial login page. Each page of the system must check the session variable for

proper credentials, to avoid any back-door entry into the system.

The system must be accessed via SSL to ensure that passwords are protected, and sent

over the internet as plain text.

Motivation

Corporate email is sensitive information. If (mail)

n

were easily cracked, it would never be

considered as a viable email option.

Unresolved Issues

Purchase and installation of an SSL Certificate

Technical Memo

Issue: Usability

Solution Summary: Ease of use and a comfortable web-based interface are provided.

Factors

  • Users must be comfortable working with the system.

Solution

Since (mail)

n

is web-based, it uses an interface that most people already know how to use.

The interface is friendly, and uses a color palette that is easy on the eyes.

Motivation

Email must be available to corporate users from anywhere in the world. By making

(mail)

n

a web-based application, users can easily access new messages, but also have

access to all archived messages.

Technical Memo

Issue: Reliability–Recovery from Failure

Solution Summary: Email is held offsite in case of network failure, and backed up

regularly.

Factors

  • (mail)n must always be accessible.
  • If system fails, recovery must be timely.

Solution

(mail)

n

should be employed on a network that is always connected to the internet, and on

trusted hardware. In case the internet network experiences outages, email will be held on

the mail server until it can be downloaded into the database. The mail database is backed

up regularly, in case the hardware itself should fail.

Motivation

Messages arrive moment by moment, and need to be stored on a system that requires

little human intervention.

Unresolved Issues

What is the best way to back up the database?

Technical Memo

Issue: Implementation Constraints

Solution Summary: (mail)

n

uses open-source and free components.

Factors

  • A relational database is needed.
  • JavaMail must be used to retrieve and send mail.

Solution

The database of choice is PostgreSQL. It is an open-source, object-relational database

that is robust and SQL standards compliant. In order to communicate with the mail

server, we will be using JavaMail, as it is free to use, and already has all the methods we

need to retrieve email, and also to send it using SMTP Authorization.

Motivation

If open-source components were not used, we could not offer the system free of charge.

Logical View

The major subsystems of (mail)

n

include the files hosted by the web server, the classes

that communicate with the mail server, and the database server. The web server, running

Apache Jakarta Tomcat, serves JSP pages. Most of the JSP pages make a call to the

database to retrieve data, based on the login id of the user. JSP is most important to the

user interface, to quickly display the contents of the database. In order to make this work,

it is necessary to have the proper JDBC class written expressly for PostgreSQL. Luckily,

this file is supplied with the PostgreSQL database. The only caveat is to make sure this

file is placed in the correct classpath.