You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
switchted not to the old memory allocator for testing, as we should have not a high throughput
stick to the SelfSignedCertificate for now, as it is unclear how to use the new CertificateBuilder correct
💡 Additional Considerations
🔄 Types of changes
Cleanup (formatting, renaming)
Bug fix (backwards compatible)
New feature (non-breaking change which adds functionality and tests!)
Breaking change (fix or feature that would cause existing functionality to change)
PR Type
Enhancement
Description
Update Netty from 4.1.121.Final to 4.2.4.Final
Migrate to new MultiThreadIoEventLoopGroup API
Add required dependencies for Redis tests compatibility
Update Maven dependencies and build configurations
Diagram Walkthrough
flowchart LR
A["Netty 4.1.121"] --> B["Netty 4.2.4"]
B --> C["New Event Loop API"]
B --> D["Additional Dependencies"]
C --> E["MultiThreadIoEventLoopGroup"]
D --> F["Protobuf & Marshalling"]
Diagnose and resolve ConnectFailure for multiple ChromeDriver instances
Ensure stable multiple session creation without errors
Provide guidance or code/config changes
Requires further human verification:
⏱️ Estimated effort to review: 3 🔵🔵🔵⚪⚪
🧪 No relevant tests
🔒 Security concerns
Dependency changes: Adding netty-pkitesting and updating Netty introduce transitive crypto (BouncyCastle) changes. Ensure versions are pinned (conflict resolution shows bcprov-jdk18on to 1.81) and that pkitesting is not exposing test certificates or insecure defaults in production builds. No direct injection/XSS/secret exposure evident.
Switching to CertificateBuilder.buildSelfSigned() and using X509Bundle.toKeyManagerFactory() changes certificate/key material loading semantics. Ensure compatibility with the existing ServerOptions (e.g., cipher suites, protocols) and that client connections still succeed across JDKs and OSes.
Replacing NioEventLoopGroup with MultiThreadIoEventLoopGroup(NioIoHandler.newFactory()) may alter threading and performance characteristics. Validate shutdown hooks, thread naming, and compatibility with NioServerSocketChannel.
Adding io.netty:netty-pkitesting introduces a test/PKI helper at runtime scope. Confirm it is intended for production artifact and does not bloat runtime or pull unnecessary BouncyCastle versions.
Preserve hostname information in the self-signed certificate to avoid TLS validation issues for clients that perform hostname verification. Pass the configured hostname (or fallback) as a subject alternative name when building the certificate.
Why: The suggestion correctly identifies that not including the hostname in the self-signed certificate can lead to TLS validation failures, and proposes a valid fix using the available options object.
Switching to MultiThreadIoEventLoopGroup with NioIoHandler.newFactory() may change threading and channel behavior; validate server bootstrap compatibility and graceful shutdown, and ensure no resource leaks.
New Netty modules and hashes were added; ensure all referenced modules exist in repositories and align with the selected netty-bom to avoid resolution conflicts.
Migrating to MultiThreadIoEventLoopGroup with NioIoHandler.newFactory() changes threading and transport semantics; ensure all channel classes (e.g., NioServerSocketChannel) and pipeline handlers are compatible and that native transports or alternatives are not required in some environments. Also, adding protobuf/marshalling dependencies broadens the attack surface; confirm they are strictly scoped to tests or Redis modules and that shading or version alignment avoids conflicts with existing protobuf users in the repo.
Why: The suggestion correctly identifies major changes in the PR, raising valid concerns about the Netty API migration in NettyServer.java and the scope and security implications of new dependencies in build files.
Medium
General
Verify BOM-module alignment
Netty 4.2 splits codec modules; ensure transitive alignment by importing the matching BOM only if all new modules are resolvable. Verify that any modules removed from 4.1 (e.g., consolidated codecs) are not pinned elsewhere to prevent dependency resolution errors.
Why: This is a good, high-level verification check for a dependency version upgrade, ensuring that the new BOM aligns with all module changes, which is a valid concern in this PR.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
User description
🔗 Related Issues
💥 What does this PR do?
Update to netty 4.2.4, add the dependencies needed for redis tests to pass with the new netty version.
🔧 Implementation Notes
I did follow most of the migration guide at https://netty.io/wiki/netty-4.2-migration-guide.html, but:
memory allocator
for testing, as we should have not a high throughputSelfSignedCertificate
for now, as it is unclear how to use the newCertificateBuilder
correct💡 Additional Considerations
🔄 Types of changes
PR Type
Enhancement
Description
Update Netty from 4.1.121.Final to 4.2.4.Final
Migrate to new MultiThreadIoEventLoopGroup API
Add required dependencies for Redis tests compatibility
Update Maven dependencies and build configurations
Diagram Walkthrough
File Walkthrough
NettyServer.java
Migrate to Netty 4.2 event loop API
java/src/org/openqa/selenium/netty/server/NettyServer.java
MODULE.bazel
Update Netty BOM and add dependencies
MODULE.bazel
maven_install.json
Maven dependency resolution updates
java/maven_install.json
BUILD.bazel
Add Redis module dependencies
java/src/org/openqa/selenium/redis/BUILD.bazel