I got this email from a strong Java developer I know for years. He wrote, “Today was the first time in my life when I hung up during the phone Java job interview “.
I asked him why. He replied and I just cut and pasted his email below without changing a word. The sad part is that it was an interview with one of the most reputable Wall Street companies. See for yourself.
The guy asked me how did we do timeout on URLConnection. I said that we simply sent a ping once a second and if we did not receive a ping we considered the connection dead. the guy asked me how did we do timeout on URLConnection. I said that we were sending a ping once a second, and if we did not receive a ping back the connection was considered dead. We’d notified the user and blah, blah, blah.
The guy said, “You should specify the timeout on URLConnection”, and asked how did we do it. I said that we did not specify timeout in URLConnection, that I am not sure there is a way to do it since in Java originally all IO was blocked.
The guy asked me how did we do timeout on URLConnection. I checked the internet to make sure, I said that we did the timeout on the software level, that I am not aware of any other way to do it and that in the very end I am really telling him how the system worked and if he can give me a hint to what he wants I ‘ll be glad to answer.
The guy asked me how did we do timeout on URLConnection. I am not joking, again. I said – we did it using ping message if we did not receive the ping within 2 secs we considered the connection dead.
The guy asked me how did we do timeout on URLConnection. I hung up.
I guess, the interviewer went by someone’s list of questions and answers – he was expecting the answer “Just close the underlying I/O stream and the connection will be timed out “. His list of possible did not icnlude the ping alternative…
Lots of morons are working everywhere, including Wall Street, and your future is in their hands. Would you hang up?