Java and Distributed Computing

shopfitterpsithurismSoftware and s/w Development

Nov 10, 2012 (5 years and 5 days ago)

333 views


UMass Lowell Computer Science 91.460


Java and Distributed Computing


Prof. Karen Daniels


Fall, 2000


Lecture 1

Introduction/Overview

Wed. 9/6/00

Web Page


http://www.cs.uml.edu/~kdaniels/courses/java2000.html


Web Page

Nature of the Course



Leading
-
edge technology


Advanced undergraduate level


CS elective


Highly interactive lectures


Lots of Java programming



Prerequisites


Computing I (91.101)


Computing II (91.102)


Strong C++ skills


preferably from Computing III (91.201)


Helpful experience:


Operating Systems


Distributed Computing

PROGRAMMING

Course Structure: 3 Parts


Java fundamentals


applets, applications, data types, control
structures, OO programming, files


Advanced Java concepts & Java support for
distributed computing


GUI/events, graphics, exceptions, advanced
data structures, threads/ multithreading, RMI


Distributed computing using a sample Java
-
based environment


Jini


Textbooks

Required:


Java: How to Program, Third Edition

by Deitel and Deitel,
Prentice
-
Hall, 1999.


Core Jini

by W. Keith Edwards, Prentice
-
Hall PTR, 1999.

Optional:


Java 2: The Complete Reference, Third Edition,
by
Naughton and Schildt, McGraw
-
Hill, 1999.

Available in UML bookstore

Syllabus

Lecture Date
Topic
Reading
Wed 9/6,
Fri 9/8
Introduction/Overview
Deitel: Chapter 1
Mon 9/11
Jini Overview
Edwards: Chapters 1, 2
Java Fundamentals
Deitel
Wed 9/13
Java Overview/C++ Comparison
Chapters 2, 3
Fri 9/15
Java Applets & Applications
Chapters 2, 3
Mon 9/18,
Wed 9/20
Data types, Operators, Expressions
From chapter:
-

4: 4.11, 4.12, 4.13
-

5: 5.9
Chapters 7, 10
Fri 9/22
Control Structures
Rest of chapters 4, 5
Mon 9/25
Exception Handling
Chapter 14
Wed 9/27
Methods, Object-Based Programming
Chapters 6, 8
Fri 9/29,
Mon 10/2
Object-Oriented Programming
Chapter 9
Wed 10/4
Files & Streams
Chapter 17
Fri 10/6
Exam 1
Syllabus
(continued)

Lecture Date
Topic
Reading
Advanced Java Concepts &
Java Support for Distributed Computing
Deitel
Wed 10/11
2D Graphics
Chapter 11
Fri 10/13,
Mon 10/16,
Wed 10/18
GUI/Event Handling
Chapters 12, 13
Fri 10/20,
Mon 10/23
Advanced Data Structures
Chapters 22, 23, 24
Wed 10/25,
Fri 10/27,
Mon10/30
Threads & Multithreading
Mutual Exclusion
Chapter 15
Wed 11/1
Web Support & Servlets
Chapter 19
Fri 11/3,
Mon 11/6
Remote Method Invocation
Chapter 20
Wed11/8
Review for Exam 2
Fri 11/10
Exam 2
Syllabus
(continued)

Lecture Date
Topic
Reading
Distributed Computing using Jini
Edwards
Mon 11/13
Distributed Computing & Jini Model
Chapter 3
Wed 11/15
Getting Started: Basic Hello World
Chapter 5
Fri 11/17
Getting Started: Hello World + Events
Chapter 5
Mon 11/20
Getting Started: Hello World + Leasing
Chapter 5
Wed 11/22
Jini Specialty Lecture
-----------
Mon 11/27
Getting Started: Hello World + Backend
Chapter 5
Wed 11/29
Discovery
Chapters 6, 7
Fri 12/1
Lookup & Join Manager
Chapter 8
Mon 12/4
Leasing
Chapter 10
Wed 12/6
Remote Events
Chapter 14
Fri 12/8
Well-Behaved Service
Chapter 12
Mon 12/11
Review for Exam 3
Wed 12/13
Review for Exam 3
TBD
Exam 3
Important Dates


Exam 1:




Friday, 10/6



Exam 2:




Friday, 11/10


Exam 3:




TBA


Grading


Homework


40%


Exam 1



15% (closed book)


Exam 2



20% (open book, notes )


Exam 3



25% (open book, notes)

Computing Environment


Java 2 platform: Java 2 SDK v. 1.2.2


http://www.javasoft.com/products/jdk/1.2


Jini v. 1.1


http://www.javasoft.com/products/jini


UML CS UNIX environment


Optional:


PC environment (code must also run on UNIX)


Experiment with jdk1.3 if you like


Java integrated development environment


2 are on disk with Deitel textbook (NetBeans caveat)

What is Java?


Language developed by Sun Microsystems


Popular use: World Wide Web


Platform
-
independent


Interpreter: Java Virtual Machine


Mobile code (Applets): transient, seamless


Fully Object
-
Oriented


Many C++ constructs


Class library support

A Typical Java Environment

Phase 1

Editor

Disk

Program is created in editor
and stored on disk.

Phase 2

Compiler

Disk

Compiler creates bytecodes
and stores them on disk.

Phase 3

Disk

Class Loader

.
.
.

Primary

Memory

Class loader puts
bytecodes in memory.

Phase 4

Bytecode Verifier

.
.
.

Primary

Memory

Bytecode verifier confirms all
bytecodes are valid & abide
by security constraints.

Phase 5

Interpreter

.
.
.

Primary

Memory

Interpreter (JVM) executes
bytecodes by reading &
translating into machine
language.

[Deitel 99]

What is Distributed Computing?


Distributed system:
collection of computing
devices that communicate with each other


Challenges:


heterogeneous hardware, software


asynchrony


limited local knowledge


failures


[Attiya, Welch 99]

Eight Fallacies of Distributed Computing


The network is reliable


Latency is zero


Bandwidth is infinite


The network is secure

“Essentially everyone, when they first build a distributed
application, makes the following eight assumptions. All prove
to be false in the long run, and all can cause big trouble and
painful learning experiences.”
-

Peter Deutsch



Topology doesn’t change


There is one administrator


Transport cost is zero


The network is homogeneous

Why Java & Distributed Computing?


Platform independence helps with
heterogeneous hardware, software challenge


Built
-
in support for:


Multithreading: concurrent multiple activities


Client
-
Server computing: servlets, JDBC


Remote Method Invocation (RMI): method calls
across network


Networking: socket
-
based communication views
networking like file I/O

Our Distributed Computing Goal:

Managing A Complex Enterprise

Telecommunications

Enterprise Characteristics


Many participants


hardware, software


varied communication


Highly distributed


Frequent changes


mobile clients


service availability

What is Jini?


Java
-
based connection framework
developed by Sun Microsystems


Philosophy:


plug ‘n play network


blur distinction between hardware and software


“self
-
healing”


Elements: discovery, lookup, leasing,
remote events, transactions, JavaSpaces

Background on Jini Technology


proxy manages service interaction

Client

Lookup Service




Service Item







Proxy

Attribute

Attribute

Attribute

Attribute

Service Provider




Service Item







Proxy

Attribute

Attribute

Attribute

Attribute




Service Item







Proxy

Attribute

Attribute

Attribute

Attribute

Homework

1


Wed, 9/6

Fri, 9/8

Read Ch 1 (Deitel)



HW#


Assigned


Due

Content

First written & programming assignment

will be handed out this Friday.