Software Paradigms (Lesson 10) Selected Topics in Software Architecture

Similar documents
Distributed Object-Based Systems The WWW Architecture Web Services Handout 11 Part(a) EECS 591 Farnam Jahanian University of Michigan.

Advanced Lectures on knowledge Engineering

What is CORBA? CORBA (Common Object Request Broker Architecture) is a distributed object-oriented client/server platform.

Agent and Object Technology Lab Dipartimento di Ingegneria dell Informazione Università degli Studi di Parma. Distributed and Agent Systems

Today: Distributed Objects. Distributed Objects

DS 2009: middleware. David Evans

Distributed Objects. Object-Oriented Application Development

CORBA (Common Object Request Broker Architecture)

System types. Distributed systems

Today: Distributed Middleware. Middleware

IIOP: Internet Inter-ORB Protocol Make your code accessible even in future, with the next universal protocol

Chapter 10 Web-based Information Systems

Distributed Middleware. Distributed Objects

Introduction to Web Services & SOA

Electronic Payment Systems (1) E-cash

Introduction to Web Services & SOA

Notes. Submit homework on Blackboard The first homework deadline is the end of Sunday, Feb 11 th. Final slides have 'Spring 2018' in chapter title

Distributed Objects and Remote Invocation. Programming Models for Distributed Applications

Distributed Systems Architectures. Ian Sommerville 2006 Software Engineering, 8th edition. Chapter 12 Slide 1

1.264 Lecture 16. Legacy Middleware

Distributed Environments. CORBA, JavaRMI and DCOM

UNIT 4 CORBA 4/2/2013 Middleware 59

Verteilte Systeme (Distributed Systems)

ANSAwise - CORBA Interoperability

CS555: Distributed Systems [Fall 2017] Dept. Of Computer Science, Colorado State University

Chapter 5: Distributed objects and remote invocation

Oracle Tuxedo. CORBA Technical Articles 11g Release 1 ( ) March 2010

Real-time & Embedded Systems Workshop July 2007 Building Successful Real-time Distributed Systems in Java

Distributed systems. Distributed Systems Architectures. System types. Objectives. Distributed system characteristics.

Distributed Systems Middleware

A short introduction to Web Services

Distributed Systems Principles and Paradigms

QuickSpecs. Compaq NonStop Transaction Server for Java Solution. Models. Introduction. Creating a state-of-the-art transactional Java environment

Distributed Technologies - overview & GIPSY Communication Procedure

INTRODUCTION TO Object Oriented Systems BHUSHAN JADHAV

Distributed Object-based Systems CORBA

Advanced Topics in Operating Systems

Appendix A - Glossary(of OO software term s)

AQUILA. Project Defense. Sandeep Misra. (IST ) Development of C++ Client for a Java QoS API based on CORBA

Module 1 - Distributed System Architectures & Models

Announcements. me your survey: See the Announcements page. Today. Reading. Take a break around 10:15am. Ack: Some figures are from Coulouris

COMMUNICATION PROTOCOLS: REMOTE PROCEDURE CALL (RPC)

KINGS COLLEGE OF ENGINEERING DEPARTMENT OF COMPUTER SCIENCE & ENGINEERING ACADEMIC YEAR (ODD SEMESTER) QUESTION BANK

Irbid National University, Irbid, Jordan. 1. The concept of distributed corporate systems

Distributed Systems. The main method of distributed object communication is with remote method invocation

Overview. Distributed Systems. Distributed Software Architecture Using Middleware. Components of a system are not always held on the same host

Mohsin Qasim Syed Abbas Ali

A Report on RMI and RPC Submitted by Sudharshan Reddy B

DISTRIBUTED SYSTEMS Principles and Paradigms Second Edition ANDREW S. TANENBAUM MAARTEN VAN STEEN. Chapter 1. Introduction

Software. Networked multimedia. Buffering of media streams. Causes of multimedia. Browser based architecture. Programming

Middleware. Adapted from Alonso, Casati, Kuno, Machiraju Web Services Springer 2004

Lecture 06: Distributed Object

MODELS OF DISTRIBUTED SYSTEMS

Application Servers G Session 5 - Main Theme Object Management Architectures. Dr. Jean-Claude Franchitti

