I am writing some code that involves the use of embedded Jetty 9 (Jetty as a POJO). To start with, I was doing some basic testing with a handler that would print a message to the console and then do a Thread.sleep(10000). The idea was to get it sleep long enough for me to kick off a bunch of requests (web browser tabs to start, eventually graduating to a curl script) to see how well Jetty 9 handled simultaneous requests.
No matter what I seemed to do, I could not get my code to respond to simultaneous requests. The requests always seemed to pass through serially. To make things worse, I just happened to be doing this development on a Windows 7 machine - which makes it pretty much impossible to sniff traffic on the localhost interface (yes, I know there are some possible ways to do that, but they are unreliable). So I was working in the blind and nothing seemed to be working...
Finally I managed to find the answer here. The problem was not my code, it was the Chrome Browser. Apparently you cannot open the same URL on multiple tabs at the same time. I fired up Firefox (pun intended) and everything worked like a champ.
So ah... What is the deal Google?
No comments:
Post a Comment