Making a cross site request to a service returning back XML
I have a legacy middleware application that returns back XML. It has lots of methods and is doing well in a stable production environment. I would like my GWT app (running on a different domain) to consume this data with minimal changes to the middleware. The way I see it I have these 2 options 1. Modify my middleware to return back JSONP instead of XML with an optional argument for return type. 2. Proxy calls to the middleware through a GWT servlet #1 would mean a change to every remote method call into equivalent JSONP. #2 would mean an additional hop -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Making a cross site request to a service returning back XML
My question was, Is there an option #3 ? On Feb 25, 11:28 am, ialexei iale...@gmail.com wrote: I have a legacy middleware application that returns back XML. It has lots of methods and is doing well in a stable production environment. I would like my GWT app (running on a different domain) to consume this data with minimal changes to the middleware. The way I see it I have these 2 options 1. Modify my middleware to return back JSONP instead of XML with an optional argument for return type. 2. Proxy calls to the middleware through a GWT servlet #1 would mean a change to every remote method call into equivalent JSONP. #2 would mean an additional hop -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: Making a cross site request to a service returning back XML
On Fri, Feb 25, 2011 at 9:28 AM, ialexei iale...@gmail.com wrote: I have a legacy middleware application that returns back XML. It has lots of methods and is doing well in a stable production environment. I would like my GWT app (running on a different domain) to consume this data with minimal changes to the middleware. The way I see it I have these 2 options 1. Modify my middleware to return back JSONP instead of XML with an optional argument for return type. 2. Proxy calls to the middleware through a GWT servlet #1 would mean a change to every remote method call into equivalent JSONP. #2 would mean an additional hop GWT is Javascript executing in a browser context. Just as, for example, Firefox can download and render an XML file, so too can your app. I don't know the mechanics of the request, but it sounds like it's a CGI contract (as opposed to Java RPC): your middleware app will set the response MIME type to text/XML, your response handler will receive the response, if the status is HTTP 200, it will parse the response via the browser. You then navigate the resulting DOM tree and extract the relevant tags/attributes/content. hth, jec -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.