Introduction to Distributed Systems. INF5040/9040 Autumn 2018 Lecturer: Eli Gjørven (ifi/uio)

Vendor: SUN. Exam Code: Exam Name: SUN Certified ENITRPRISE ARCHITECT FOR J2EE(tm)TECHNOLOGY. Version: Demo

Administrative Stuff. We are now in week 11 No class on Thursday About one month to go. Spend your time wisely Make any major decisions w/ Client

Configuring the Oracle Network Environment. Copyright 2009, Oracle. All rights reserved.

Agent-Enabling Transformation of E-Commerce Portals with Web Services

Chapter 10 Web-based Information Systems

CAS 703 Software Design

CLIENT SERVER ARCHITECTURE:

(9A05803) WEB SERVICES (ELECTIVE - III)

Enterprise Software Architecture & Design

Protocol Buffers, grpc

Cloud Computing Chapter 2

Chapter 16. Layering a computing infrastructure

INSTITUTE OF AERONAUTICAL ENGINEERING (Autonomous) Dundigal, Hyderabad

The Common Object Request Broker Architecture (CORBA)

MODELS OF DISTRIBUTED SYSTEMS

RIKA: Component Architectures

Active Server Pages Architecture

Interconnection of Distributed Components: An Overview of Current Middleware Solutions *

Broker Pattern. Teemu Koponen

CHAPTER 1: OPERATING SYSTEM FUNDAMENTALS

Implementation of GDMO to IDL Translator and CORBA/CMIP Gateway for TMN/CORBA Integration

Advanced Distributed Systems

Patterns Architectural Styles Archetypes

JAVA S ROLE IN DISTRIBUTED COMPUTING

RMI: Design & Implementation

殷亚凤. Processes. Distributed Systems [3]

XVIII. Software Architectures

Overview. Borland VisiBroker 7.0

Distributed Systems Exam 1 Review Paul Krzyzanowski. Rutgers University. Fall 2016

ANSAweb: A Web of Distributed Objects

Introduction to Distributed Systems (DS)

CIW 1D CIW Foundations Exam v5.

FIPA Agent Software Integration Specification

Chapter 1: Distributed Information Systems

Bionic Buffalo Tech Note #23: The France IDL Compiler: C Language Mapping

An Introduction to Software Architecture. David Garlan & Mary Shaw 94

As related works, OMG's CORBA (Common Object Request Broker Architecture)[2] has been developed for long years. CORBA was intended to realize interope

04 Webservices. Web APIs REST Coulouris. Roy Fielding, Aphrodite, chp.9. Chp 5/6

The Umbilical Cord And Alphabet Soup

Distribution and Integration Technologies

3. WWW and HTTP. Fig.3.1 Architecture of WWW

Distributed Systems Principles and Paradigms

CCNA Exploration Network Fundamentals. Chapter 03 Application Functionality and Protocols

Programming of Interactive Systems

Message Passing vs. Distributed Objects. 5/15/2009 Distributed Computing, M. L. Liu 1

Transcription:

Software Paradigms (Lesson 10) Selected Topics in Software Architecture Table of Contents 1 World-Wide-Web... 2 1.1 Basic Architectural Solution... 2 1.2 Designing WWW Applications... 7 2 CORBA... 11 2.1 Distributed Object Systems... 11 2.2 CORBA: Basics... 12 2.3 CORBA: Services... 16 3 Database System... 17 4 Real-Time Systems... 20 This lesson presents a number of standard architectural solutions.

1 World-Wide-Web The basic WWW properties are: Remote access to documents Interoperability between different platforms Extensibility of software Extensibility of data Scalability The basic architectural approach used in the WWW can be defined as: Client/server style; Hypertext transfer protocol (HTTP) that serves as a data transportation layer Special data format (HTML) that masks all hardware, operating system, and protocol dependencies. 1.1 Basic Architectural Solution Content producers and consumers interact through their respective servers and clients.

