Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

There is no way to provide max-sessions parameter in the docker section of the standalone config file #9660

Closed
gpt14 opened this issue Jul 18, 2021 · 2 comments · Fixed by #9688
Labels

Comments

@gpt14
Copy link
Contributor

gpt14 commented Jul 18, 2021

🐛 Bug Report

There is no way to provide max-sessions parameter in the docker section of the standalone config file

To Reproduce

My grid config looks as follows. Is there a way to limit the number of sessions available for both Firefox and Chrome in the docker section of standalone config file

[node]
detect-drivers = false
max-sessions=4

[docker]
configs = ["selenium/standalone-chrome:latest", "{\"browserName\": \"chrome\", \"browserVersion\": \"91\"}", "selenium/standalone-firefox:latest", "{\"browserName\": \"firefox\", \"browserVersion\": \"89\"}"]
host = "localhost"
port = 2375
url = "unix:/var/run/docker.sock"
video-image = "selenium/video:latest"

Running this command java -jar selenium-server-4.0.0-beta-4.jar standalone --config grid.config.toml creates 12 sessions each of Chrome and Firefox with a max concurrency of 4

image

In the file

int maxContainerCount = Runtime.getRuntime().availableProcessors();

we have initialised it to the # of availableProcessors

whereas in the file

config.getInt("node", "max-concurrent-sessions").orElse(Runtime.getRuntime().availableProcessors()),

we take into consideration the value available in the node section of the config file

Expected behavior

There should be a config to set max-sessions in the docker section

Test script or set of commands reproducing this issue

Environment

Selenium Grid version (if applicable): selenium-server-4.0.0-beta-4

@diemol
Copy link
Member

diemol commented Jul 28, 2021

Just for context, the improvement in the PR will allow to set a max-sessions which can be up to the number of available processors. It won't be possible to go over that number for now. This comment explains that.

@github-actions
Copy link

github-actions bot commented Sep 5, 2021

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked and limited conversation to collaborators Sep 5, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants