Hi Eric,

I deployed the gadgetRPC sample in tomcat and then tried to call it
from orkut but I got the following output (Server properties were not
retreived):

RPC to: 
http://www.orkut.gmodules.com/gadgets/proxy?refresh=3600&gadget=http%3A%2F%2F<my
hosting service>%2FtestOS
%2Fcom.google.gwt.gadgets.sample.gadgetrpc.client.GadgetRPC.gadget.xml&container=orkut&url=http
%3A%2F%2F<my hosting service>%2FtestOS%2FGadgetRPC
Server Start Time: <not retrieved>
Server Current Time: <not retrieved>

When I click the 'Call RPC method' button following exception is being
thrown :
com.google.gwt.user.client.rpc.InvocationException: Unable to initiate
the asynchronous service invocation -- check the network connection

The 'HelloGadgets' sample is working fine but there isn't any server
side code in it....so how can I tell whether it has solved the SOP
problem or not ?

Regards
Yasser Sultan


On Jan 13, 6:00 pm, Eric Ayers <[email protected]> wrote:
> There are 2 samples included in the gwt-gadgets.jar file that use network
> requests: one is "HelloGadgets" and the other is called "GadgetRPC".
>
> I am sorry but I confused a few issues in the last post.  Does the 'GET
> Cached' example of the HelloGadgets sample work for you?  If so, then you've
> gotten around the SOP!  The POST option of HelloGadgets is strange in that
> it fetches a file on the filesystem of the server with doPost().   That is
> the one that may require you to delegate doPost() to doGet().
>
> Assuming your servlet container is Jetty, the request looks like it is
> getting all the way to your Jetty server and then your server is rejecting
> it.  Are you sure your web.xml is configured correctly?  Look in the jetty
> debug log and make sure the servelt is loading correctly.  One common
> problem is that gwt-servlet.jar isn't copied into your web.xml.
>
> -Eric.
>
> On Tue, Jan 13, 2009 at 7:28 AM, falcon_whiz <[email protected]>wrote:
>
>
>
>
>
>
>
> > Hi Eric,
> >  I was using the same servlets as provided in the GadgetRPC sample.
> >  Moreover I checked on the web today steps for deploying a GWT
> > application in an opensocial container. I have created some opensocial
> > applications earlier but they were written in pure javascript on the
> > client side, this is the first time that I have used GWT. The problem
> > is that the application is complete and I have used RPC for client
> > server communication. Now I found that due to SOP I can't make RPC
> > calls from gadget containers. so to use opensocial makerequest methods
> > I will have to re-implement the communication in JSON, that will be
> > waste of time and money. :(
> > So can you please check out with the opensocial guys that whether RPC
> > is possible inside an opensocial container or not...?
>
> > Regards
> > Yasser Sultan
>
> > On Jan 13, 3:13 pm, Eric Ayers <[email protected]> wrote:
> > > The problem is that the Gadget RPC is weird for the POST situation.  To
> > > resolve this, add a doPost() method in your servlet that delegates to
> > > doGet().
>
> > > On Tue, Jan 13, 2009 at 12:10 AM, falcon_whiz <[email protected]
> > >wrote:
>
> > > > Hi Eric,
> > > >  I tried the GadgetRPC sample but its returning with the following
> > > > exception :
>
> > > > com.google.gwt.user.client.rpc.StatusCodeException: <html> <head>
> > > > <meta http-equiv="Content-Type" content="text/html;
> > > > charset=ISO-8859-1"/> <title>Error 405 HTTP method POST is not
> > > > supported by this URL</title> </head> <body><h2>HTTP ERROR: 405</
> > > > h2><pre>HTTP method POST is not supported by this URL</pre>
> > > > <p>RequestURI=/gadgets/proxy</p><p><i><small><a href="http://
> > > > jetty.mortbay.org/">Powered by Jetty://</a></small></i></p><br/> <br/>
> > > > <br/> <br/> <br/> <br/> <br/> <br/> <br/> <br/> <br/> <br/> <br/> <br/
> > > > > <br/> <br/> <br/> <br/> <br/> <br/> </body> </html>
>
> > > > I tried to deploy the application in igoogle and then in Shindig
> > > > server present on my machine but the result is same...
> > > > Can you please tell me whether I am doing something wrong during
> > > > deployment ??
>
> > > > On Jan 12, 6:32 pm, Eric Ayers <[email protected]> wrote:
> > > > > I've not done it with opensocial containers, but there is a trick in
> > the
> > > > > GadgetRPC sample that should help.  You will need to get the proxy
> > URL
> > > > for
> > > > > your RPC using the method:
>
> > > > >  gadgets.io.getProxyUrl()<
> > > >http://code.google.com/apis/gadgets/docs/reference/#gadgets.io.getPro..
> > .>
>
> > > > > The GadgetRPC sample is included in the download under the 'samples'
> > > > > directory.
>
> > > > > Note that  gwt-gadgets-1.0.1 does not support the opensocial 0.8 spec
> > (is
> > > > > that what you are using?) , only the legacy API.  I don't know that
> > the
> > > > > generated gadget.xml file is going to work for you without
> > modification.
>
> > > > > On Mon, Jan 12, 2009 at 1:56 AM, falcon_whiz <
> > [email protected]
> > > > >wrote:
>
> > > > > > Hi,
> > > > > >  I have created an application using GWT and now I want to deploy
> > > > > > this app in opensocial containers. The problem is how do I use the
> > > > > > RPC's they are not working at the moment. Through Firebug I found
> > that
> > > > > > no request is being sent to the servlets. I am also using gwt-
> > > > > > gadgets-1.0.1 api to generate the required xml file.
>
> > > > > --
> > > > > Eric Z. Ayers - GWT Team - Atlanta, GA USAhttp://
> > > > code.google.com/webtoolkit/
>
> > > --
> > > Eric Z. Ayers - GWT Team - Atlanta, GA USAhttp://
> > code.google.com/webtoolkit/
>
> --
> Eric Z. Ayers - GWT Team - Atlanta, GA USAhttp://code.google.com/webtoolkit/- 
> 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 [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to