Week12-2. Networked Application Architecture Design and Implementation Application software design and development is just one part of the computer system development. To make the delivery to the clients application software is to be integrated into technology infrastructure. In general case Application Building Blocks are (ref. Figure 1): - Application Software - Data - Infrastructure Software - Local Area Network - Server - Desktop Computer - Global Internet Principal destiny of the networked application infrastructure is to support 4 most important features: - Communication across distance (LAN, Internet) - Communication across time (Data storage) - Computation and logic (Application software) - Human-Computer Interface (Presentation, GUI) The major Layers in a computer infrastructure are presented in the table Layer Application Function Provides specialized functionality directly needed by a user Example GRP business logic implementation Application components Specialized modules incorporated by many applications and purchased as a product from an outside company Middleware Hides the heterogeneity and distribution of operating system and network from the application. Also provides capabilities useful to a wide range of application, such as scalability, performance, security Manages and hides the details of resources such as storage and printing. Also manages the details of interhost communications Provides communication of data from one host to another MQ Series – messages services CC Validation Connector EntireX – connection to legacy system (Adabas) XML Parser Transaction Services, ODBC HTTP Server, Web Application Server Operating System and other Servers Network Windows, Unix DBMS, Directory Services, Mail Server Novell, Windows based network, Internet The new terms explanation Connector Objects – a special type of objects whose responsibility is to provide communication between essentially different software components (for example developed on different platforms) Messages Services – a special middleware developed to mange messages effectively Transaction Services – a special middleware to manage transactions to database Directory Services – services that locate users, services and resources in the network Network Infrastructure – provides services such as TCP/IP, directory and security whose capabilities can be accessed via open, standard interfaces and protocols Web (HTTP) Server provides communication over Internet Application Server – a middleware to provide a scalability, performance and Security for applications. Mail Server – a middleware to provide e-mail services Actually the choice what components should be included into the computer system model depends on the factors listed below: Platform solution. So far 2 distinctly different platforms are known – Windows based from Microsoft and Unix based from Java community. In spite of the possibility to implement cross-platform solutions, there are the “native components” for each platform allowing complete computer system modeling. Each platform offers fully integrated solutions and each platform has its own advantages and disadvantages. Detailed consideration of differences is beyond our course scope. Non-Functional Requirements, particularly scalability. The computer system scalability is easier to achieve with Application Server included. Non-Functional Requirements, such as performance and security. To achieve higher level of their implementation Directory Service, Transaction Services, Message Services should be implemented using specialized software (Servers or middleware) instead of those available with operating system. Data Storage Solution. Particularly the legacy system requires special components to be integrated to the system. Functional Requirements. To implement some standard functions such as e-mail sending, credit card validation, fax messaging it is preferable to use third party software components instead of doing private development. Application Architecture Examples Big Enterprise Application Architecture (Fig. 3) The model presents Java-based n-tier application architecture. It contains: 1. A browser interface access over TCP/IP network 2. Web Server 3. Application Server allows development and deployment of Java Applications and provides a set of major services: State/Session management, Connection Management, Load balancing and Logging 4. From Application Server there is the access to Transaction Management, Messages Services, Data Servers and LDAP Directory. Application Server use JMS (Java Message Services) to connect to MQ Series and JTS to connect to Transaction Services 5. Access to Data Server is provided through database middleware from Application Server through Integration Tier. Data Servers could include legacy system. 6. Special Middleware is required to connect to legacy system. 7. LDAP Directory is accessible from Web Server and from Application Server 8. Mail Server is accessible from Application Server Medium Enterprise Application Architecture (Fig. 4) The model presents Java-based n-tier application architecture. However such components like legacy system, Messages Services and Transaction Services are not included. Database Server is Oracle. Messages and Transactions management is implemented by Application Server. Small company application architecture (Fig. 5) The model presents Java – 2-tier application. It does not use separate services and rely on standard services of web servers and database servers. For this reason Web Server usually is more functional to provide additional services, such as IIS or Apache Network Topology The network topology schema is to show physical implementation of computer system. This is the blue print for deployment. Fig. 6 shows the example of topology for medium size application Application Software Physical Implementation The following tasks must be completed to arrange physical implementation of the application software: - Decide about EXE and DLL - Decide about components (Compiling) - Decide about component placement on the network (Deployment Diagram) - Develop Start-Up procedure and configuration files/parameters - Configure naming services - Deployment on designated infrastructure Executable code usually is compiled in one of 2 capacities; - The exe module that is started by Start-Up procedure to initiate the system running. Usually it contains the pieces of the software that is preferable to have constantly in memory (Action Controller, Front Controller) because they are constantly in use. Very often the main executable module is implemented as COM module or services of operating system. They are included into the services that are under control of operating system. EXE module creates its own process Client - Dynamically Linked Libraries (DLL). The modules from the libraries are uploaded “by request”, when some particular activity is initiated. Modules from DLL do not create processes A component is a physical model of code. Components can include both source code libraries and runtime files. Components can be created in the correspondence to functional structure. A component must have one or more interfaces. For example in GRP each mini-project can be considered as a component. Components represent a physical perspective. The component diagram is to define the dependency relationships between components, and this is the only possible type of relationships. The component dependency relationships show the order of compiling. If component A is dependent on B, B must be the first to compile. Apart the order of compiling, other goal of component creating is to facilitate management and interaction among teams involved into computer system development and implementation. The deployment view represents physical deployment of the application. Deployment Diagram shows all the nodes on the network, the connections between them, and the processes that will run on each one. In other words, Deployment Diagram shows which components and objects run on which node of application architecture. There is only one Deployment Diagram for a particular application. Start-Up procedure is essentially platform dependent. It could be simply a batch file with a single command <cd c:\application/main.exe>. Or it could be the COM module activated once by hands. Other detailed information about the application such as DLL names and paths, parameters needed to link application to middleware or servers are sourced through configuration files. In general terms configuration file could be considered as the link between application software and middleware. Each middleware defines its configuration file format and the only thing to do is to provide information requested. Configuration files language is either scripts or nowadays very often XML format is in use. Start-Up procedure may provide the paths to configuration files if they are not standard. And finally it is important to take care about naming services configuration to link all the pieces. Naming services provide the tool to support general requirements to object names availability. The simple example of naming services is Registry. Commonly available Objects ID must be included into the Registry. Another example – directory services. This is advanced storage of objects names and connection for complicated networked application. One more example – Domain Name Services (DNS) to store the URL of objects available via Internet. Application Architecture Design Application Architecture Design goal is to make the decision about each layer internal structure and the ways of interaction (interfaces, integration). Non- Functional Requirements provide good source of information to the architect. The table below contains the tasks that usually are to be completed. Task Define platform hardware Define platform software Task description Major sources of information to consider To decide what kind of Scale of the system, machine shall be used as a commercial value, server and as a client potential number of clients, performance and security requirements, other non-functional requirements To decide what operating Platform hardware system and languages will solution, functional be used for development requirements, nonand implementation. functional requirements Decide about DBMS Define communication middleware To define what kind of communication software is needed and decide what is to be used Platform hardware and software, functional requirements Define Network To define what software Platform hardware and Examples of solutions Servers: Sun Solaris Clients: PC, Mac Unix, Java, J2EE, Oracle Windows, VB, MS SQL Server Windows, VC++, Oracle Connection to DB – ODBC, JDBC Connection to Internet – IIS, Apache, IBM HTTP Server OS embedded network middleware Define application components and other middleware required Define security middleware and hardware Design the system architecture for both environments, production and QA Define configuration parameters for each middleware component Design special objects that may be required to implement communication shall be used to support Local Area Network To define what components could be purchased from a vendor instead of in-house developments. The components are used to implement some functional requirements such as e-mail sending, or user’s authentication. Or the necessity to have a component could derive from non-functional requirements, such as scalability, performance, security To define what additional hardware/ software is needed for the computer system protection Having the components listed, design the exact architecture. It means to make the exact decision about servers configuration (how many, the content of each), where firewalls are located, what is the network topology. Usually there are two solutions – for production and for QA To define the configuration parameters values that make all the components interact smoothly. In some special cases you may be required to develop special objects needed to integrate software components. Example: legacy system is to be included into a new system architecture software, nonfunctional requirements Knowledge of technologies available from vendors, Functional and nonfunctional requirements, Platform solutions Platform solution Non-functional requirements solutions Novell Web Application Server – Web Sphere, Web Logic. E-mail Server – Post Office, MS Exchange, Domino. Messages Service – MQ Series. Directory Service – LDAP, Active Directory Naming Services – Registry, JNDI Firewalls, Intrusion Detection System, Authentication tokens Platform solution, See the examples for a middleware, additional big enterprise system hardware, non(fig.2), middle size functional requirements (fig. 3) and small system (fig.4). QA solution can be more simple. Usually it does not contain additional middleware and hardware, but it must contain all the components needed to test functionality Platform solution, Usually the guides to middleware, additional harden middleware hardware, noncomponents are to be functional provided to the requirements. Special technical team attention to security requirements Vendor’s information Legacy system Legacy system usually interface, vendor’s is developed on a information, platform mainframe, using solution for the system powerful data storage under development like DB2 or Adabas. The connectivity middleware is usually available from a vendor, for example Application software deployment Decide about the components and develop Deployment Diagram Class Diagrams, platform solution, functional requirements EntireX for Adabas. However project specific components are to be developed and included into application architecture to implement the interface. Those components are known as adapters and connectors objects. Patterns are available to design the objects GRP Deployment Diagram (Fig.6)