Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I get my Selenium Grid Hub log

I have a selenium grid2 set up on an AWS instance, and I was wondering if there's a way I could view the logs on my local machine?

I understand I can visit: http://MyServerAddress/grid/console and view all of the nodes but I want the actual log. Its a bit of a pain having to remote desktop to the server each time I want to view it.

I was thinking something like http://MyServerAddress/grid/log but alas, it doesnt seem to be an option.

like image 801
Festivejelly Avatar asked Feb 05 '23 07:02

Festivejelly


1 Answers

There's nothing available out of the box. But you can build this on your own.

  • You would first need to enable logging for your Grid and have the logs dumped to a specific folder.
  • You would now need to build a custom Servlet and inject it into the servlet (See here for details on how to do it )
  • Assuming that your servlet is called "HubLogServlet", you should be able to access it via the link http://localhost:4444/grid/admin/HubLogServlet

You can refer to this LogServlet for a sample.

like image 108
Krishnan Mahadevan Avatar answered May 16 '23 07:05

Krishnan Mahadevan