[ libXmlRequest SPEC-1.5.1.0909.2005 | whitefrost.com | Stephen W. Cote ]
Refer to the reference implementation libXmlRequest SPEC-1.5.1.0909.2005 and the Engine for Web Applications project.
This example is a stress test for the pooling and caching features. Both features are enabled in the default configuration. The configured pool size is five (5), and the configured maximum pool size is ten (10). By default, this test attempts fifteen (15) asynchronous requests at one time.
When the pooling feature is enabled, the test should fail for the eleventh request. Because an alert is raised, thus blocking the process, additional requests may or may not fail. When caching and pooling are enabled, the test should be completely successful for subsequent attempts because the first ten requests were cached. If caching is disabled, then the last five requests should never be successful, unless the attempts are blocked (eg: raising an alert). When pooling is disabled, all requests should be successful.
Another part of this test is to verify that there are no errors in the client's XmlHttpRequest agent. For example, various versions of MSXML have differences in how the readystatechange event works, and various versions of Mozilla have differences in how the load event is handled.
One additional test is to toggle whether the same document request is made for the previous tests. If the same document id is used for asynchronous requests, a race condition in the cache is created because the first cached request may not have completed. The purpose of this test is to make sure that the race condition is corrected.
Pooling Enabled: Caching Enabled: Async Request: Same Document: