Upload
others
View
4
Download
0
Embed Size (px)
Citation preview
1
1
Application ServersG22.3033-011
Session 4 - Sub-Topic 1Distributed Communications Enabling
Dr. Jean-Claude Franchitti
New York UniversityComputer Science Department
Courant Institute of Mathematical Sciences
2
Enterprise Web Applications(review)
3
Basic Web Applications
DBDB
Databases
Documents
EnterpriseData
WebServerCGI, SSJS, NSAPI,ISAPI, WAI, Etc.
ClientBrowser
Internet Connection
2
4
Robust Web ApplicationsPresentation
Tier
Rich Clients(Java C/C++, VB)
WebBrowser
Business Logic Tier
WebServers
ApplicationApplicationServer(s)Server(s)
Data Tier
Databases
Enterprise C/SApplications
LegacySystems
DocumentsHTTP
IIOP
Application Servers Internals
Scalable, Reliable
ApplicationArchitecture
HTML
C/C++
Java
VisualBasic
Client
Network ServicesOperating System
Distributed Object Infrastructure
Pre-BuiltSystem &
ApplicationServices
Versioning
State /Session Mgt Directory Security Messaging
JDBC
Data AccessConnection
Pooling Transactions ResultsCaching
LoadBalancing Persistence Thread
ManagerFail SafeServices
Application Server
ApplicationLogic
(Java, C/C++)
6
Open and Extensible
Application Servers Technical Architectures
Browsers
Rich Clients
Data Sources• RDBMS
• Oracle• Informix• Sybase• DB2• SQL Server
• OODBMS• ODI
• ODBC & JDBC
Open Client Library
Java, C/C++,VB
Platforms• Sun Solaris• HP-UX• SGI Irix• Windows
Extensions• TP Monitors• Legacy• Client/server
OC
L
Dat
a A
cces
s En
gine
Exte
nsio
ns
Prot
ocol
Man
ager
(HTT
P, K
CP,
IIO
P)
Web
Con
nect
ors
ISAP
I, N
SAPI
, CG
I
WebServers
ApplicationServer
(Java, C/C++)
Embedded (bundled) ORB
3
7
• HTML/CGI• HTML-Extended• CORBA-based (OMA)• RMI-based (J2EE)• DCOM-based (COM+)• XML-based• Adaptive• http://www.appserver-zone.com/guide.asp
Application Server Categories
8
Application Servers Selection Criteria
UsabilityScalabilitySecurityManageabilityReusabilitySupportSkillsThe underlying DOC platform is a key driver inthe selection process
9
Distributed Object Computingand
Application Servers
4
10
Enterprise Computing Layers/Facilities
Distributed Object ComputingApplication ServersClient Interfaces (MOM & POP Applications)Web Application Modeling (MOF/UML/XML)Adaptiveness & Model-Driven ApplicationGeneration
11
Distributed Object Computing Models
OMA (CCM)J2EE (EJB)COM+ (MTS)
12
CORBA
5
13
Common Object Request Broker Architecture
Open distributed computing infrastructure/platform (OMA)Programming language independent DOC environmentBased on OMG IDL, and IIOP/GIOPStandardized by the OMGAutomates common networking programming tasks
Object registration, location, activationRequest demultiplexingFraming and error handlingParameter marshalling and demarshallingOperation dispatching
14
New in Corba 3
Component Model (CCM)Quality-of-service controlMessaging invocation modelTightened integration with the InternetPOA (Portable Object Adapter)EJB and Java supportOMG specifications for analysis and design, andapplication interoperability
UML, MOF, XMI, Common Warehouse Model
15
Overview of Corba:OMG Reference Model Architecture
6
16
Object Services (CORBAservices)
Domain-independent interfaces used by manydistributed object programsNaming Service: allows clients to find objects basedon namesTrading Service: allows clients to find objects basedon their propertiesOther services: persistence, lifecycle management,security, transactions, event notification, etc.
17
Common Facilities (Horizontal CORBAfacilities)
Horizontally-oriented interfacesOriented towards end-user applicationsE.g.: Distributed Document Component Facility (DDCF)
Compound document facility based on OpenDocAllows for presentation and interchange of objectsbased on a document model (e.g., linking ofspreadsheet object into a report document)
Printing, Secure Time, Internationalization, and MobileAgent Facilities
18
Domain Interfaces (Domain CORBAfacilities)
Role similar to Object Services and CommonFacilitiesOriented towards specific application domainsE.g., Product Data Management (PDM) Enablers forthe manufacturing domainOther possibilities in the telecommunications,medical, and financial domains
7
19
Application Interfaces
Interfaces developed for a given applicationNot standardizedMight become candidates for future OMGstandardization
20
CORBA ORB Architecture
21
Object Implementation
Defines operations that implement a CORBA IDLinterfaceObject implementations can be written in a variety oflanguages
C, C++, Java, Smalltalk, Ada, etc.
8
22
Client
Program that invokes an operation on an objectimplementationAccessing the services of a remote object istransparent to the caller
As simple as calling a method on an objectE.g., obj->op(args)
23
Object Request Broker (ORB)
Provides mechanism for transparentlycommunicating client requests to target objectimplementationsSimplifies distributed programming by decouplingthe client from the details of the method invocationsClient requests appear to be local procedure callsORB is responsible for finding the objectimplementation, activating it, delivering the requestto the object, and returning a response to the caller
24
ORB Interface
Abstract interface for an ORBORB may be implemented in various ways
One or more processes, set of libraries, etc.Interface provides various helper functions
Converting object references to stringsCreating argument lists for requests made throughthe dynamic invocation interface
9
25
CORBA IDL Stubs and Skeletons
Serve as the “glue” between the client and serverapplications, and the ORBCORBA compiler automates the transformationbetween CORBA IDL definitions and the targetprogramming languageUse of compiler reduces the potential forinconsistencies between client stubs and serverskeletonsUse of compiler facilitates automated optimizations
26
Dynamic Invocation Interface (DII)
Allows a client to directly access the underlyingrequest mechanisms provided by an ORBApplications use the DII to dynamically issuerequests to objects without requiring IDL interface-specific stubs to be linked inDII allows clients to make non-blocking deferredsynchronous (separate send and receive operations)and oneway (send-only) calls
27
Dynamic Skeleton Interface (DSI)
Server side analogue to the client side DIIAllows an ORB to deliver requests to an objectimplementation that does not have compile-timeknowledge of the type of the object it isimplementingClient making the request has no idea whether theimplementation is using type-specific IDL skeletonsor dynamic skeletons
10
28
Object Adapter
Assists the ORB with delivering requests to theobjectAssists the ORB with activating the objectAssociates object implementation with the ORBCan be specialized to provide support for certainobject implementation styles (e.g., OODB objectadapters for persistence)
29
ORB Products
BEA WLE (formerly BEA M3)Expertsoft CORBAplusIBM WebSphere Product Family (Component Broker)Inprise VisiBroker Middleware ProductsIONA OrbixMerant CORBA Technology for COBOLPeerLogic DAISObjectSpace Voyager
30
Questions?
11
31
EJBand
Java 2 Platform Enterprise Edition
32
Java 2 Platform, Enterprise Edition
Released on 9/27/99Complete development platform architected to meetthe needs of enterprise application developmentMakes all Java APIs and functionality available andaccessible in a well integrated fashionSimplifies the development, deployment, andmanagement of multi-tier server-centric solutionsBuilt on Enterprise JavaBeans componentarchitecture
33
Java Technology Findings
Open standards are better than closedWrite Once, Run Anywhere beats proprietaryvendor-lock technologyFindings motivate the creation of a single, unifiedplatform with an easy-to-use model for buildingdistributed ebusiness applications across a widearray of products
12
34
J2EE Platform and Enterprise Computing Solutions
35
J2EE Key Value Propositions
Simplified enterprise developmentSupports various pieces of server software
Industrial strength scalabilityLegacy connectivityOpen platform (choice/flexibility)SecurityPortability
36
J2EE Platform:The Whole is Greater than the Sum of its Parts
13
37
J2EE: A Complete Computing Environment
Platform SpecificationLists required elements of the platformLists policies to follow for a valid implementation
Reference ImplementationSemantically correct prototype to test against
Compatibility Test SuiteAPI-level compatibility, component-level tests,end-to-end compatibility
Application Programming Model: java.sun.com/j2ee
38
The Three Cs:Components, Containers, Connectors
39
J2EE: Components
Enterprise JavaBeansServer-side solutions can be built without regardsfor the database, transaction server, or applicationthey run on
ServletsRun on vast majority of web servers
JavaServer PagesDynamic content leverages off the full power ofJava
14
40
J2EE: Containers
Containers provide high-performance, scalableenvironments for J2EE-enabled serversJ2EE-enabled servers support EJB-basedcomponents, servlets, and JSP-based pages
41
J2EE: Connectors
Connectors allow J2EE-based solution to preserve,protect, and leverage off of existing enterpriseinvestments
42
J2EE: Unifying the Three Cs
Single platformStandard platform-independent technologyApplications built with components can be run onany J2EE server, and are able to talk to enterprise-class systems that exist today
15
43
J2EE TechnologiesJavaIDLRMI/IIOPJDBCJDBC 2.0 Client partsJNDIServletsJavaServer PagesJavaMail, JavaBeans Activation FrameworkJTS, EJB, JTA, JMS, Connector/Resource Mgmt. Comp.XML (platform independent data)
44
Questions?
45
Goals
Show by example that COM+ makes it:• As easy to develop Server Components as it
is to develop Client Components• As easy to deliver enterprise apps as it is to
deliver workgroup apps!
16
46
COM+COM+COM+ Services:COM+ Services:EventsEventsSecuritySecurityLoad Load Balancing Balancing Queued Queued Components ComponentsIn Memory In Memory Database DatabaseCompensatingCompensating Resource Resource Manager ManagerAdministrationAdministration
MTSMTS
MTS Services:MTS Services: Transactions Transactions Resource Pooling Resource Pooling Security Security Administration Administration
COMCOMTheThe Model ModelTools SupportTools SupportMulti-LanguageMulti-LanguageDiscovery (QI)Discovery (QI)
COM+The caring, sharing
environment for yourcomponents
COM+COM+The caring, sharingThe caring, sharing
environment forenvironment for youryourcomponentscomponents
Technology Scenario
47
Application Scenario
• Online service like MSN or AOL• User login causes two databases
to be updated– Customer Billing Log– Customer Login Status
• Total connect time is tracked• User is notified of various activities while they
are logged in(i.e. chat rooms)
48
Web Web clientsclients Web Web infrastructureinfrastructureLogonLogon
BusinessBusiness applicationsapplications
LogoffLogoff
SecuritySecuritybillingbilling
Real-timeReal-timeProfile-directedProfile-directed
informationinformation
ContentContent
BillingBilling
ExistingExistingBilling Billing SystemSystem
ExistingExistingBilling Billing SystemSystemExistingExistingBilling Billing SystemSystemCustomerCustomer
onlineonlinesystemsystem
ExistingExistingBilling Billing SystemSystemExistingExistingBilling Billing SystemSystemExistingExistingbilling billing systemsystem
ExistingExistingBilling Billing SystemSystemExistingExistingBilling Billing SystemSystemExistingExistingBilling Billing SystemSystemExistingExistingbilling billing systemsystem ExistingExisting
Billing Billing SystemSystemExistingExistingBilling Billing SystemSystem
OtherOthersystemssystems
Application Flow
17
49
Application Object Model
OnlineEventsOnlineEventsLoginEventClassLoginEventClass dbOnlineEventdbOnlineEvent
UpdateUpdate
IMDBIMDBdbCustomerdbCustomerPreferencesPreferences
BusCustomerBusCustomerLoginLogin
dbCustomerdbCustomerupdateupdate
BillingBillingDatabaseDatabase
dbCustOnlinedbCustOnline CustomerCustomerDatabaseDatabase
50Many others… Many others…
Application Requirements
• Ultimate customerresponse andavailability
• Always accept Logon• No freebies! Always bill
for entiretime online
• Use existingbilling system
• Use existingdev resources
• Keep billing, CustomerOnline and othersystems consistent
• Real-time two way infoon who is on
• Real-time info on whatis going on
• Flexible administration• Maximize use of
platform, minimizedevelopment time
51
Tackling TheApplication Requirements
• Ultimate customerresponse and availability
• Always accept legitimatelogin
• No freebies! Always billfor entiretime online
• Use existingbilling system
• Use existingdev resources
• Others…
• Keep billing, CustomerOnline and other systemsconsistent
• Real-time two way info onwho is on
• Real-time info on what isgoing on
• Flexible Administration• Maximize use of platform,
minimize developmenttime
18
52
Requirement: Simplify Server SideDevelopment
• Issues:
AppliancesAppliances ApplicationsApplications
– Threading– Synchronization– Data Base Connection pooling– Communications - front and back ends
53
ApplicationApplicationclientclient
COM+ ServerCOM+ Server processprocess
ConcurrencyConcurrencySecuritySecurity
Services...Services...ApplicationApplication
ComponentsComponentsIFooIFoo
Requirement: Simplify Server SideDevelopment
• Solution: core COM+ Services– You write a “single user” component as though it were the
only user of DB resources– COM+ provides the rich service environment which makes
your component multi-user, multi-threaded and resourcepooled
54
Core Application Services• COM+ provides:
– Administrator controlled process placement– The context– Sharing automatically managed by COM+– Auto Completion (or explicit
SetComplete, SetAbort)
• All you have to do:– Stick with the model (or be aware of consequences of
leaving model)– (Basic component walkthrough)
19
55
Tackling TheApplication Requirements
• Ultimate customerresponse and availability
• Always accept legitimatelogin
• No freebies! Always billfor entiretime online
• Use existingbilling system
• Use existingdev resources
• Others…
• Keep billing, CustomerOnline and other systemsconsistent
• Real-time two way info onwho is on
• Real-time info on what isgoing on
• Flexible administration• Maximize use of platform,
minimize developmenttime
56
Flexible Administration
• Issues– Different Administration dimensions– Application Distribution– Connectivity
Now!Now!
57
Flexible Administration
• Solution: COM+ Administration– Features: extends administration to all COM
Components, supports administration of new servicesand provides a complete programmatic interface forinstallation, configuration and deployment automation
CatalogCatalog AttributesAttributes
20
58
Administrative Model• Applications are defined and components are
installed in the applications that they are to run in• Attributes are set declaratively
on the components• Transactions• Security roles• Activation properties
• SDK - complete automation capabilities
59
Administration Example
• Walkthrough of Billing system deployment• Billing components are updated
on the dev machine• The Application can be exported manually:
– Application information and the DLLs to be moved to theaccounting server and…
– ActiveX® Control is downloaded to the client using theCODEBASE tag and a CLSID
– Or…• Auto download of components on demand
• Requires Windows 2000 Directory Service
60
Tackling TheApplication Requirements
• Ultimate customerresponse and availability
• Always accept legitimatelogin
• No freebies! Always billfor entiretime online
• Use existingbilling system
• Use existingdev resources
• Other…
• Keep billing, CustomerOnline and other systemsconsistent
• Real-time two way info onwho is on
• Real-time info on what isgoing on
• Flexible administration• Maximize use of platform,
minimize developmenttime
21
61
Database Consistency• Issues:
– Updating multiple Resource Managers• (DB, IMDB, MSMQ)
– Avoiding conflicts– Multiple simultaneous users– Indeterminate numbers of users
Other DataOther DataSourcesSources
BillingBillingDatabaseDatabase
CustomerCustomerDatabase Database
BusCustomerBusCustomerLoginLogin
dbCustomerdbCustomerupdateupdate
dbCustomerdbCustomerOnlineOnline
62
IFooIFoo
ApplicationApplicationcomponentscomponents
COM+ ServerCOM+ Server ProcessProcess
ApplicationApplicationcomponentscomponentsApplicationApplication
ClientsClients
ApplicationApplicationclientsclients
TransactionTransactionservicesservices
Database Consistency
• Solution: COM+ Transaction Services– Features:
• System provided transactions on activation, commit on deactivation,abort on errors
• System enforced serialization• Manual (SetComplete, SetAbort)
or Auto completion
63
Consistency Example
• COM+ Transaction Services– Transaction code and attribute walkthrough– Bus_Customer calls db
_CustomerBilling and db_CustOnlineStatus– Distributed transaction occurs (transparently) when user logs
on– Without Transactions customer could be billed for time even
if they failed to complete the logon or…– They might not get billed even though they successfully
logged on– Auto Completion (not in the Preview)– Transaction code and attribute walkthrough
22
64
Tackling TheApplication Requirements
• Ultimate customerresponse and availability
• Always accept legitimatelogon
• No freebies! Always billfor entiretime online
• Use existingbilling system
• Use existingdev resources
• Other…
• Keep billing, CustomerOnline and other systemsconsistent
• Real-time two way info onwho is on
• Real-time info on what isgoing on
• Flexible administration• Maximize use of platform,
minimize developmenttime
65
Application Security• Issues:
– Security Dimensions– Distributed application– Components being Compounded
CustomerCustomerloginlogin
dbCustomerdbCustomerUpdateUpdate
dbCustomerdbCustomerOnlineOnline
66
COM+ ServerCOM+ Server processprocess
ApplicationApplicationclientclient
SecuritySecurityserviceservice IFooIFoo
ApplicationApplicationServerServer
Application Security• Solution: COM+ Security Services:
– Role-based access control on classes, interfaces andMETHODS,
– mapping roles to Windows 2000domain accounts
23
67
Security Example• Application context
– Customer billing information needsto be protected
– When a user logs on the bus_Customer componentrunning on the Web server will call the accounting server
– Using roles the Web server will be allowed to call theaccounting server but you may not call the componentdirectly
– Roles established in package definition– Roles established in the IDE– Code and Attribute walkthrough
68
Tackling The Application Requirements -The Story So Far
• Ultimate customerresponse and availability
• Always accept legitimatelogon
• No freebies! Always billfor entiretime online
• Use existingbilling system
• Use existingdev resources
• Other…
• Keep billing, CustomerOnline and other systemsconsistent
• Real-time two way info onwho is on
• Real-time info on what isgoing on
• Flexible administration• Maximize use of platform,
minimize developmenttime
69
Tackling Other Application Requirements
• Ultimate customerresponse and availability
• Always accept legitimatelogon
• No freebies! Always billfor entiretime online
• Use existingbilling system
• Use existingdev resources
• Other…
• Keep billing, CustomerOnline and other systemsconsistent
• Real-time two way info onwho is on
• Real-time info on what isgoing on
• Flexible administration• Maximize use of platform,
minimize developmenttime
24
70
Even Easier!• Coming soon
– Direct manipulation of attributes from IDE– Direct manipulation of COM+ administration from
IDE• The COM+ Wizardo
71
Conclusion
COM+ makes it:• As easy to develop Server Components as it
is to develop Client Components• As easy to deliver enterprise apps as it is to
deliver workgroup apps!
72
Call To Action• Architecting, designing, developing:
– Assume COM+ level of service and use Windows2000 now
• Deploying and in production:– Use Microsoft Transaction Server now - your
components will be uplifted when COM+ is installed• Everything discussed is a standard feature of
Windows 2000
25
73
References on COM+
• Books– Chappell. Understanding ActiveX and OLE– Eddon. Inside DCOM– Grimes. Professional DCOM– Box. Essential COM
• COM Home Page– http://www.microsoft.com/com/
• Windows 2000 Platform SDK– NT 5.0 Beta 2 or later
74
Questions?