1 / 96

Middleware Technologies

Middleware Technologies. MC9251. Unit-I Introduction. Middleware Middleware is a general term for any program that serves to "glue together" or mediate between two separate programs.

Download Presentation

Middleware Technologies

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Middleware Technologies MC9251

  2. Unit-I Introduction Middleware • Middleware is a general term for any program that serves to "glue together" or mediate between two separate programs. • A common application of middleware is to allow programs written for access to a particular database to access other databases Middleware

  3. Middleware • Enterprise Application Integration-EAI • To exploit the Internet, E-commerce, Extranet, and other new technologies • Middleware categories • TP monitors • RPC systems • Object Request Brokers (ORBs) • Database access systems • Message Passing Middleware

  4. Client-Server Architecture “Relationship between two computer programs, the client makes a service request from another program, the server”. • Can be used in a single computer • More important in Computer Networks • Example: FTP, Internet, Internet banking Middleware

  5. Client-server architecture - Static HTML pages Middleware

  6. Client-server - CGI Scripts Middleware

  7. Server side scripting technologies Middleware

  8. Client-Server Architecture • Two tier architectures • Three tier architectures • Three tier architecture with transaction processing monitor technology • Three tier with an ORB architecture • Distributed/collaborative enterprise architecture Middleware

  9. Transaction Processing monitor technology • The ability to update multiple different DBMSs in a single transaction • Connectivity to a variety of data sources including flat files, non-relational DBMS, and the mainframe • The ability to attach priorities to transactions • robust security Middleware

  10. Client-Server Architecture Characteristics • Service • Shared Resources • A symmetrical protocols • Transparency of location • Mix and match • Message based exchanges • Encapsulation of services • Scalability • Integrity Middleware

  11. Types of Servers • File server • Database server • Transaction server • Group server • Object server • Web server Middleware

  12. File Server • It is a computer responsible for the central storage and management of data files • Allows users to share information • File server – a normal PC – Dedicated network attached storage • System security to limit access to files to specific users or groups • Novell’s eDirectory, MS’s Active directory Middleware

  13. Database Server • SQL requests and Data • Server uses processing power to find the requested data • DBMS provides server functionality • Database Master servers and Slave servers • Client application written by the user Middleware

  14. Transaction Server • Transaction- a group of SQL statements • Client invokes Remote procedures – Servers execute transactions • Both client and server component coded by the user • Online transaction Processing (OLTP) Middleware

  15. Groupware Server • Addresses the management of semi-structured information • Applications are created using a scripting language and form based interfaces Middleware

  16. Object Server • Client objects communicates with server objects using an ORB • ORB locates an instance of object server class, invokes requested method • Server objects provide support for concurrency and sharing • Various ORB’s • CORBA - Object management Group • Dcom - Microsoft • SOM - IBM • NEO - SUN Middleware

  17. Web Servers • HTTP requests - HTTP responses along with optional data contents • Error response • Supposed to serve requests quickly from more than one TCP/IP connection at a time. Middleware

  18. Client/Server building blocks Architecture Analogy  • We buy houses and not plans • Thus, computer users buy business solutions and not client/server architectures • How is the application split between the client and the server? • What functions go into the client and server? • Can the client/server model accommodate businesses of all sizes? • Can a single client/server model accommodate all these type of users?  Middleware

  19. The Basic Building Blocks • Components: • Client • Server • Middleware and is catered for Middleware

  20. The Four situations • Client/server for tiny shops • Client/server software and most of the business services runs on the same machine – one person shop • Client/server for smallshops and departments • Classic Ethernet client/single-server building block implementation • Client/server for intergalactic enterprise • Multi-server building block implementation of client/server • Client/server for the post-scarcity world • Every machine is transformed in the world for both client and a server. Personal agents on every machine and do the negotiations Middleware

  21. Client Components • Operating system with: • a Graphical User Interface (GUI) • the ability to find and access distributed services • Web browser to: • provide the user interface • download the necessary components from the server on demand • Middleware components handle the non-local services. • Clients may also run a component of a Distributed System Management (DSM) system Middleware

  22. Server Components • Server Operating System • A server software package of some kind: • SQL Database server • Transaction Processing (TP) monitor • Groupware server • Object server • Web server • Middleware components handle the reception of requests for services • A server may also run a DSM component Middleware

  23. Middleware Components • These run on both the client and the server sides of a client/server application • Transport Stacks • Network Operating Systems (NOSs) • Service-specific middleware • May also have a DSM component Middleware

  24. General middleware – provide substate for most client/server • Communication stacks • Distributed directories • Authentication services • Network time services • Remote Procedure Calls • Queuing services • NOS extensions: • Distributed file and print services Middleware

  25. Service-Specific Middleware • Database: • ODBC, JDBC, SQLJ, DRDA, OLE DB, etc. • OLTP: • A variety of proprietary products • Groupware: • MAPI, VIM, JavaMail, SMTP, POP3, IMAP, etc. • Object: • CORBA, Microsoft's COM+ • Internet: • HTTP, CGI, XML, SET Middleware

  26. Server-to-Server Middleware • Middleware software may also be used to coordinate inter-server interactions • Servers are often clients to other servers, and vice-versa • Some server-to-server interactions require special middleware: • Mail servers may do store-and-forward type messaging • Databases and groupware use daemons to automatically replicate data Middleware

  27. Unit - II Enterprise Java Beans

  28. Enterprise Java Beans • Write once, run-anywhere, middle tier components Evolution of Technology • Mainframe/Terminal model • Transaction processor • To handle concurrent client requests • Several statements as on logical unit • Guaranteeing successful execution or non would be executed Middleware

  29. Transaction processor • Provides API with ‘begin’, ‘commit’, and ‘rollback’. • Logging mechanism ACID properties of Transactions • Atomicity • Consistency • Isolation • Durability Middleware

  30. Updates in a Database Response time is critical Can handle large volume of transactions Reviews information Involves long-running queries Smaller number of requests, longer think time OLTP Vs DSS/EIS/OLAP Middleware

  31. Evolution… • Two-Tier architecture • Transaction integrity by DBMS • Three-Tier architecture • Transaction integrity by Middle tier components • Sockets • Limited distributed computing • RPC • A thin layer on top of Sockets • Stub-Skeleton • Stub uses IDL Middleware

  32. CORBA • An object oriented RPC Mechanism • Objects written in one language can be called by objects written in a different language • CORBA clients can access EJB objects RMI • Java version of CORBA • No need to write IDL. RMIC handle automatically • EJB allows client side RMI calls to EJB objects Middleware

  33. EJB’s role • EJB specifies an execution environment • EJB is a java class implements Session bean or entity bean • Container provides services to EJB • Container provides proxy object for each bean • EJB exists in the middle tier • To encapsulate business logic • Supports transaction processing • Can Maintain state Middleware

  34. Enterprise JavaBeans (EJB) is an architecture for setting up program components, written in the Java programming language, that run in the server parts of a computer network that uses the client/server model. • Enterprise JavaBeans is built on the JavaBeans technology for distributing program components (which are called Beans,) to clients in a network. Middleware

  35. Enterprise JavaBeans offers enterprises the advantage of being able to control change at the server rather than having to update each individual computer with a client whenever a new program component is changed or added. • EJB components have the advantage of being reusable in multiple applications. • Can be deployed across all major operating systems, not just Windows. Middleware

  36. EJB’s Architecture • Logically three-tier system • EJB server & DB reside on the same machine – EJB server includes built in functionality for persistent storage • EJB server & Client – EJB bean makes a call to another EJB bean • All three tier might reside on a single machine Client - EJB Server - Database Middleware

  37. EJB’s role in the three layers • Client calls remote EJB’s • EJB components live in the middle tier, EJB objects reside in an EJB container which is in side of an EJB server • DB resides in the third layer EJB beans accesses the DB through JDBC Middleware

  38. Overview of EJB’s Software Architecture • EJB bean exists within the container • Client communicates with bean through home interface, remote interface Middleware

  39. Overview of EJB’s Software Architecture EJB server • Provides container with lower level services such as network connectivity • Layered approach EJB Container • Interface between EJB and outside world • Can create pool of beans • Provides services to Beans • Support for transactions, management of multiple instances, persistence, and security Middleware

  40. Enterprise Bean • EJB object is implemented, in addition Home interface and Remote interface implemented Types of EJB beans Middleware

  41. Session Bean – is created by a Client and usually exist only for the duration of a single client/server session. • Entity Bean – represents a business objects in a persistent storage mechanism • Ex : Customers, orders & products Middleware

  42. A stateless session bean is a distributed object that does not have an associated conversational state, thus allowing concurrent access to the bean. • The contents of instance variables are not guaranteed to be preserved across method calls. • Stateful session beans are distributed objects having a conversational state. The state could be persisted, but access to the bean is limited to only one client. Middleware

  43. Session bean Vs Entity bean • EB’s are persistent, allow shared access, have primary key, and may participate in relationships with other entity beans When to use Entity bean • If the bean represents a business entity, not a procedure • If the bean’s state must be persistent • Ex: CreditcardEJB - Entity bean CreditcardverifierEJB – Session bean Middleware

  44. EJB Session & Entity Bean Unit-III

  45. Session EJB • A session bean instance is: • A non-persistent object • Implements some business logic • Runs on the server • Live as long as the client need them Middleware

  46. Constraints on Session Bean • EJB cannot use threads – but container can run multiple instances • Cannot directly access transaction manager – container is responsible for managing transactions • Cannot use JDBC commit and rollback – container issues commit and rollback • Not allowed to change security identity at runtime • Cannot have static variables – it must be static final Middleware

  47. Session bean constraints • It is irrevocably disappear from the server • If timeout value expires • If the server crashes, shutdown, or restarted • Session beans are non-reentrant – another call to the same object from same transaction context throws remote exception Middleware

  48. Components of a Session EJB • The remote interface • Extends EJBObject (All extended types are from javax.ejb) • The home interface -Extends EJBHome • The bean class itself, called XBean • Extends SessionBean • Should implement java.io.Serializable (for stateful beans) • Implements business methods from the component interface • Implements lifecycle methods (ejbXXX) Middleware

  49. Stateless Session bean life cycle • Nonexistence • Method-ready state • Session EJBs have no state, so activation and passivation are meaningless • The container simply destroys instances when low on memory, and creates new ones as needed • Still, ejbActivate and ejbPassivate must be implemented in XBean (as empty methods) Middleware

  50. Middleware

More Related