Application Server - E-Commerce - Lecture Slides, Slides of Fundamentals of E-Commerce

Students of Communication, study E-Commerce as an auxiliary subject. these are the key points discussed in these Lecture Slides of E-Commerce : Application Server, Transaction Processing, Message, Server Coordinates, Message Sources, Application Programs, Control Flow, Display Input, Format Request, Display

Typology: Slides

2012/2013

Uploaded on 07/29/2013

alok-sarath
alok-sarath 🇮🇳

4.3

(35)

143 documents

1 / 16

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
6. Application Server
Issues for the Project
Transaction Processing
for E-Commerce
Docsity.com
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff

Partial preview of the text

Download Application Server - E-Commerce - Lecture Slides and more Slides Fundamentals of E-Commerce in PDF only on Docsity!

6. Application ServerIssues for the Project^ Transaction Processingfor E-Commerce

Requests

-^ A request is a message that describes a unit of work for the^ system to execute. •^ An application server coordinates the flow of requests^ between message sources (displays, applications, etc.) andapplication programs that run requests as transactions. •^ Basic control flow:^ –^ Translate the display input (form/menu selection, etc.)into a standard-format request^ –^ Send the request to the appropriate server based on thetransaction type in the request header^ –^ Start the transaction^ –^ Invoke the transaction type’s application program^ –^ Commit and send the transaction’s output to the display

Application Server Components • Web Browser – A smart device, with forms, menus, input validation • Web server – Performs front-end work, e.g., security, data caching, …. – “Calls” the web page associated with the URL, which in turncalls a workflow controller • Workflow controller – Calls Start, Commit, and Abort – App logic that transforms the request (automatic loanpayment, money transfer) into calls on basic objects (loan,account). Sometimes called

business rules.

-^ Transaction server^ –^ Business objects (customer, account, loan, teller) •^ Resource Manager – usually a database (DB) system

Project’s Process Architecture 1^ Web BrowserWeb Server^ Workflow controller^ Transaction ServerResource Manager

Client Workflow ControllerResource Manager

Transaction Server • The features that differentiate a Transaction Server arethe inverse of the Workflow Controller, namely that it – Does not issue Start, Commit, and Abort (so it can be calledeither as an independent transaction or as a step in largertransaction) – Does not talk directly to the client (e.g., Web Server) – Can access the DB system • In addition, it can call other transaction servers. • Often, some transaction server code runs as storedprocedures inside the DB system. – So combining the transaction server and resource manager inthe project isn’t really an oversimplification.

Transaction Manager (TM) • The TM is the server that supports Start, Commitand Abort. • It implements two-phase commit (2PC). • This is a major feature of many application servers. – 10 years ago, it was^ the^ major feature (TM + T-RPC). – Supports 2PC across different RMs. – So it’s useful to have a TM in the application server eventhough DB products implement 2PC themselves

Remote Procedure Call (RPC) • Within a system or intranet, RPC is the most popular formof inter-process communication • A program calls a remote procedure (in another process)the same way it would call a local procedure – This simplifies the message protocol. It’s always a call messagefollowed by a return message. – It hides certain communications errors. – It automates the work of marshaling parameters into and out ofthe call and return messages. • There are many implementations of the concept – RMI, DCOM, CORBA/IIOP, HTTP, SOAP, ODBC, …. • In the project, all inter-process communications is via RPC.

Transactional RPC • Transactional RPC^ is an RPC protocol that implementsthe necessary plumbing to cope with a caller and/orcallee that are running a transaction. • Ideally, Start returns a transaction ID that’s hidden fromthe caller in a transaction context – Transactional RPC passes that transaction context as a hiddenparameter. It’s an easier programming model and avoids errors. – When a transaction first arrives at a callee C, C needs to

enlist with the local transaction manager (TM), so the TM knows tocall C during two-phase commit. – Also, C needs to execute the call in the context of thetransaction that called it.

Project’s Process Architecture(revisited)

Web Browser^ ClientWeb ServerWorkflow Controller Workflow controller Transaction ServerResource ManagerResource Manager

Start, Commit,AbortTransaction^ enlistManager2PC

Partitioning Servers • To add system capacity, add server machines. • Sometimes, you can just relocate some server processesto different machines. • But if an individual server process overloads onemachine, then you need to partition the process. – Example – flights, cars, and hotel rooms are managed by oneserver process. Later, you partition them in separate processes. – This implies the WFC has to direct its RPC calls based onresource type – To facilitate such changes, the mapping of resource name toserver name can be made table-driven. • This scenario is developed in step (7) of the project,where multiple RMs are required.

Summary of Concepts • Workflow controller vs. Transaction Server • Remote Procedure Call (RPC) • Transactional RPC • Transaction Manager • Partitioning Servers • Parameter-Based Routing • There’s a lot more to say about Application Servers.We’ll return to the topic in a later lecture.