1.11k likes | 1.36k Views
Introduction to Distributed Object Technology. Study Material. These slides shall be put up regularly on Vidyalankar Live. In my opinion, you don’t need notes on the subject. The following textbook is perfect for exam preparations Middleware & Enterprise Integration Technology
E N D
Study Material • These slides shall be put up regularly on Vidyalankar Live. • In my opinion, you don’t need notes on the subject. • The following textbook is perfect for exam preparations • Middleware & Enterprise Integration Technology • By G. SudhaSadasivam & RadhaShankarmani • Wiley Publications
Why MEIT • Scenario 1 • You own an enterprise that manufactures automobiles. • Let’s call your firm Audi • Your grandfather started the firm in 1920 • Your firm was doing well. • Your firm came out with new models every year and they were quality cars • Post the world war, industrialization and economic growth led to a boom in the automobile industry.
Why MEIT • Scenario 1 continued • Now, it’s 1970. • Your father was in charge. • He realized that if he bought a mainframe, he could improve the performance of his Accounting and Finance department. • So he installed a mainframe where batch processing and time-sharing were followed. • Then in the 1980s came the PC. • So, you gave a couple of PCs to the A&F Dept. • They set up a few accounting and financial tracking software. • All was good.
Why MEIT • Scenario 1 continued • Then came the 1990s. • Your father realized he could start computerizing a whole lot of things. • So the manufacturing dept. got PCs for tracking purposes. • The design and R&D departments got PCs for their work. • The managers got PCs for reporting purposes. • The Warehouses and Inventory departments got PCs. • The sales & marketing departments got PCs.
Why MEIT • Scenario 1 continued • 1990s also saw the use of information systems. • So your dad set up servers with information systems for all the aforesaid departments. • All was good. • Until, one day (in 1999) the Manufacturing head and Inventory head walked into your dad’s office. The Manufacturing head was angry with the Inventory head for not informing him of a shortage in the inventory of mirrors. The manufacturing head missed out on his annual target because of “incompetency.” • Your dad fired the Inventory head.
Why MEIT • Scenario 1 continued • Then a few months later, the Sales head walked into your dad’s office. He said, “I can’t sell these cars. No one wants 3.8Litre 300hp engines, bucket seats, stick (manual) shift, carbon fiber body and Le Mans racing stripes on sedans.” • Your dad called the R&D and Design Heads. Clearly they were not in touch with the customer needs and they were fired too. • Now in 2001, your dad hired an Information Systems specialist and set up an IT Department.
Why MEIT • Scenario 1 continued • In August 2002, a fresh problem arose. The Tax man made raids on your firm for non-payment of taxes. • Your dad hired Pricewaterhouse Coopers. They identified the problem. Apparently the sales figures received by the Finance team had not been updated with sales for the last two weeks of March 2002. • The Sales Head was called and promptly fired. • 1 week later, your IT systems head met your dad.
Why MEIT • Scenario 1 continued • The IT Head says to your dad, “It’s no ones fault. The problem is that your various Information Systems are not communicating.” • That made a lot of sense. • What if these systems could automatically send each other the required information as and when needed. No human error would be in the picture. • So your dad hires SAP to do an analysis. They say, we’ll set up an ERP for you and revamp all your information systems. • The cost, $200 Million! • The guys from SAP are kicked out the door.
Why MEIT • Scenario 1 continued • The IT Head says to your dad, “Yes, We will set up an ERP. But, we won’t change the existing systems. We’ll use Middleware.” • What is an ERP? ERP is Enterprise Resource Planning and is a set of systems that streamlines the way an enterprise views and utilizes its resources – Unofficial definition • The cost is just about $20 million for the entire solution. • Your dad says “Go for it!”
Why MEIT • So, we’ll revisit this scenario later in the semester. • But just to explain it to you briefly, • Middleware is software that enables the communication and synergy between multiple disparate systems
Why MEIT • Scenario 2 • You own Dell. • You are assembling branded PCs, Servers etc. • You require parts from Intel, nVidia, AMD, Fujitsu, Toshiba and a few lesser known firms. • You want to streamline the inventory and supply chain management. That is whenever you need supplies, you want the above firms to be automatically notified and paid. • But, Intel’s ERP is SAP. nVidia is Oracle, AMD is PeopleSoft etc. • How can you integrate your information systems with theirs?
Why MEIT • Scenario 2 • The answer is Enterprise Integration Technologies • This is Middleware to integrate ERPs. • Earlier you were considering Middleware to integrate Information Systems. • Don’t worry. We’ll be revisiting this scenario and this concept again. • However, I hope you now understand the relevance of this subject. • Note that the IT industry in India is predominantly working on ERP & MIS. Hence the importance of MEIT. You’re being made industry ready!
Chapter 1 Let’s Begin
Learning Objectives • Evolution of Distributed Systems • Evolution of Object Technology * • Elements of Object Technology * • Distributed Object Systems * • Properties of Distribution * • Issues in Distribution * • Client / Server Architecture • Multi-tier Architecture * • Types of Servers *
Introduction • What is a distributed system? • A distributed system is a collection of autonomous computers linked by a network with software designed to produce an integrated computing facility. • When did we start thinking distributed? • The potential for distributed systems became apparent in the 1970s after the emergence of minicomputers • Later Client/Server systems were developed followed by open, scalable and fault-tolerant distributed systems in the 1980s
Introduction • The pitch • As monolithic applications are difficult to customize, software development cost and time increases. • What do you mean by monolithic applications? • This difficulty can be overcome by using component – based systems • These systems use interoperable components to reduce the cost and time involved in software-development. • A component is viewed as a collection of objects. • An object works in a single process • To facilitate the access of an object’s functionalities from outside its process space, distributed object technologies are used • These technologies enable the access of objects in multiple processes in a transparent way.
Introduction • Types of distribution: • Distribution of access • A two tier architecture • Distribution of functionality • A multi-tier architecture
Evolution of Distributed Systems • Improvements in hardware components made it possible to produce cost-effective machines. • This made commerce and government departments recognize the importance of computers. • Thus, business has driven technology toward faster, cheaper and superior products. • In turn, technology has also driven business to set and achieve new, higher targets. • The modern computing era began in 1946 with ENIAC machines. Subsequently we’ve had a few generations of enhancements. • The computer system architecture has evolved from single systems to host-centric systems like mainframes and mini-computers, network-centric and distributed architectures as shown in the next slide.
Evolution of Distributed Systems • User Needs. • Users want swift and immediate results. • These needs can be satisfied by increasing the processing capacity of a single system and by providing a virtual and transparent computing environment. • Enhancements in speed and storage and diminishing costs of PCs facilitated the use of multi-processors on a distributed scale across networks. • Parallel processing is evolving from uni-processing to symmetric multiprocessing and from massively parallel processing to distributed multiprocessing and to clustering. • Thus, computing has migrated from processor centric to network centric architectures • Let’s discuss this briefly. • Hadoop • Virtualization • Cloud Computing
Evolution of Distributed Systems • The earliest form of a distributed system was a client/server design, in which independent servers perform centralized tasks such as database maintenance. • The client/server systems have evolved from single-tier to two, three and multitier architectures • Mainframes used batch processing in computer centers and mini computers used time-shared processing in terminal rooms. • PCs & Distributed Systems • Processing in PCs takes place on desktops • Processing in distributed computing is geographically dispersed • Software for parallel systems is executed on the same computer • Software for distributed systems is distributed across two or more independent nodes. • In the 1970s, internally lined, tightly coupled processors were used for parallel processing. • Later, externally lined processors communicating using networks led to distributed computing, wherein the network is viewed as a gigantic computer. • Supercomputers utilize this principle and architecture. • Example: Supercomputer using PS3
Mainframes • Mainframes are powerful computers used mainly by large organizations for critical applications, typically bulk data processing such as census, industry and consumer statistics, enterprise resource planning, and financial transaction processing. • The term originally referred to the large cabinets that housed the central processing unit and main memory of early computers. • Later the term was used to distinguish high-end commercial machines from less powerful units. • Most large-scale computer system architectures were firmly established in the 1960s and most large computers were based on architecture established during that era up until the advent of Web servers in the 1990s.
Mini-Computers • A minicomputer is a class of multi-user computers that lies in the middle range of the computing spectrum, in between the largest multi-user systems (mainframe computers) and the smallest single-user systems (microcomputers or personal computers). • The class at one time formed a distinct group with its own hardware and operating systems, but the contemporary term for this class of system is midrange computer, such as the higher-end SPARC, POWER and Itanium -based systems from Sun Microsystems, IBM and Hewlett-Packard.
Evolution of Distributed Systems • Modern Operating Systems • 3 Groups • Based on the interaction that takes place between the computer user and application program • Batch-processing operation systems • Users submit jobs to a central place where these jobs are collected into a batch and subsequently placed on an input queue in the computer where they are executed. The user has no interaction with the job during its processing • Example: Mainframes • Time-sharing operating systems • A computer provides computing services to several users concurrently on-line. Users share the central processor, the memory and other resources of the computer system monitored by the operating system. The user can interact with the program during its execution • Example: Minicomputers • Note: this architecture is back in prevalence with the move towards virtualization
Evolution of Distributed Systems • Modern Operating Systems • 3 Groups (contd.) • Real Time Operating systems • Designed to service those applications which require fast response in order to prevent errors and disasters. These systems are designed to be interrupted by external events that need immediate attention. • Example: Airline reservations, household appliances, portable media players etc. • Modern computer operating systems are usually hybrids, incorporating more than one of the above stated operating systems. • Does your PC have and RTOS? Where? • A multi-programming operating system is a system that allows more than one active user program to be stored simultaneously in the main memory. • A multi-processing operating system is a computer hardware configuration that includes more than one independent processing unit.
Evolution of Distributed Systems • A networked operating system is a collection of physically interconnected computers. • The OS of each of the interconnected computers must contain facilities to handle the functionality and communication to provide for the transfer of program and data among interconnected computers. • Each machine runs its own local operating system and has its own user. • Facilities to achieve remote login and remote file access are needed. • A distributed computing system consists of a number of computers that are connected and managed so that they automatically share the ob processing load among themselves. • Such a system requires an OS to handle its functionality, coordinate the operations and allow flow of information. • Distributed systems allow a program to run on several processors at the same time and hence require more complex scheduling algorithms to optimize the amount of parallelism achieved.
Evolution of Distributed Systems • Definitions • A distributed system is a system consisting of multiple interconnected autonomous processes which are involved in the coordinated execution of data processing tasks by messages sent through a communication system. • It gives a single system view to its users and provides a single service. • Because tasks and processes are replicated, these systems are more fault tolerant. • Examples: GPS, ATM • A distributed OS is one that appears to its users as a traditional uni-processor system, even though it is actually composed of multiple processors. • In a true distributed system, users are unaware of the location of files and services, i.e. abstraction • In a networked OS, users are aware of the existence of multiple computers and can log in to remote machines and copy files from one m/c to another.
Evolution of Distributed Systems • Characteristics of a DOS (Distributed Operating System) • Facilitates the use of network resources • Maximize utilization • Provides the user with a virtual computing environment (Abstraction) • User gets the illusion he is on a single powerful m/c • Hides the distribution of resources • Transparency • Provides security against unauthorized access • Provides secure communications
Evolution of Distributed Systems • Challenges faced by distributed systems. • Transparency • The concealment of the separation of the components of a distributed system from the user • Provides a single image view to the user & often difficult to achieve • Includes: • Access Transparency • Hiding of data representation and resource access details • Location Transparency • Hiding the location of the resource • Migration Transparency • Hiding resource movement to another location • Relocation Transparency • Same as above except for movement while in use • Replication Transparency • Hiding the usage of multiple copies of the resource • Concurrency Transparency • Hiding the usage of a resource by multiple competitive users • Failure Transparency • Hiding the failure and recovery of a resource • Persistence Transparency • Hiding the storage of data permanently
Evolution of Distributed Systems • Challenges faced by distributed systems • Flexibility • Flexibility leads to extensibility – Scaling • The act of adding components / services to the system • Microkernel –based client/server systems are inherently more flexible than monolithic systems, which makes them particularly attractive for distributed systems • Dependability • Reliability • DS provides higher availability by replication • The probability that the system is active and providing correct service during an interval of time • Availability • The fraction of time when the system is usable • The probability that the system is operational at a particular time instant • Timeliness • Ability to meet time constraints imposed on task execution • Integrity • Capability to keep replicated copies of data consistent • Security • Protection of information against unauthorized users and integrity (security perspective) of information
Evolution of Distributed Systems • Challenges faced by distributed systems • Performance • Scalability • Performance must not degrade with growth of the system in terms of number of users and resources • Centralized services, data and algorithms hinder scalability • Hiding communication latencies, asynchronous communication, distribution of components, DNS namespace, caching, replication and maintenance of consistency bring about scalability. • Openness • Whether the system can be extended and re-implemented in different ways • Whether new resource sharing services can be added and made available for different clients
Evolution of Distributed Systems • Challenges faced by distributed systems • Failure Handling • Systems should be fault-tolerant (transaction based – accept occasional failures with lengthy recovery procedures OR process-based – strict timing requirements) in nature • Concurrency • Heterogeneity • Provided by middleware – a software layer that provides programming abstractions and masks the heterogeneity in underlying n/w, OS, computer hardware and programming languages.
Evolution of Object Technology • Programming has shifted its focus from languages that tell computers what to do to languages that describe key abstractions in the problem domain. • High level languages have been classified into five generations based on their features. • First Generation Languages (1950-54) • They are raw machine codes • Micro-code is an example of the first generation language residing in the CPU & is written for doing multiplication or division. • Computers programmed in binary notation are error prone and lengthy • Therefore, mnemonic codes were used to represent operations • Symbolic addresses allowed programmers to represent memory locations, variables and instructions with names. • This improved the flexibility in programming. • Although this kind of programming is fast, it is machine dependent and hence lacks portability.
Evolution of Object Technology • Second Generation Languages (1954-58) • Primarily used for scientific and engineering applications. • The vocabulary of the problem domain is entirely mathematics. • This it freed programmers from the intricacies of machine and assembly language programming • The advantages of high level languages include the support for ideas of abstraction so that programmers can concentrate on finding the solution to the problem rapidly, rather than concentrating on low-level details of data representation. • There is more coupling among the parts of programs due to global accessibility of data. • Hence an error in one part of the program can affect another part of the program. • Such a system faces problems of extension and integration and hence is less reliable. • Example: FORTRAN-1 & ALGOL-58
Evolution of Object Technology • Third Generation Languages (1959-75) • Often followed procedural code, wherein the language performs functions defined in specific procedures. • Emphasis on algorithmic abstractions and independence of hardware • Basic building blocks of such applications are subprograms. • They were viewed as abstraction mechanisms. • This leads to structured programming and design methods. • +ves: Ease of use & learning, improved portability, simplified debugging, modifications and maintenance • Lead to reliability and lower costs. • Examples: ALGOL-60, FORTRAN-II • Later, 3GPLs addressed the issue of programming in finer details. • Different parts of the program were developed separately. • Modules were used as an abstraction mechanism to group related subprograms. • One module could access and change the data belonging to another module.
Evolution of Object Technology • Third Generation Languages (1959-75) • Later, the advantages of object orientation were incorporated into the available procedural languages. • Simula was improved in 70s to bring forth Smalltalk, Object Pascal, C++ etc. • These languages are called object-based or object oriented languages. • The physical building blocks of such languages are modules, which are a logical collection of objects and classes. • Procedure-oriented programs are organized around verbs or actions, while object oriented programs are organized around nouns. • OOP uses little or no global data. • In very large systems, clusters of abstractions are built-in layers with meaningful collaboration. • This leads to component based design
Evolution of Object Technology • Fourth Generation Languages (1980 onwards) • Non-procedural languages, integrated data dictionaries, dynamic relational databases are examples of fourth generation languages. • They aid in rapid system development and prototyping • These languages are user-friendly, portable and independent of operating systems • They are usable by non-programmers, having intelligent default options about what the user wants and allowing the user to obtain results faster using minimum requirement code generated with bug-free code from high-level expressions. • Example: IBM’s ADRS2
Evolution of Object Technology • Fifth Generation Languages (1990 onwards) • Languages such as PROLOG, referring to systems used in the field of AI, fuzzy logic and neural networks. • Facilitate computers to think and draw their own inferences using programmed information in large databases. • Basically they facilitate machine-learning. • They could simplify complex processes like speech recognition. • They are declarative in nature • Declarative languages allow the programmer to concentrate on the logic of the algorithm. • They are goal driven – control is not the concern of the programmer as against imperative languages where the programmer must focus on both control and logic. • The future of PLs is entirely dependent on the needs of both computer and communications industries. • The trend is towards a combination of 5GPLs and parallel processing techniques.
Preview of Object Orientation • Object orientation is so called because this method / approach sees things that are part of the real world as objects. • It lays emphasis on viewing the system as a collection of objects. • In everyday life, we simplify objects in our thinking by modeling them. • The same is true in the field of software development. • The essential features of real-world objects are represented as symbols. • Complex realities are more manageable using models.
Preview of Object Orientation • Let’s go off topic for a moment. • Consider any software you will develop. • For convenience let’s talk of a customer management and sales tracking application. • Say the products are laptops. • Would you rather use an array or other data types to represent the properties and qualities of the laptop or would you rather create a parent class with all the properties. Now each customized laptop is a data structure that has certain standard properties. • Similarly for your customers. It is easier to model a data structure for people with the basic properties required than store it in arrays etc. How will you keep track of each property associated with each customer. • Object orientation addresses this issue!
Preview of Object Orientation • Object orientation fosters the following: • Information Hiding • It is the key to object oriented thinking • It stresses on hiding the unnecessary attributes of an object from the user • It simplifies the design of the system and reduces ripple effects. • Objects are like black boxes that hide the implementation details of their functionality from their users.
Preview of Object Orientation • Object orientation fosters the following: • Abstraction • It is the presentation of simple concepts to the external world. • Abstraction is the process of suppressing non-essential details of the system, while focusing on the essential details of the system. • Higher levels of abstraction focus on the important characteristic of an entity while lower levels focus on its construction • Example: An automobile • There are 3 categories of abstraction: • Functional Abstraction: Provides information on what functionality is being offered by the system while suppressing the details of its implementation. (RPC uses this feature) • Data Abstraction: It is build on top of functional abstraction. The attributes of an object are accessible only through the functionalities offered. It is only accessible through a well-defined interface composed up of operations • Process Abstraction: Deals with how an object handles itself in a parallel processing environment with more than one thread to control
Preview of Object Orientation • Object orientation fosters the following: • Encapsulation • Localization is the process of gathering and placing things in close physical proximity to each other • Encapsulation is the process of logically and/or physically packaging items so that they may be treated as individual units. While functional decomposition localized information around functions and data driven decomposition localized information around data, object oriented approached localize information around objects. • Classes provide a powerful encapsulation of data and functionality. • Concurrency • It enables parallel execution of processes.
Advantages of Object Orientation • This is presented slightly differently in your textbook but for the purpose of this discussion, the fundamentals are the same. • simplicity: • software objects model real world objects, so the complexity is reduced and the program structure is very clear; • modularity: • each object forms a separate entity whose internal workings are decoupled from other parts of the system; • modifiability: • it is easy to make minor changes in the data representation or the procedures in an OO program. Changes inside a class do not affect any other part of a program, since the only public interface that the external world has to a class is through the use of methods;
Advantages of Object Orientation • extensibility: • adding new features or responding to changing operating environments can be solved by introducing a few new objects and modifying some existing ones; • maintainability: • objects can be maintained separately, making locating and fixing problems easier; • re-usability: • objects can be reused in different programs. • interoperability: • Brought on by polymorphism (measure of the degree of difference between the items in a specified collection of items at a given level of abstraction. Polymorphism facilitates existence of different forms of objects within a collection)
Advantages of Object Orientation • easier integration • because objects offer clear interfaces using which they can be integrated into the system • traceability: • Degree of ease with which a concept can be followed from one point in a process to either a succeeding or preceding point in the same process • smooth transition between analysis, design and implementation phases of software engineering • reduces overall time taken to develop by promoting reuse • improves the quality of the system developed • number of errors are minimized • higher level of abstraction
Elements of Object Orientation • Abstraction • Abstraction is one of the fundamental ways that we as humans cope with complexity. • An abstraction denotes the essential characteristics of an object that distinguish it from all other kinds of objects and thus provide crisply defined conceptual boundaries, relative to the perspective of the viewer. • An abstraction focuses on the outside view of an object and so serves to separate an object’s essential behavior from its implementation.