Re: GWT HTTP RequestBuilder
Thanks Thomas and jens for your help
i am planning to use CORS for time being. later i will use reverse
proxy approach.
Regards
kumar
On Nov 14, 12:24 am, Thomas Broyer <t.bro...@gmail.com> wrote:
> On Sunday, November 13, 2011 7:59:38 PM UTC+1, karun wrote:
>
> > Hi Jens
>
> > Yes i am sure, i got response code as 200 and the jsp from J2EE server
> > is also getting displayed,
>
> > sorry for typo my application is in server 2 and J2EE application is
> > in server 1.
>
> > to overcome SOP only, we have setup the 2 servers in above format. so
> > that domain name and port are same, both servers end with
>
> > 1. example.com
>
> > 2. and also both servers have same port no. 8111
>
> That's not enough: factory-dev03.example.com is different from
> factory-dev109.example.com, so they're different origins.
>
> > when i went through the sop policy in gwt documentation,
>
> Seehttp://en.wikipedia.org/wiki/Same_origin_policy, andhttp://www.schemehostport.com/2011/10/foundations-origin.html
>
>
>
>
>
> > i came across
> > below way of loading images and javascript files from different
> > server. which i felt is similiar to our setup.
>
> > part of documentation is pasted below:
>
> > "However, many organizations setup their deployment platform in such a
> > way that their main host HTML page is served up fromhttp://mydomain.com/,
>
> > but any other resources such as images and JavaScript files are served
> > up from a separate static server underhttp://static.mydomain.com/. In
> > older versions of GWT, this configuration would not be possible as the
> > SOP prevented the GWT bootstrap process from allowing script from
> > files that were added from a different server to access the iframe in
> > the main host HTML page. As of GWT 1.5, the bootstrap model now
> > provides support for this kind of server configuration via the cross-
> > site linker (xs-linker).
>
> > When using the cross-site linker the compiler will still generate a
> > <module>.nocache.js that you will want to reference within your
> > index.html. The difference though, is that the <module>.nocache.js
> > produced by the cross-site linker will link in a cache.js file for
> > each of your permutations rather than a cache.html file.
>
> > To enable the cross-site linking simply add the following to your
> > <module>.gwt.xml and include a reference to your <module>.nocache.js
> > in your index.html as you normally would.
>
> > <add-linker name="xs"/>
> > "
> > according to this doesn't our setup overcome SOP.
>
> That's only about serving the GWT files from another server, it doesn't
> change anything about RPC/RequestFactory/RequestBuilder: they have to be
> issued by the same origin (your HTML host page) as the one they try to
> reach (or they can use CORS in non-IE browsers).
> In other words, the URL you see in your browser should be factory-dev109 if
> your servlets are on that server; you can serve the *.nocache.js and
> associated *.cache.* files from the factory-dev03 server.
>
> Also, note that the "xs" linker is being deprecated in favor of the
> "xsiframe" linker.- Hide quoted text -
>
> - Show quoted text -- Hide quoted text -
>
> - Show quoted text -
--
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+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home