Selenium grid is widely used in lots of companies and projects. Unfortunately with the current open source implementation one can not run more than one hub which can cause various problems due to hardware or network instability. Single hub architecture is also hardly scalable, at least it requires hardware upgrades for the hub.
At the same time many teams implement their own internal solutions which are usually not shared because of the team/organization specific or custom selenium hacks.
In Yandex we have multi hub solution for more than 5 years. At the same time we are doing our best to avoid making custom internal patches to selenium.
During these years we were using client side balancing approach: client applications were always obtaining a browser via a special internal library. It knew the configuration of all the hubs and browsers and was performing the search for an available node on request.
But when it came to the different test frameworks, different languages and different runtimes this approach became difficult to support. As long as test practices move from test engineers to development teams the diversity of frameworks and runtimes increases. So we come up with meta hub solution.
Our meta hub solution has the following basis:
- Stock versions of selenium and selenium grid
- Stock web driver interface for the client
- Virtual infrastructure. We use Openstack for all parts of our infrastructure. It’s not necessary but It makes sense.
- Fixed load for each hub and node – scalability via adding new hubs with fixed volume.
- Redundancy and scalability
- Stateless solution for meta hub. No storage requires to keep state between several meta hub nodes
We made solution that includes:
- Proxy software between client and multi-hub grid installation
- Some configuration adjustments for hubs/nodes.
I'll talk about our solution. We going to go open source on the SeleniumConf conference or earlier.