Different servers do it different ways, and the error messages are particularly uninformative on some servers. Sorry, but I don't think that is being standardized. But, some servers are getting a lot better about this. I follow exactly what you are getting at reusing a servlet as a proxy. However, the question about how JSP and XML fit together in general is an important one.
Some people view XML as a source of data only.
There, servlets and JSP coexist perfectly with it. The servlets and JSP extract the data from the XML and format it. But if you view XML as a way of representing an entire document, then I think the jury is still out. In some cases you wouldn't need JSP at all with this view. But others think they should still work together even there.