The producer places content on a server machine and the content is described in HTML. The server communicates with a client using the hypertext transfer protocol (HTTP). The software on both the server and the client is based on HTTP and HTML and so the details of the protocol and the dependencies on the platforms are masked from the software. Mapping basic WWW properties on architectural solutions: Remote access = Build on top of Internet Interoperability = Use HTML to mask platform details Extensibility of software = Server-Site and Client-Site programming (Virtual Machine Style) Extensibility of data = references to any types of data Scalability = client-server architecture style and local references to other data One of the main WWW components is a WWW client that display WWW documents (content) so that the content consumer is presented with an understandable image and with a possibility to access other related documents.

The user interface (UI) manager handles the look and feel of the cliental user interface. However, given that the set of resources that a WWW system can handle is open ended, the UI manager, can delegate information display to external programs (viewers) to view resources that are known by the system but not directly supported by the UI manager. For example, most Web viewers use an external program to view Postscript files, Vector Graphics an movies. This delegation is a reasonable compromise between the competing desires of user-interface integration (which provides for a consistent look and feel and hence better usability) and extensibility. The UI manager captures a user's request for information retrieval in the form of a URL and passes the information to the access manager. The access manager determines if the requested URL exists in cache and also interprets history-based navigation (e.g., "back","forward", etc.).

The stream scheduler is an important architectural component to synchronize "fast" local data processing operations performed by the UI manager and relatively "slow" data access and data transfer operations performed by Cache Manager and Protocol Manger. The stream scheduler can be seen as a queue of requests to perform input/output and data transfer operations. The protocol manager manages the low-level communications, thus ensuring, for the other parts of the system, transparent communication across a network. The protocol manager determines the type of request and invokes the appropriate protocol suite to service the request.

The WWW server ensures transparent access to the tremendous collection of documents that is actually a primary WWW goal. The server does this either by handling the access directly (for known resource types) or through a proxy known as common gateway interface (CGI). CGI handles resource types that a native server cannot handle and handles extension of the functionality of the server, as will be discussed below. The request scheduler is an important architectural component to synchronize requests concurrently coming from multiple (often very many) clients and other server components sharing a single data processing unit. The request scheduler can be seen as a queue of clients' requests to the server. The User Session Manager is an architectural component to resolve a conflict between the server serving simultaneously many users and personalization of a particular user access.

Normally, the user session manager keeps a user specific data (for example, user status, login name, etc.), identifies a user for each particular request, and recovers the user specific data to properly carry out the request. When a request is received by the request manager, the type of request is determined. If a known file is requested, the HTTP server accesses the file system and writes the requested information to the output stream. If a program is to be executed, a process is made available (either new or polled) through the CGI and the program is executed, with the output written by the server request manager back to the WWW client. In either case, CGI is one of the primary means through which servers provide for extensibility, and ease of extensibility has become one of the most important requirements driving the evolution of Web software. CGI has become an important aspect of Web-based applications. 1.2 Designing WWW Applications Most information served by a server is static; it changes only when its author modifies it on its home tile system. Common Gateway Interface (CGI), on the other hand, allow dynamic, request-specific information to be returned by a server. The most common use of CGI, is to create virtual HTML documents- documents that are dynamically synthesized in response to a user request.

CGI applications are written in a variety of languages, some of which are compiled (C, C++, Fortran) and others run under control of a CGI compatible virtual machine (Java Scripts, Java Servlets, PHP scripts, CGI scripts, etc.) Thus, WWW technology may be seen as an operating environment for developing full-fledged distributed applications. In this case, HTTP serves as a transport protocol HTML server as graphic user interface purpose-oriented functionality is implemented as a CGI compatible application Actually, the term CGI compatible application may be seen as an Internet access to any local application. For example, a database management system, spreadsheet, expert system, etc.

Unfortunately, all such internet applications experience common problems: Performance: all the calculations requested by a number of clients are performed on the server what results in a longer responce time. Usability: HTML does not provide such up-to-date graphical user interface solutions as drag/drop, animation,vector graphics, etc. Internet Traffic: almost any user actions results in generating and transfering rather long HTML files what considerably increase an Internet traffic and the system overall costs for users. Of course, the WWW technology provides another solution to build WWW compatible applications - client site applications. A particular WWW server may just provide access to a purpose-oriented applications which are interpreted by a WWW client.

