From 656ed8952c7f6a1211daf8e4fbfd28e1661730e1 Mon Sep 17 00:00:00 2001 From: Valery Yatsynovich Date: Fri, 10 Mar 2023 23:15:12 +0300 Subject: [PATCH] [plugin-web-app] Add workaround for Chrome 111 (#3708) Root cause is the changes in Chrome behavior: https://bugs.chromium.org/p/chromium/issues/detail?id=1422444 Discussion: https://groups.google.com/g/chromedriver-users/c/xL5-13_qGaA?pli=1 Selenium issue: https://github.com/SeleniumHQ/selenium/issues/11750 Solution details: following Selenium team recommendation and switching to JDK 11 Http client for Selenium --- vividus-plugin-web-app/build.gradle | 1 + .../main/resources/properties/profile/web/profile.properties | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/vividus-plugin-web-app/build.gradle b/vividus-plugin-web-app/build.gradle index 99fe99cabf..e07b0fc379 100644 --- a/vividus-plugin-web-app/build.gradle +++ b/vividus-plugin-web-app/build.gradle @@ -17,6 +17,7 @@ dependencies { implementation(group: 'org.seleniumhq.selenium', name: 'selenium-firefox-driver') implementation(group: 'org.seleniumhq.selenium', name: 'selenium-ie-driver') implementation(group: 'org.seleniumhq.selenium', name: 'selenium-safari-driver') + implementation(group: 'org.seleniumhq.selenium', name: 'selenium-http-jdk-client') implementation(group: 'junit', name: 'junit', version: '4.13.2') implementation(group: 'io.github.bonigarcia', name: 'webdrivermanager', version: '5.3.2') { exclude group: 'com.github.docker-java' diff --git a/vividus-plugin-web-app/src/main/resources/properties/profile/web/profile.properties b/vividus-plugin-web-app/src/main/resources/properties/profile/web/profile.properties index e445fc697f..6ddae9d08d 100644 --- a/vividus-plugin-web-app/src/main/resources/properties/profile/web/profile.properties +++ b/vividus-plugin-web-app/src/main/resources/properties/profile/web/profile.properties @@ -43,3 +43,7 @@ selenium.screenshot.full-page=true selenium.screenshot.indent=300 # highlighter types: DEFAULT, BLUR, MONOCHROME selenium.screenshot.highlighter=DEFAULT + +# https://www.selenium.dev/blog/2022/using-java11-httpclient/#integrating-the-java-11-client +# Reason: https://github.com/SeleniumHQ/selenium/issues/11750 +system.webdriver.http.factory=jdk-http-client