Komponentbasert utvikling Den sanne objektorientering Trygve Reenskaug Numerica Taskon

advertisement
Komponentbasert utvikling
Den sanne objektorientering
Trygve Reenskaug
Numerica Taskon
UML
Unified Modeling Language
og
komponentbasert utvikling
Geilo 19 april 1999
Komponentbasert utvikling
© Trygve Reenskaug 1999
5/29/2016 3:32:05 AM.
Personal Information Environments
Content and Communication
Digital
Map
Census
Data
Police
Records
House
Drawings
Police
Dispatcher
Komponentbasert utvikling
© Trygve Reenskaug 1999
Aerial
Photos
5/29/2016 3:32:06 AM.
Presentation Plan
• The Communication-Centered Paradigm
• Building Systems with Components
• But the Real Challenge is …
Summary and conclusion
Komponentbasert utvikling
© Trygve Reenskaug 1999
5/29/2016 3:32:07 AM.
CPU-Centered
paradigm
Output
Input
Central
Processing
Unit
FORTRAN
Algol 60
Tape
Software
Hardware
Komponentbasert utvikling
© Trygve Reenskaug 1999
5/29/2016 3:32:07 AM.
Storage-Centered
paradigm
Input
App.1
Output
Shared
database
Central
Processing
Unit
Memory
App.3
Tape
Disk
App.4
DB Schema language
e.g. Entity-Relation
e.g. NIAM
Software
Hardware
Komponentbasert utvikling
App.2
© Trygve Reenskaug 1999
5/29/2016 3:32:08 AM.
Communication-Centered
Output
Tape
Central
Processing
Unit
Object 1
Disk
Object 3
Information Bus
Input
Communication Bus
paradigm
Object 2
Object 4
Memory
Composition language
e.g. Object Constraint Language
Hardware
Komponentbasert utvikling
Software
© Trygve Reenskaug 1999
5/29/2016 3:32:08 AM.
No Main Program!
The SYSTEM
Centralized solutions
The designer
• sees everything
• knows everything
• understands everything
• controls everything
Distributed solutions
The object
- has responsibility
- knows its collaborators
- is robust
Nobody knows everything!
Komponentbasert utvikling
© Trygve Reenskaug 1999
5/29/2016 3:32:08 AM.
Advantages
Communication-Centered paradigm
• Unlimited Scaling
• Distributed Ownership
• Support people’s Tasks
• Flexible Consistency Requirements
Komponentbasert utvikling
© Trygve Reenskaug 1999
5/29/2016 3:32:08 AM.
Presentation Plan
• The Communication-Centered Paradigm
• Building Systems with Components
• But the Real Challenge is …
Summary and conclusion
Komponentbasert utvikling
© Trygve Reenskaug 1999
5/29/2016 3:32:09 AM.
App. for booking meeting rooms
Komponentbasert utvikling
© Trygve Reenskaug 1999
5/29/2016 3:32:09 AM.
We use objects
to master the age of distribution
Object-B
IN
IN
OUT-B
OUT-C
OUT-C
Methods Variables
Object-C
Methods Variables
IN
Object-A
Methods Variables
Message
triggers method
causes response
Komponentbasert utvikling
© Trygve Reenskaug 1999
5/29/2016 3:32:09 AM.
What is a Component?
• A Component is a reusable object
• A Component is an object playing
standardized roles in a specified
container
• A component is reused by cloning
• Tools are used to compose systems
Komponentbasert utvikling
© Trygve Reenskaug 1999
5/29/2016 3:32:09 AM.
Component Value Chain
Application Assembler
(User expert)
Component Deployer
(Operational environment expert)
Component Provider
(Domain expert)
Component Container Provider
(System programmer)
Komponentbasert utvikling
© Trygve Reenskaug 1999
5/29/2016 3:32:09 AM.
The competing technologies
CORBA™ Object Management Group (OMG)
Public standards
Java™
SUN Microsystems
Build once, run anywhere
COM™
Microsoft
Dominating on desktops
Komponentbasert utvikling
© Trygve Reenskaug 1999
5/29/2016 3:32:10 AM.
Java Bean
• User Interface
• Properties
• Events
• Composition
• Run time context
Information Bus
Component standardization
examples
Enterprise Java Bean
• Naming
• Persistence
• Transactions
• Security
• Load sharing
• Run time context
Client
Komponentbasert utvikling
Server
© Trygve Reenskaug 1999
5/29/2016 3:32:10 AM.
Compose User Interface
with Java Beans
Komponentbasert utvikling
© Trygve Reenskaug 1999
5/29/2016 3:32:10 AM.
The Enterprise Java Bean objects
and their message paths
WEB
Browser
Information Bus
Booking
Client
Name
Server
Booking
Home
Room
Chooser
Booking
Bean
Booking
Object
4: getRooms();
Multithreading
Reuse EJBs
Reuse DB conn.
Persistence
Could be Entity Bean
java.sql.
Connection
5: getRooms();
Session Bean
Transactions
Security
Java Bean
Komponentbasert utvikling
© Trygve Reenskaug 1999
5/29/2016 3:32:10 AM.
EJB Implementation
We wrote:
• BookingHome.java
Intf. Client create its own server object
• Booking.java
Intf: Client access booking service
• BookingBean.java
Class: The booking business logic program itself
• BookingClient.java
Class: The main user interface class
The IONA EJBHome tool created these files for us:
• RoomBroker.ejbml
• datasource.properties
• ejbhome.properties
• Iona*.java/class
Komponentbasert utvikling
Property file describing the booking EJB
File: Maps datasource names
to JDBC databases URLs.
File: EJB Server configuration
Class: A number of supporting java classes
© Trygve Reenskaug 1999
5/29/2016 3:32:15 AM.
Presentation Plan
• The Communication-Centered Paradigm
• Building Systems with Components
• But the Real Challenge is …
Summary and conclusion
Komponentbasert utvikling
© Trygve Reenskaug 1999
5/29/2016 3:32:15 AM.
Distributed Systems
What you get:
• Unlimited scaling
• Distributed ownership
• Specific task support
• Information partitioning
How you do it:
• Think in terms of objects, their
responsibilities and collaboration.
• Think in terms of open systems, no
main program.
Komponentbasert utvikling
© Trygve Reenskaug 1999
5/29/2016 3:32:15 AM.
Component-based development
What you get:
• Build by composing library objects,
avoid coding.
• Leverage infrastructure mechanisms
(transactions, security, persistence,…)
How you do it:
• Think in terms of objects.
(Responsibilities, environment, collaboration.)
• Penetrate vendor fog - find essentials
• Insist on high product quality
• Adapt to new layers in value chain
Komponentbasert utvikling
© Trygve Reenskaug 1999
5/29/2016 3:32:15 AM.
The main problems
We spend too much time and effort
on low-level mechanics.
Current offerings are NOT:
• Easy and intuitive to use
• Smooth development platforms
• Reliable
• Secure
• Extensible
Komponentbasert utvikling
© Trygve Reenskaug 1999
5/29/2016 3:32:16 AM.
The Real Challenges
The
Connected
Organization
Business
processes
Komponentbasert utvikling
Effective,
Enjoyable
and
Instructive
Tools
Task / Use Case / Tool
© Trygve Reenskaug 1999
Effective
Partitioning
of
Information
Services
Information services
5/29/2016 3:32:16 AM.
Distributed systems
Do it!
http://www.ifi.uio.no/~trygve
Komponentbasert utvikling
© Trygve Reenskaug 1999
5/29/2016 3:32:17 AM.
Download