|
|
YOUR FEEDBACK
Did you read today's front page stories & breaking news?
SYS-CON.TV |
TOP THREE LINKS YOU MUST CLICK ON Administration
Enhancing Application Manageability Part 1
By: Justin Murray
Digg This!
When we build enterprise applications based on either a J2EE-compatible application server or an XML Web services platform, we tend to leave the manageability of our application as a problem for the base platform to solve. We therefore may not do any work in our business logic to enhance the manageability of our application in production. This is not a good policy and can lead to an application that is more difficult to manage than it should be when it is deployed. J2EE application servers, a foundation for XML/SOAP Web services applications, give us tools for monitoring our software servers and, to an extent, our applications. However, software developers need to exploit these facilities to give more application-level manageability, as opposed to platform-level manageability. The difference between these two can be compared to knowing the number of items in my shopping cart (an object at the application or business logic level) as opposed to what is happening in the BEA WebLogic Server (WLS) message queues that are supporting it. The absence of manageability can cause serious problems. The application software can become an unmanageable entity once it is deployed because the operations staff doesn't understand it. Lack of attention to manageability raises the cost of supporting and maintaining the software product significantly. Software developers can be engaged in solving post-deployment management problems that could have been handled in steps taken earlier in the software life cycle. Those steps will be described here.
This article describes a range of choices for the developer, including:
The concept behind these JMX managed bean objects will be explained later. These steps can be viewed as incrementally increasing the levels of manageability in an application. They may be followed separately or all together for one application. The article positions the various technologies to help the developer integrate them and build a better application. The good news is that much of the hard work has already been taken care of by the application servers and by management tools. However, there is still some work to be done in the application.
Background Application manageability is not limited, however, to knowing simply whether the application is alive or not, or whether the application has produced an error message in its log file. For certain applications we may well need to know how many user transactions the application processed over the past hour or two, how long on average each transaction took, and what percentage of them failed to complete. Sophisticated applications have queues of requests, some of which are outstanding and some are being processed. The system manager in such cases needs to know the condition of each queue, so that he or she can respond to problem situations appropriately. Should a queue of incoming requests be causing delays to the end user, for example, the administrator may wish to allocate some of those requests to another identical process, thus avoiding a problem. We need a framing definition of what the term "manageability" means in order to judge how much of it to build into any one application. This "level of manageability" determines what technologies we use and how much effort we expend on this aspect of the application design.
Definition of Manageability
Manageability is further broken down into three main pieces:
Manageability covers the activity of ensuring that the application is alive and functioning normally, as well as checking that an application's performance is as expected. When a problem occurs, manageability tools enable the troubleshooting engineer to find the problem. These aspects of manageability are used to assess the various technologies. Further, manageability covers the monitoring, tracking, and control of more than one instance of the same software. For example, applications built on J2EE application servers are frequently replicated on several computers for load balancing and fault tolerance reasons. Operators need to be able to see and control the levels of activity of each one of these instances at all times. They can then reroute requests or take other actions to allay problems and maintain service level agreements.
Key Design Decisions in Manageability
Approaches to Building Manageability into Applications
Application Log Files
Direct Logging from the Application to the Management Console
Indirect Logging from the Application
In the OVO toolkit are utilities for encapsulating application log files (and other sources of data, such as binary files and SNMP traps) as message sources. Further, there are screens for setting up "templates" or patterns for processing these messages at a centrally located management server, and then distributing these templates to the managed nodes so that all instances of an application can be monitored in this way. Such processing patterns may define that certain message types be excluded from appearing at management consoles, for example. The processing template may restructure the format of the messages, or may aggregate a set of messages into one, to avoid overloading the operator with too many messages. The choices for the template designer are many and are fully documented in the OVO administrator's guide. All the developer or IT operations person needs to do is:
The developer can choose the monitoring options for such log files and make decisions on factors such as:
Issues in Log File Encapsulation and Message Template Processing Filtering of the messages to highlight those that are of interest in certain situations can be achieved. These filters can then feed messages into a subsequent notification command or piece of logic. Tools exist in the management platform that can take these messages and demand that the operator respond in some fashion to the message. Correlation: Message correlation is also a task that requires the user or software designer to work harder with log files. Either the end user/operator has to correlate the messages, which apply to one situation, by hand, or a special piece of functionality has to be written to perform the correlation for him. The OpenView Operations templates take care of this issue for the developer. Further details on log file handling and message processing can be found in the OpenView Operations Concepts Guide (OVO-Concepts) and in the OpenView Operations Administrators Guide (OVO-Admin).
Log Files Summary
The Java Management Extensions Standard The JMX environment is composed of three levels of software
At the Instrumentation level, there are managed bean objects, or MBeans. These are Java objects that conform to either
Conforming to the JavaBeans format is straightforward. It implies that an object is serializable and has a null constructor. It is common practice to implement "getter" and "setter" methods on all of that object's properties or data members (class variables) that may be required to be visible to external management tools. Creating MBeans in this style means that once the MBeans are registered with the JMX server, called the MBean server, they can be reached for monitoring and control purposes by the tools at the distributed services layer at the top of the diagram. JMX requires the use of an MBean server shown at the Agent Level in Figure 1. MBeans are required to register their presence with an MBean server in order to be noticed by the management framework. The MBean server handles the management messages that are flowing to and from objects that have been previously registered as MBeans. Certain properties of the object that conform to the MBean interface can then be viewed by management tools and, in some cases, the behavior of the object can be changed using the functionality of management consoles. This is done through the connectors and other adapters that allow a management console to extract data from a JMX server, not through direct manipulation of the MBeans themselves.
Key Issues with MBeans for the JMX Developer
Trade-offs in using the MBean Interfaces Directory The developer has a choice of making their business object conform to the appropriate JMX-style interfaces or building separate JMX bean objects that are specifically for the management of their business objects. Why would this separation be interesting? Well, both techniques have their advantages. Using the inheritance method, where business objects inherit their JMX management interface, every such business object instance will need to be registered with the MBean server - and there could be thousands of them. With a separate object for manageability, which is the one conforming to the JMX interfaces, it alone registers with the MBean server, causing the number of entries to be fewer. This single management object will then be responsible for managing a group of business objects. There may be a need for only one management object for all instances of a business class. This is a trade-off and there is no right answer for all applications. The developer must make a design decision at this point. This will be discussed later.
Communication and Linkage
Key decisions therefore must be made by the developer on questions such as
The application developer has full control over the amount of communication going on between these business objects and MBean pairs. The application developer can choose to have a reference from one to the other or a bidirectional reference beween them.
Conclusion
References BEA WEBLOGIC LATEST STORIES
SUBSCRIBE TO THE WORLD'S MOST POWERFUL NEWSLETTERS SUBSCRIBE TO OUR RSS FEEDS & GET YOUR SYS-CON NEWS LIVE!
|
SYS-CON FEATURED WHITEPAPERS MOST READ THIS WEEK BREAKING NEWS FROM THE WIRES
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||