Moving calculations to a client site considerably increases performance and decreases an internet traffic. At the same time, all such internet applications experience user interface problems and especially browser incompatibility.

2 CORBA Distributed object systems are distributed systems in which all entities are modeled as objects. Distributed object systems are a popular paradigm for object-oriented distributed applications. Since the application is modeled as a set of cooperating objects, it maps very naturally to the services of the distributed system. CORBA, or Common Object Request Broker Architecture, is a standard architecture for distributed object systems. It allows a distributed, heterogeneous collection of objects to interoperate. 2.1 Distributed Object Systems CORBA is an architecture for distributed object systems. It basically means two things: A system functionality is defined by means of Object-Oriented programming paradigm. calculation is distributed over a network. Object-Oriented programming paradigm: A system is presented in a form of Objects Objects (Clients) request services from other objects (Servants) Everything else is defined by CORBA in terms of this basic paradigm. A distributed calculation is implemented over a location transparency. Exactly the same request mechanism is used by the client regardless of where the server is located. It might be in the same process with the client, down the hall or across the planet. The client cannot tell the difference.

2.2 CORBA: Basics The location transparency is implemented as a pecial component called ORB (Object Request Broker). ORB is a special computer network environment providing transportation of requests and data from one physical location to another. In CORBA, every object instance has its own unique object reference, an identifying electronic token.

