From 400e3f341b0f3c557564305fb0234873e82e5e51 Mon Sep 17 00:00:00 2001 From: Mohammad Saddam Hossain Date: Thu, 23 Jul 2026 09:42:06 +0530 Subject: [PATCH] docs: fix invalid config keys and missing timeouts in parallel guide MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Two copy-paste defects in guides/parallel.md, found while drafting the P1-5 SEO article and confirmed against SeleniumBootConfig / ConfigurationLoader in 3.2.0: - The guide documented a top-level `parallel: {enabled, threadCount}` block and `browser.maxActiveSessions`. Neither exists — all three keys live under `execution:` (SeleniumBootConfig.Execution: parallel, threadCount, maxActiveSessions). ConfigurationLoader uses a default SnakeYAML Constructor, which throws on unknown top-level properties, so copy-pasting the old sample aborted the suite immediately with a YAMLException. configuration.md already had the correct structure; used as reference. - Every YAML sample in the guide omitted the required `timeouts:` block. ConfigurationLoader.validate() requires timeouts.explicit and timeouts.pageLoad as positive primitives (absent = 0), so even a key-corrected sample still aborted with "Selenium Boot failed to initialize". Same defect as the one fixed in the README under P1-6a (860d4d2) — matched that fix's shape (complete, loadable minimal config). Verified against real Maven Central 3.2.0 + ConfigurationLoader: - Old documented sample: YAMLException, "Unable to find property 'parallel' on class SeleniumBootConfig", exit 1. - Corrected sample (both the "Configuration" and "Disabling parallel execution" snippets): loads cleanly, exit 0, execution.parallel/ threadCount/maxActiveSessions and timeouts.explicit/pageLoad all read back as configured. Grepped the rest of docs-site/ and README/CHANGELOG for the same two patterns (top-level `parallel:`, `maxActiveSessions` outside `execution:`, YAML samples with no `timeouts:`) — no other current-doc instances found. Two historical changelog entries (CHANGELOG.md, docs-site/docs/changelog.md) describe the 0.3.0-era schema and were left untouched as historical record. Co-Authored-By: Claude Opus 4.8 (1M context) --- docs-site/docs/guides/parallel.md | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/docs-site/docs/guides/parallel.md b/docs-site/docs/guides/parallel.md index 4437354..bddf3f5 100644 --- a/docs-site/docs/guides/parallel.md +++ b/docs-site/docs/guides/parallel.md @@ -15,14 +15,22 @@ Selenium Boot supports parallel test execution out of the box. Configure the thr ## Configuration ```yaml title="selenium-boot.yml" -parallel: - enabled: true - threadCount: 4 # number of concurrent browser sessions +execution: + mode: local + parallel: methods # none (default) | methods | classes | tests + threadCount: 4 # number of concurrent browser sessions + maxActiveSessions: 4 # semaphore cap — cannot exceed threadCount browser: - maxActiveSessions: 4 # semaphore cap — cannot exceed threadCount + name: chrome + +timeouts: + explicit: 10 + pageLoad: 30 ``` +`parallel`, `threadCount` and `maxActiveSessions` all live under `execution:` — see the [Configuration Reference](/docs/configuration#execution). `timeouts.explicit` and `timeouts.pageLoad` are required by every `selenium-boot.yml`, parallel or not. + `maxActiveSessions` acts as a hard ceiling on concurrent browsers. If `threadCount` is 4 but `maxActiveSessions` is 2, at most 2 browsers will run at the same time. --- @@ -137,8 +145,8 @@ TestNG creates a new instance of each test class per thread, so instance fields ## Disabling parallel execution ```yaml -parallel: - enabled: false +execution: + parallel: none ``` -Or simply omit the `parallel` block — sequential execution is the default. +Or simply omit `execution.parallel` — `none` (sequential execution) is the default.