When I use the “Start WebDriver” or “Get Pooled WebDriver” node somewhere in my workflow to launch a browser and do not quit it (after finishing the job), I cannot use a “Get Pooled WebDriver” node to use the same (idle) browser which is still open and it always launch a new browser (sharing the same webdriver factory node didn’t make any change). (That’s not my main issue but I’ll be glad to be guided)
When I start a webdriver with “Start WebDriver”, I can quit it using “Quit WebDriver” node but I cannot quit the one started with “Get Pooled WebDriver”. How can I quit this one?
as far as I understood from your message, this is exactly how the idea of the WebDriver pooling is supposed to work:
When you use Get Pooled WebDriver, the node will create a new browser instance, in case there’s non in the pool
To put back a browser into the pool (so that it can be reused), you need to use the Quit WebDriver node. Browsers which were created by the Get Pooled WebDriver, will not close when running the Quit node, but instead remain open so that they can be re-used again.
In this case, when you re-run any Get Pooled WebDriver which requests exactly the same WebDriver configuration (as configured by the WebDriver Factory), you will receive one of the already open browsers.
The only way to quit browsers which were created by the Get Pooled WebDriver node is to quit KNIME.
Additional info: The Get Pooled WebDriver will perform a health check before handing out a pooled browser. This means, that if a browser has crashed or does not react, it should be detected, and a new browser instance will be created.
Hope that helps to clear up any confusion. In case you still have issues or doubts, please let me know.
Now I got it. Your answer is exactly what I needed. The point was that I thought the Quit node is not required after Pooled webdriver node so I couldn’t reuse the browser except when using it in a loop. Now everything works great.