Click here to close now.

Welcome!

Microservices Journal Authors: Lori MacVittie, Ruxit Blog, Roger Strukhoff, Carmen Gonzalez, Kevin Jackson

Related Topics: Microservices Journal, Virtualization

Microservices Journal: Article

Monitoring Web Applications Using Hyperic

Monitoring enables us to anticipate the issues

Monitoring applications is an important aspect of IT industry. Huge investments are made in setting and maintaining the IT infrastructure be it cloud or physical. To ensure maximum performance across your business, problems have to be identified and resolved before they affect the users. Monitoring enables us to anticipate the issues and hence resolve them before they start appearing as problems to users. We need to have visibility into IT infrastructure to identify the issue origin. For example, by monitoring the applications proactively, we can figure out the root cause whether its poor performance is due to the problem at resource level or at application level or at any other place and take action before it starts impacting the user. It gives us more control and confidence on the application and hence helps us in meeting the service quality requirements.

Performance issues can arise due to problems at any level - machine/ application/ transaction. We should be able to monitor through all levels so that exact point of origin can be located. Most of the current solutions provide monitoring at any one particular level. For example, some cloud based infrastructure solutions provide monitoring at machine level only. Problem need not be necessarily to be at machine level. There could be problem at the application level like increased thread count, more number of active connections to valuable resources, etc or at transaction level like response time, request rate, etc. Thus, monitoring across different levels gives us visibility to know where the problem lies. Once the problem origin is known, we can take corrective actions to resolve it before it impacts the user experience.

There should be a solution to achieve the same to dig out the actual problem. We are going to deal with it in this article. We are going to see how to monitor different metrics (CPU utilization, thread count per minute, response time) at different levels. We will use Hyperic as our monitoring tool to measure the metrics. It is a systems monitoring, server monitoring and IT management software. It is based on server-agent model. We will have a look at the basic architecture of Hyperic as well.

Use-case scenario - Problem statement

Consider a case where a web application becomes famous and workload increases on it. This causes the application's performance to go down which results in slow loading of web pages. There could be many reasons for the degradation of performance like CPU utilization exceeds certain level, application logic is poor, less number of resources in infrastructure which are not able to sustain the load and many more. Issue could be at any level as discussed. Availability and performance marks end users' experience. This necessitates the monitoring of applications at different levels so that any unexpected behaviour could be avoided by taking corrective measures on time.

Deep dive into the solution
One of the most common complaints heard from end user is ‘website responds very slowly'. Poor performance of application can drift the user away from web application and leaves a bad impact on them. To find out the reason for poor performance of application, we have to measure the metrics at different levels to dig out the actual issue. We are programmatically going to monitor CPU utilization at machine level, used thread count per minute at application level and response time at transaction level.

Monitoring requires a reliable tool which can track the metrics periodically and update the application administrators.  There are lots of monitoring tools present in the market with varying features. Some of the most commonly used are Hyperic, Nagios, Cacti, Ganglia, etc.  Most of the tools in the market represent the metric values in visual form which helps the administrators to monitor and analyze any unexpected behaviour of application.

Hyperic is one of the leading monitoring tools in this arena. Hyperic comes in two flavors - open source (under GPL licensing) and enterprise edition (commercial license). It is based on server-agent model.  Following is a short description of Hyperic key components:

  1. HQ Agent: HQ agent is responsible for collecting data of the machine in which it is installed and send it to server. Each machine which is to be monitored should have an HQ agent running.
  2. HQ Server: HQ server consolidates the data sent by agents installed on different machines and persist it in the Hyperic database. HQ server maintains the inventory which keeps the information of all the resources and their monitored values.
  3. HQ Portal: HQ portal is a graphical user interface which gives complete information about the resources being monitored. User can add/ remove/perform control actions/set alarms from this portal. It is highly customizable with provision of choosing the metric to be collected and changing the collection intervals.
  4. HQ Web Service API: It has java based API called HQAPI. It helps in accessing the resources and their metrics programmatically.
  5. HQ Plugins: Hyperic has its own set of resource plugins for collecting metrics and other operations. It is also possible to build a new plugin to support additional functionality.

A large number of metrics is managed by Hyperic. In case of virtual environment, Hyperic agents are installed on virtual machines. We will use HQAPI to access the resources.

