Answering my own question.
Selenium caches sessions in the -browserSessionReuse mode to reuse it again in the following tests, but they have a maximum session timeout before expiration in the BrowserSessionFactory class:
private static final long DEFAULT_CLEANUP_INTERVAL = 300000;
The constructor receives a parameter for cleaning, which defaults to TRUE.
public BrowserSessionFactory(BrowserLauncherFactory blf) { this(blf, DEFAULT_CLEANUP_INTERVAL, DEFAULT_MAX_IDLE_SESSION_TIME, true); }
AFAIK there is no way to change it with the Selenium parameter, the only way is to change the Selenium source code and compile it again. So what i do
source share