Could you explain your use case? What would such plugin do? In what way do you want to integrate selenium?
I want to have selenium test suite running (ex: every 10 minutes) locally in the agent for each deployed webapp. I want to have an RHQ "business indicator" indicating not only that the webapp is deployed but that the webapp is functional.
The selenium test suite can be : 1. Login in the webapp 2. I'm on the welcome page => ok 3. I search for a ticket 4. I found ticket. => ok.
=> In Rhq, seleniumTestSuite = UP // metric totalTimeScenario = 10 seconds.
But there is maybe another way to have this indicator for each deployed webapp ?
You could write your own plugin to start the suite (I'm not aware of a similar plugin in the community). The key problem is how you will connect Selenium to a browser on a production, headless machine. You could use PhantomJS.
Honestly, if it was me I'd send simple, fabricated HTTP requests from the RHQ plugin to the application. Much easier to implement and does the job.
Another option might be using Script Server resource, but you'd be missing totalTimeScenario metric. You can create a bundle that would contain some script which can start testsuites (you can either package your tests within bundle, or let the script check them out from SCM). Script Server resource can be used to run your script using scheduled operation, you can then setup an alert definition in case the operation fails (you can match script output using regular expression to determine success/failure).
It seems to be a pretty solution ! Thank you Thomas and Libor !