Java News from Wednesday, May 12, 2004

Nobody knew of a service like the old postquery at that returned all the information posted (or gotten) by an HTML form, so I went ahead and wrote my own in PHP. Feel free to bang on it.

I'd like to expand on this a little. If anyone happens to know a way PHP can read the complete client request HTTP header or body without breaking it up into name-value pairs, please drop me a line. I could also use a way to retrieve arbitrary fields from the HTTP header by number, sort of like URLConnection.getHeaderField(int) or HttpServletRequest.getHeaderrNames() in Java. That is, I don't want to assume I know the names of the header fields in advance.

Update: I think what I need is $HTTP_RAW_POST_DATA. Nope, I spoke too soon. That doesn't work. Still looking. Hmm, OK maybe I need php://input? Yes, that seems to be it. This gives me the raw, unencoded body of the request. I still need to figure out how to get all the headers though.

Robert Oloffson has posted version 0.42 of Java Memory Profiler (JMP). JMP uses the Java Virtual Machine Profiling Interface (JVMPI) interface to track objects and method times in a JVM. It uses a GTK+ interface to display statistics. The current instance count and the total amount of memory for each class is shown as is the total time spent in each method. This release adds popup menus to various tables and lists for easier navigation between the objects owned by an instance and the owner of the instance. JMP is written in C for Linux.