Diagnosing a Problem

If you run into a problem, here are a couple things that might help in trying to narrow it down:

Reporting Bugs

If you run into a problem, bug, have questions, suggestions, or comments, please first check the FAQ and the rest of the docs. If that doesn't answer your question, then feel free to send me an email.

When submitting a bug report or other problem report, make sure you supply the following information (some of it can be skipped if you know it's not relevant):

  1. Which version of the HTTPClient you're using. This can be found in any source file at the very top and in all the javadocs. Additionally, the version is sent as part of the User-Agent header, so a network trace will also reveal what version is running.
  2. If you get an exception, then please provide the full stack trace, exactly as printed out. Note that its often important to see the exact error message - something along the lines of "I got an IOException" is almost useless. Also make sure that the JIT is disabled if you're using one so that the stack trace contains line numbers (if you're using jdk 1.3 with HotSpot then you'll always get line numbers).
  3. The full jdk version ("jdk -fullversion") and platform. While java does run well anywhere, there are broken JVM's out there, and some of the exception messages can be platform dependent.
  4. If this error occurs trying to send a request to a particular site, please provide at least the URL for that site. Also, if the problem occurs doing anything more than a simple GET (e.g. doing a POST with certain data), please try to provide a complete code sample. The easier it is for me to reproduce, the quicker I can give you a fix (or tell you where the problem is). For simple GETs the URL is enough, though.

    If the URL is internal (i.e. not accessable from the internet), then please turn on the debug logging and send me the output.

  5. If the application seems to hang, or seems to spend a lot of time somewhere, then get a thread dump (see above).
  6. If you are having trouble getting your code to work, then show me that code (or at least the relevant parts of it). Trying to guess at what it looks like can be somewhat tricky...

In general, the more info you can provide up front the quicker I can deal with it. I tend to be pretty busy, and therefore tend to sort and answer mail according to how quickly I can provide an answer.


[HTTPClient]
Ronald Tschalär / 6. May 2001 / ronald@innovation.ch.