We are using a pub/sub model to insert the records in a database. if DB is down is for a min, then the wM’s trigger is going to be suspended. So i want to add a ping DB service in resource monitoring service.
Could you please help me on how to implement the pingDB service in resource monitoring service to check if DB is up&running or not.
A ping will only check if the VM (i.e., machine) is up, but not the database application.
You can write an adapter service that performs a “select * from DUAL” query for Oracle, or any other simple equivalent query in other databases. Wrap this in a flow service that follows the Resource Monitoring principles/specification, et voila, you are done.
Resource Monitoring requirements are documented in the Publish Subscribe Developers Guide (link).