MachinePublishers / jBrowserDriver

A programmable, embeddable web browser driver compatible with the Selenium WebDriver spec -- headless, WebKit-based, pure Java
Other
809 stars 143 forks source link

Difference between ajaxWait and ajaxResourceTimeout #358

Closed vrosu closed 3 months ago

vrosu commented 4 years ago

I've looked in the code, and searched through the internet, but I need to ask this. I do not really understand what ajaxResourceTimeout does. So, my usage is this: Settings.builder().requestHeaders(new RequestHeaders(map)).screen(dim).blockAds(false) .quickRender(false).ajaxWait(10000).hostnameVerification(false).ssl("trustanything").javaOptions("-Dprism.useFontConfig=false").build();

In this context, I understand that the get method will basically lock for 10 seconds+warmup time, and then will finish executing, returning content as it is etc. If I'm looking at ajaxResourceTimeout, with its standard value of two seconds, I would understand that in these 10 seconds, if an ajax call will take more than 2 seconds, it will be "ignored". Does that mean that the page will treat that ajax call like one with an empty response? I'm basically not sure what "ignored" means in the HTTP request/response world.

I apologize for this question - it might be under the wrong location. I'm open to sugestions on where I should move it.