A monitoring and logging strategy for a "web service facade"?

I am working on "facase webservice" and I need to rethink part of it.

The context - my web service (let's call it "FacadeWebservice") is an internal web service designed to hide the complexity of other web services from my system:

  • My FacadeWebservice calls ExternalWebserviceA , ExternalWebserviceB and will need to call ExternalWebserviceC soon .
  • ExternalWebserviceA , ExternalWebserviceB and ExternalWebserviceC are external web services; they can be changed and downtime.

The complexity is getting higher and higher and I need to rethink how I control my FacadeWebservice and external web services. I need:

  • a complete view of the status of my application (number of calls, error codes sent)
  • a good idea of ​​what is happening with the external web services (eg the downtime of the external web services, the response codes received by my web service, eg one of these often goes "technical error / readonly" for some time).
  • basically a simple view / tool that shows general status.
  • service availability is pretty much covered (so I don't need applications like Nagios), I want to know what's going on at the application level.

I was thinking about using JMX in my FacadeWebservice - it might give me some disappointing graphs and statistics.

Is this the way? Or is a good logging strategy sufficient for the task (even if external changes are a big part of my problem)?

Any advice or experience on this matter?

+2


source to share


3 answers


This is a pretty tricky requirement, but you can try JavaMelody, http://javamelody.googlecode.com



  • "(number of calls, error codes sent)": yes, through the number of http calls and http errors
  • "External web services" statistics: yes, this can be done with JavaMelody via hooks if you are using EJB3 or Spring
  • JavaMelody performs application level monitoring and has "graphs and statistics": see screenshots
+2


source


The advantage of JMX is that you can run commands and query complex data.

The downside is that the standard console (which you combine with your Java version) is pretty limited. He can do anything, but nothing is very good.

My solution was to create a simple HTML page that shows this data. It has the following advantages:

  • I can easily format the data that I want to see that is most useful to me.

  • I can use any web browser to view (at home, internet cafe, mobile phone)



The main disadvantage is that it is not easy to display complex data (such as graphs and trends).

[EDIT] At the same time, JMX supports displaying graphs and trends, but it has no memory. So you get what happens from the moment you start the JMX console. If you need to be able to look back in time, you have to run the JMX console somewhere all the time.

In this case, it would be easier to add a graphics renderer to your "plain HTML page" where you can draw what you want.

+2


source


I don't know if this is an option, but it looks like you want some of the functionality that the ESB component offers:

  • Aggregating, composing and orchestrating web services
  • Monitoring (number of calls, operability of proxy web services, etc.)
  • Management console
  • etc.

Maybe you should check out something like ServiceMix that can be tracked through JMX (see Using the JMX Console with ServiceMix ):

alt text
(source: apache.org )

Or other commercial tools ( Mule ESB Enterprise , ALSB Oracle Service Bus ...).

+1


source







All Articles