Feature and motivation
Overview
EdgeDriverService in Selenium Java binding has six properties; webdriver.edge.driver, webdriver.edge.logfile, webdriver.edge.verboseLogging, webdriver.edge.silentOutput, webdriver.edge.withAllowedIps, and webdriver.edge.disableBuildCheck. These options are very helpful in operating Edge server nodes.
https://github.com/hgsgtk/selenium/blob/036ee7f6aec797f5fe4608d2f7673e59d7f548b5/java/src/org/openqa/selenium/edge/EdgeDriverService.java#L46
One feature I feel missing is that there are no APIs to customize the log level.
Current possible solutions
For example, when I want to set the log-level=INFO, I have only one option, to set the --log-level option to msedgedriver directly.
$ ./msedgedriver --log-level=INFO
However, this way has some drawbacks.
First, it requires us a complex flow which combines with the system property webdriver.edge.driver and some wrapped scripts.
For example: set a wrapper batch file to the webdriver.edge.driver property.
java -Dwebdriver.edge.driver=edgedriver_wrapper.bat
And then, a wrapped batch file execute msedgedriver with the --log-level option.
C:\path\msedgedriver.exe --log-level $args
Another drawback is that command option settings must be written in multiple places. I understand that it doesn't make sense to support ALL options (e.g. an experimental option --replayable). But I believe the --log-level is commonly helpful, as is the --verbose option.
In addition, the property webdriver.edge.verboseLogging is not a perfect solution because it indicates to set the option --verbose option (equivalent to --log-level=ALL).
Usage example
We can use the new system property like this:
System.setProperty("webdriver.edge.loglevel", "INFO");
EdgeDriverService service = EdgeDriverService.createDefaultService();
EdgeDriver driver = new EdgeDriver(service);
Feature and motivation
Overview
EdgeDriverService in Selenium Java binding has six properties;
webdriver.edge.driver,webdriver.edge.logfile,webdriver.edge.verboseLogging,webdriver.edge.silentOutput,webdriver.edge.withAllowedIps, andwebdriver.edge.disableBuildCheck. These options are very helpful in operating Edge server nodes.https://github.com/hgsgtk/selenium/blob/036ee7f6aec797f5fe4608d2f7673e59d7f548b5/java/src/org/openqa/selenium/edge/EdgeDriverService.java#L46
One feature I feel missing is that there are no APIs to customize the log level.
Current possible solutions
For example, when I want to set the log-level=INFO, I have only one option, to set the --log-level option to msedgedriver directly.
However, this way has some drawbacks.
First, it requires us a complex flow which combines with the system property
webdriver.edge.driverand some wrapped scripts.For example: set a wrapper batch file to the webdriver.edge.driver property.
And then, a wrapped batch file execute msedgedriver with the --log-level option.
Another drawback is that command option settings must be written in multiple places. I understand that it doesn't make sense to support ALL options (e.g. an experimental option --replayable). But I believe the --log-level is commonly helpful, as is the --verbose option.
In addition, the property
webdriver.edge.verboseLoggingis not a perfect solution because it indicates to set the option--verboseoption (equivalent to --log-level=ALL).Usage example
We can use the new system property like this: