Monday, May 16, 2011

Middleware

Middleware is in operating system and application software between. Others think it should belong to a portion of the operating system. People use middleware, often is a group of middleware integrated together, form a platform (including development platform and operation platform), but in this group of middleware in must have a communication middleware, namely middleware = platform + communication, this definition is limited to only used in distributed system called middleware, also can put it and support software and practical software to distinguish.
Why use middleware?
Specifically, middleware shielding rock-bottom operating system complexity, makes the program developers face a simple and unified development environment, reduce the complexity of the program design, focusing on their own business, no need for program in different system software the transplantation of repetition of work on and, thus greatly reduced the burden on technology. Middleware bring application system, not only the development of the development cycle, simple and shorten, also reduced the system maintenance, operation and management of the workload, reduced the overall cost input. Computer
Middleware definition and classification
To solve the problem, people heterogeneous distribution put forward the concept of middleware (middleware). Middleware is located in platform (hardware and operating system) and applications between general service, as shown in figure 1 shows, these services have standard procedure interface and agreement. In view of the different operating system and hardware platform, they can accord with the agreement standard interface, and various realization.
Maybe hard to give middleware a strict definition, but middleware should have the following some features:
Meet the needs of large-scale application
Running on a broad range of hardware and OS platform
Support distributed computing, to provide cross network, the hardware and OS platform application of the transparency of the service or interaction
Support the standard agreement
Support the standard interface
Due to a standard interface for portability and standard protocol for interoperability, middleware has become the importance of the main part of many standardization work. For application software development, middleware than operating system and web services is more important, middleware provide program interface defines a relatively stable higher application environment, no matter the bottom of the computer hardware and software, as long as how renewal upgrade update, and keep the middleware interface definition of middleware foreign changeless, application software almost without any modification, thus protecting the enterprise application software development and maintenance in the major investments.
Second, the main middleware classification
Middleware include the is widespread, according to the different application needs emerged in many distinctive middleware products. But so far they haven't had a more precise middleware, therefore, the definition of the different angles or different level, the classification of of middleware would differ. Because middleware requires shielding distribution environment heterogeneous operating system and network protocol, it must be able to provide distributed environment communication services, we will this communication service called platform. Based on objective and realization mechanism of different, we will be divided into the following several kinds of main platform:
Remote Procedure calls (Remote Procedure Call)
The < Message Oriented Middleware (Oriented Middleware) -
Object Request agent (Object that Brokers)
They can be upward provide different forms of communication services, including synchronization, queuing, subscribe to release, radio and so on, in these basic communication platform, can build above for the application of framework, provide different fields service, such as transaction processing monitor, distribution data access, object affairs manager OTM etc. Upper platform for application of the heterogeneous platform shield differences, whereas the framework and defines the corresponding field application system structure, standard service component, etc, the user simply tell the framework concern event, and then deal with these events provide the code. When an event occurs, the framework will call user code. User code don't call framework, the user program frame structure, also need not concern for executive process, the system-level API calls, etc., all these responsible for completing the framework. Therefore, based on the application of middleware development with good scalability, easy managerial, high availability and portability.
1, remote procedure calls
Remote procedure calls is a widely used treatment method of distributed applications. An application USES RPC to "remote" executive at a different address space, and from the effects of the process of the same look and implement local calls. In fact, a RPC application is divided into two parts: server and are. Server provide one or more remote procedure; To the server are issued remote calls. Server and are located in the same computer can be located in different, also can the computer, even running on different operating systems and above. They communicate through the network. The corresponding stub and operation support provide data conversion and communication service, thus shielding of different operating systems and network protocol. Here are synchronous communication RPC. Using thread can undertake asynchronous calls.
In RPC model, and the server as long as are has the corresponding RPC interface, and has the RPC operation support, can complete the corresponding interoperability, and not limited to specific server. Therefore, RPC are/server distributed computing to provide strong support. Meanwhile, and remote procedure calls RPC offer is based on the services of the process access, are direct connection with server, no middle agency to handle request, so also has some limitations. For example, RPC generally require some network details to locate server; In the meanwhile, request are required server must be activity, etc.
2, the message oriented middleware
MOM refers to use high efficient and reliable message transfer mechanism of platform-independent based on data communication, data communication and to the integration of distributed systems. By providing information and message queuing model, it can be extended process in distributed environment, and communications between the supports multiple communication protocol, language, applications, the hardware and software platform. Currently popular MOM middleware products are the MQSeries, BEA of IBM MessageQ etc. Messages and queuing technology has the following three main features:
Communication program can be in different time run: the program is not on a network directly, but indirectly call each other news into the message queue, because do not have direct connection between program. So they don't have to run concurrently. News into the appropriate queue, target program don't even need is running; Even if the target, nor programs are running processes this message meant to immediately.
For application structure in complex without constraint: applications, communication between a program can not only is one-to-one relationship, also can undertake a pair of more and more of a way, even the various ways of the portfolio. Various forms of communication structure and did not increase the complexity of the application.
Procedures and network complexity is isolated from: program will news into message queues or removed from the message queue, and news to communicate the associated all activities, such as maintaining the message queue, maintenance program and the relationship between the platoon, processing network restart and mobile news network is the task, procedures not MOM directly with other programs, and they don't call involving network communication complexity.
3, object request agent
As object technology and distributed computing technology development, both mutual combination formed distribution object calculation, and development for today's software technology of mainstream direction. The end of 1990, Object Management group OMG first launched Object Management structure Management Object now OMA (Architecture), Object Request agent (Object that a Broker) is the core component that model. Its role is to provide a communication framework, transparently in heterogeneous distributed computing environment transfer object request. CORBA regulating includes all the standard interface ORB. 1991 launched CORBA 1.1 defines interface description language OMG IDL and support in concrete are/Server object on the ORB, interoperability API.
CORBA 2.0 standard described is different between the manufacturer provides the ORB interoperability.
Object request agent (the ORB) is an object bus in CORBA specification, it is in the key position, and define heterogeneous environment transparent send request and object of the basic mechanism, receiving response is to establish a relationship between objects are/server middleware. The ORB makes the object can be transparent to other objects to request or accept other object response, these object can be located in local can also located in remote machine. The ORB intercept, and is responsible for the requested the objects found can realize request, transmit parameters, calls the corresponding methods, return the results, etc. Are object does not know with server object communications, activate or storage server object mechanism, also don't need to know what server where the object is in what language, it is realized, use what operating system or other do not belong to an object interface system components.
It's worth recalling that are used to coordinate with server character is just the interaction between objects, according to the corresponding occasions, the ORB object can be are, also can be the server, even with both. When the object send a request, it is in are character; When it is receiving the request, it is server role. Most of the object is both play role play server role are again. Plus, because of the ORB is responsible for object request transmitting and server management, between are not directly connected with server with RPC, therefore, the support of the pure are/server structure, the ORB can support more than the complex structure.
4, the transaction monitoring
The Transaction monitoring (Transaction first appeared in monitors) allow for its mainframes, support the reliable operation of the large-scale Transaction processing environment. Along with the development of distributed computing technology, distribution of large-scale application system proposed transaction needs, such as business a lot of key transaction processing. The transaction monitoring are bound at between server, and transaction management and coordination, load balance, failure, in order to improve the system restoration of the overall performance. It can be seen as transaction processing applications "operating system". Overall, the transaction monitoring has the following features:
Process management, including start server process, for its assigned tasks, monitoring the implementation of load balance and on.
Business management, namely, guarantee of in its monitoring of the atomic transaction, consistency, independence and permanence.
Communication management, for are and server provides various communication mechanism between, including request response, conversation, queuing, subscribe to release and broadcasting, etc.
The transaction monitoring can provide for a lot of are services, such as aircraft booking system. If the server for each are all the resources needed to share its words, the server will be overwhelmed (as figure2shows). But in fact, at the same time not all are all need to request service, and once a request for a service, it are hoping to get quick response. The transaction monitoring above the operating system to provide a set of service, are for its request for management and distribution of the corresponding service process, make server in limited system resources can efficiently for large-scale services provided to clients.
Some of the problems faced in the three
Middleware can shielding operating system and network protocol for the application of difference, offers a variety of communication mechanisms; And the corresponding platform to meet the needs of different areas. Therefore, middleware for application provides a relatively stable higher application environment. However, middleware services is not "nostrums". Middleware some principles to be followed from actual and great distance. Most popular middleware services using proprietary API and proprietary protocols, established in a single manufacturer allows application of products, from different manufacturers realize hard to interoperability. Some middleware services only provide some platform, thus limiting the realization of between heterogeneous system applied in the transplant. Application developers in these middleware service on the application of establishing himself taxing considerable risk, with the development of technology they often still need to rewrite their system. Although the middleware service improved distribution calculation abstraction degree, but application developers still need to face many difficult design choice, for example, developers must also decide distribution are applied in fong and server square function distribution. Usually will say with convenient use are service on display device, the data service on server to close to the database, but it is not always so, besides other application functions to determine how to distribute is not easy. 

No comments:

Post a Comment