Clients use the object references to direct their invocations, identifying to the ORB the exact instance they want to invoke (Ensuring, for example, that the books you select go into your own shopping cart, and not into your neighbor's.) CORBA essentially separates object interface from implementation. In interface is defined by means of special IDL (Interface Definition Language). Any client that wants to invoke an operation on the object must use this IDL interface to specify the operation it wants to perform, and to marshal the arguments that it sends. The interface to each object is defined very strictly. In contrast, the implementation of an object its running code, and its data is hidden from the rest of the system (that is, encapsulated) behind a boundary that the client may not cross. Clients access objects only through their advertised interface, invoking only those operations that that the object exposes through its IDL interface, with only those parameters (input and output) that are included in the invocation. An interface definition (IDL) is compiled into client stubs (used to request a sevice) and object skeletons (used to provide a service). Stubs and skeletons serve as proxies for clients and servers, respectively.

When the invocation reaches the target object, the same interface definition is used there to unmarshal the arguments so that the object can perform the requested operation with them. The interface definition is then used to marshal the results for their trip back, and to unmarshal them when they reach their destination. In order to invoke the remote object instance, the client first obtains its object reference. There are many ways to do this, but we won't detail any of them here. Easy ways include the Naming Service and the Trader Service (below). The client acts as if it's invoking an operation on the object instance, but it's actually invoking on the IDL stub which acts as a proxy. Passing through the stub on the client side, the invocation continues through the ORB (Object Request Broker), and the skeleton on the implementation side, to get to the object where it is executed. CORBA has standardized inter object collaboration process at two key levels: First, the client knows the type of object it's invoking (that it's a shopping cart object, for instance), and the client stub and object skeleton are generated from the same IDL. This means that the client knows exactly which operations it may invoke, what the input parameters are, and where they have to go in the invocation; when the invocation reaches the target, everything is there and in the right place.

In order to be able to do that, the the system needs to have access to information about the object's location and operating environment. The database containing this information is called Implementation Repository and is a standard component of the CORBA architecture. The Implementation Repository may also contain other information pertaining to the implementation of servers, such as debugging, version and administrative information. Second, the client's ORB and object's ORB must agree on a common protocol - that is, a representation to specify the target object, operation, all parameters (input and output) of every type that they may use, and how all of this is represented over the wire. This function is fulfilled by General Inter-ORB Protocol (GIOP); it has been specifically defined to meet the needs of ORB-to-ORB interaction and is designed to work over any transport protocol that meets a minimal set of assumptions. Of course, versions of GIOP implemented using different transports will not necessarily be directly compatible; however their interaction will be made much more efficient. Apart from defining the general transfer syntax, OMG also specified how it is going to be implemented using the TCP/IP transport and thus defined the Internet Inter- ORB Protocol (IIOP).

2.3 CORBA: Services Object Services are domain-independent interfaces that are used by many distributed object programs. For example, a service providing for the discovery of (Searching for) other available services is almost always necessary regardless of the application domain. Two examples of Object Services that fulfill this role are: The Naming Service -- which allows clients to find objects based on names; The Trading Service -- which allows clients to find objects based on their properties. There are also Object Service specifications for lifecycle management, security, transactions, event notification, etc. Common Facilities -- Like Object Service interfaces, these interfaces are also horizontally-oriented, but unlike Object Services they are oriented towards end-user applications. An example of such a facility is the Distributed Document Component Facility (DDCF), a compound document Common Facility based on OpenDoc. DDCF suports an interoperability of objects based on a document model, for example, facilitating the linking of a spreadsheet object into a report document.

3 Database System Architecture of any RDBMS system is heterogeneous. These systems utilize not only one architectural style but rather they combine a number of architectural styles into a complex software architecture. At the top level, RDBMS can be seen as a client/server system. The client is the process that issues special data processing commands (database transactions). Database transactions are processed by the server that actually access the database. Thus, the server: Controls the physical files containing the data. Checks user login and privileges. Support logical and physical structure of the database (integrity) Optimize transactions to increase performance Manages transactions received from multiple clients

Normally, a Database Management System (DBMS) has a number of ready-made clients allowing a user to work interactively with a database using SQL commands or another data manipulation language. Such clients are called system clients. A database application is implemented as a number purpose-oriented clients that use special API (Application Programming Interfaces) to initiate database transactions. The transactions are embedded into the code to access/modify database. In this case, the programming language is called Host Programming Language. Conceptually, a database server is build using layered architecture. We can distinguish Communication Layer that provides a transparent communication between the server and clients independently of their physical position. Logical Layer that implemnts main DBMS functionality in accordance with logical data model supported by the system Physical Layer that masks all hardware, operating system, and protocol dependencies. Normally, logical layer consists of the following components: Transaction Manager that accumulate and queue data transactions received from different clients. Session Manager that resolves a conflict between the server serving simultaneously many users and personalization of a particular user access

Transaction Engine that parses, optimizes and carry out database transactions Recovery Engine control whether a transaction has been carried out successfully, and recovers the database in case of any erroneous situations Note, the Transaction Engine and Recovery Engine are built on top of functionality provided by the physical layer. Physical layer os a database server consists of the following components: Buffer Manager that controls elements of the database in RAM. Typical problems that is solved by the component is reducing of read/write operations by keeping most frequently accessed parts of the database in RAM. Resource Manager that controls such additional data elements as database journals, flags, dynamically built indexes, etc. Storage Manager that implements a patform and position independent storage access operations.

4 Real-Time Systems Real-time systems operate under strong time conditions (constraints), they are inherently distributed and dynamic. In order to reflect these properties, software architecture for real-time systems which monitor, control, or simulate real world processes must provide adequate means to cope with time, concurrency, and decentralisation. Most often, real-time systems are design using "Event" architectural style. Additionally, the real-time architecture should reflect the following tasks: time-stamping of all involved processes. scheduling of all involved resources. The event receiver gets all the events from external sensors and internal systems components. Additionally, the component. provides an event time-stamp using a high resolution global clock calculates a time until when the event should be processed sends the time-stamped event (i.e. a so-called task) to the task scheduler.

The task scheduler controls the order in which the tasks are carried out by the system. We can see it as a dynamic changing the tasks priorities as follows: for each task the system keeps an average time needed to carry it out and relative importance the prority can be calculated using a particular time restriction, relative importance and current system time. the task scheduler selects a task having highest priority, and sends it to process manager that initiates a special process for an especially designed software component. Note, if the task manager encounters a task having higher priority then currently running process, the process is interrupted. The priority assignment scenario above is known as "worst-case" scenario. However, it is a non-trivial problem to find the relative importance of tasks such that the whole system behaves optimal. Since there might be a number of processes running concurrently resources (memory, input/output devices, etc.) might be redistributed between processes. The resource manager allocates system resources to processes in accordance with their relative priority. For example, in accordance with the "worst-case" strategy all system resources are allocated for a process if the task priority reaches a certain threshold value (task is a risk for the whole system functionality).