Consider a web application deployed on Apache Tomcat as application server. We will deploy famous - Jpetstore web portal on application server and then monitor the same.

Deploy web application on application server
Copy the jpetstore application under ${Apache_Tomcat_Installation_dir}/webapps and start tomcat. Try accessing - http://localhost:8080/jpetstore link and if it shows jpetstore homepage that means application is deployed successfully.

The way resources are modelled in hierarchical fashion in Hyperic UI console, same way resources could be accessed programmatically using HQ Java API. Top most resource is Platform and beneath it are present services running which are allowed to be monitored in that machine. Let's see how to monitor different metrics at different levels using HQAPI.

More Stories By Akansha Jain

Akansha works as a Technology Analyst at SETLabs, R&D division, at Infosys Technologies Ltd. She has close to 4 years of experience in development of Cloud computing, Java and Java EE applications, Eclipse Plugin Architecture, Software Factory, Web 2.0,etc. Earlier publication works are available on devx.com.

@MicroservicesExpo Stories
Lacking the traditional fanfare associated with any technology that can use the word "container" or mention "Docker" in its press release, Ubuntu Core and its new Snappy system management scheme was introduced late last year. Since then, it's been gaining steam with Microsoft and Amazon and Google announcing support for the stripped-down version of the operating system. Ubuntu Core is what's being called a "micro-OS"; a stripped down, lean container-supporting machine that's becoming more pop...
This is a no-hype, pragmatic post about why I think you should consider architecting your next project the way SOA and/or microservices suggest. No matter if it’s a greenfield approach or if you’re in dire need of refactoring. Please note: considering still keeps open the option of not taking that approach. After reading this, you will have a better idea about whether building multiple small components instead of a single, large component makes sense for your project. This post assumes that you...
This digest provides an overview of good resources that are well worth reading. We’ll be updating this page as new content becomes available, so I suggest you bookmark it. Also, expect more digests to come on different topics that make all of our IT-hearts go boom!
The stack is the hack, Jack. That's my takeaway from several events I attended over the past few weeks in Silicon Valley and Southeast Asia. I listened to and participated in discussions about everything from large datacenter management (think Facebook Open Compute) to enterprise-level cyberfraud (at a seminar in Manila attended by the US State Dept. and Philippine National Police) to the world of entrepreneurial startups, app deployment, and mobility (in a series of meetups and talks in bot...
SYS-CON Events announced today the DevOps Foundation Certification Course, being held June ?, 2015, in conjunction with DevOps Summit and 16th Cloud Expo at the Javits Center in New York City, NY. This sixteen (16) hour course provides an introduction to DevOps – the cultural and professional movement that stresses communication, collaboration, integration and automation in order to improve the flow of work between software developers and IT operations professionals. Improved workflows will res...
I woke up this morning to the devastating news about the earthquake in Nepal. Sitting here in California that destruction is literally on the other side of the world but my mind immediately went to thinking about my good friend Jeremy Geelan. See Jeremy and his family have been living in Kathmandu for a while now. His wife, in fact, is the Danish Ambassador to Nepal!
SYS-CON Events announced today that B2Cloud, a provider of enterprise resource planning software, will exhibit at SYS-CON's 16th International Cloud Expo®, which will take place on June 9-11, 2015, at the Javits Center in New York City, NY. B2cloud develops the software you need. They have the ideal tools to help you work with your clients. B2Cloud’s main solutions include AGIS – ERP, CLOHC, AGIS – Invoice, and IZUM
Containers and microservices have become topics of intense interest throughout the cloud developer and enterprise IT communities. Accordingly, attendees at the upcoming 16th Cloud Expo at the Javits Center in New York June 9-11 will find fresh new content in a new track called PaaS | Containers & Microservices Containers are not being considered for the first time by the cloud community, but a current era of re-consideration has pushed them to the top of the cloud agenda. With the launch ...
There is no doubt that Big Data is here and getting bigger every day. Building a Big Data infrastructure today is no easy task. There are an enormous number of choices for database engines and technologies. To make things even more challenging, requirements are getting more sophisticated, and the standard paradigm of supporting historical analytics queries is often just one facet of what is needed. As Big Data growth continues, organizations are demanding real-time access to data, allowing immed...
The world's leading Cloud event, Cloud Expo has launched Microservices Journal on the SYS-CON.com portal, featuring over 19,000 original articles, news stories, features, and blog entries. DevOps Journal is focused on this critical enterprise IT topic in the world of cloud computing. Microservices Journal offers top articles, news stories, and blog posts from the world's well-known experts and guarantees better exposure for its authors than any other publication. Follow new article posts on T...
SYS-CON Events announced today that MangoApps will exhibit at SYS-CON's 16th International Cloud Expo®, which will take place on June 9-11, 2015, at the Javits Center in New York City, NY., and the 17th International Cloud Expo®, which will take place on November 3–5, 2015, at the Santa Clara Convention Center in Santa Clara, CA. MangoApps provides private all-in-one social intranets allowing workers to securely collaborate from anywhere in the world and from any device. Social, mobile, and eas...
One of the most frequently requested Rancher features, load balancers are used to distribute traffic between docker containers. Now Rancher users can configure, update and scale up an integrated load balancing service to meet their application needs, using either Rancher's UI or API. To implement our load balancing functionality we decided to use HAproxy, which is deployed as a contianer, and managed by the Rancher orchestration functionality. With Rancher's Load Balancing capability, users ...
There are 182 billion emails sent every day, generating a lot of data about how recipients and ISPs respond. Many marketers take a more-is-better approach to stats, preferring to have the ability to slice and dice their email lists based numerous arbitrary stats. However, fundamentally what really matters is whether or not sending an email to a particular recipient will generate value. Data Scientists can design high-level insights such as engagement prediction models and content clusters that a...
SYS-CON Events announced today the IoT Bootcamp – Jumpstart Your IoT Strategy, being held June 9–10, 2015, in conjunction with 16th Cloud Expo and Internet of @ThingsExpo at the Javits Center in New York City. This is your chance to jumpstart your IoT strategy. Combined with real-world scenarios and use cases, the IoT Bootcamp is not just based on presentations but includes hands-on demos and walkthroughs. We will introduce you to a variety of Do-It-Yourself IoT platforms including Arduino, Ras...
What’s hot in today’s cloud computing world? Containers are fast becoming a viable alternative to virtualization for the right use cases. But to understand why containers can be a better option, we need to first understand their origins. In basic terms, containers are application-centric environments that help isolate and run workloads far more efficiently than the traditional hypervisor technology found in commodity cloud Infrastructure as a Service. Modern operating systems (Linux, Windows, e...

As a company making software for Continuous Delivery and Devops at scale, at XebiaLabs we’re pretty much always in discussions with users about the benefits and challenges of new development styles, application architectures, and runtime platforms. Unsurprisingly, many of these discussions right now focus on microservices on the application side and containers and related frameworks […]

The post May. 3, 2015 10:00 AM EDT  Reads: 1,734

The cloud has transformed how we think about software quality. Instead of preventing failures, we must focus on automatic recovery from failure. In other words, resilience trumps traditional quality measures. Continuous delivery models further squeeze traditional notions of quality. Remember the venerable project management Iron Triangle? Among time, scope, and cost, you can only fix two or quality will suffer. Only in today's DevOps world, continuous testing, integration, and deployment upend...
Chuck Piluso will present a study of cloud adoption trends and the power and flexibility of IBM Power and Pureflex cloud solutions. Speaker Bio: Prior to Data Storage Corporation (DSC), Mr. Piluso founded North American Telecommunication Corporation, a facilities-based Competitive Local Exchange Carrier licensed by the Public Service Commission in 10 states, serving as the company's chairman and president from 1997 to 2000. Between 1990 and 1997, Mr. Piluso served as chairman & founder of ...
Financial services organizations were among the earliest enterprise adopters of cloud computing. The ability to leverage massive compute, storage and networking resources via RESTful APIs and automated tools like Chef and Puppet made it possible for their high-horsepower IT users to develop a whole new array of applications. Companies like Wells Fargo, Fidelity and BBVA are visible, vocal and engaged supporters of the OpenStack community, running production clouds for applications ranging from d...
To manage complex web services with lots of calls to the cloud, many businesses have invested in Application Performance Management (APM) and Network Performance Management (NPM) tools. Together APM and NPM tools are essential aids in improving a business's infrastructure required to support an effective web experience... but they are missing a critical component - Internet visibility. Internet connectivity has always played a role in customer access to web presence, but in the past few years u...