Take out the XML generation prior to the request cycle