On Feb 11, 2:45 am, dougx <[email protected]> wrote:
> Yup; just remember that when you're compiling using the xs linker
> you're not in a local iframe anymore; your own server is cross domain
> now, so you'll have to use an XSS proxy to make RPC calls (or
> makeRequest()).

That I don't understand. I can do simple GETs on whatever server I
want. The only thing I can't do is POSTs, PUTs and DELETEs but that is
not needed. You can just use JSONP to call your webservices. (Of
course they have to be set up to accept that).

Also: is gwt-gadgets using the xs linker or how does it work? Because
I am already using a ClientBundles with it and that works pretty
good :)

Cheers, Jonas

>
> ~
> D.
>
> On Feb 11, 6:28 pm, Kayode Odeyemi <[email protected]> wrote:
>
> > Ok. I get it now. Now digging in...
>
> > On Thu, Feb 11, 2010 at 10:10 AM, Kayode Odeyemi <[email protected]> wrote:
> > > I really want to explore the approach you took Doug(i.e the GWT only
> > > approach). But my question is how do you include the module file and the
> > > JSNI implementation in the Wave gadget
>
> > > On Thu, Feb 11, 2010 at 6:37 AM, Jonas Huckestein <[email protected]
> > > > wrote:
>
> > >> Wow, I never knew the gadget linker did not support any of these
> > >> features. Is there any reason for that? In that case we could also try
> > >> to improve on the linker :)
>
> > >> I didn't know about shindig either, but from the looks of it, we would
> > >> have to build a GWT wrapper around it first.
>
> > >> So here's what my final goal and masterplan is:
> > >>  - I want to develop wave gadgets using ALL of GWTs features
> > >>  - I want to test in hosted mode with multiple versions of the gadget
> > >> running side by side
> > >>  - I want to be able to simulate mode changes and participant updates
> > >> all from one interface
>
> > >> I thought I was pretty close but the gadget linker not working with
> > >> some of GWTs power features is a real letdown! So does anybody have
> > >> any ideas how to build what I want to build in another way?
>
> > >> I didn't understand your point about why you cannot put a web
> > >> application in a gadget container, though. Using JSONP you can develop
> > >> any application you want and connect it to a webservice. There is no
> > >> reason for this to be slower than anything that doesn't run in a
> > >> gadget container. (I don't know what opensocial's makerequest does,
> > >> though).
>
> > >> Cheers, Jonas
>
> > >> On Feb 10, 8:11 pm, dougx <[email protected]> wrote:
> > >> > Hm.
>
> > >> > I've never been a fan of gadgets. It's always seemed rather contrived
> > >> > to me, to suggest you can have an entire web application all wrapped
> > >> > up in a single xml file.
>
> > >> > All of the open social applications you'll find in the real world make
> > >> > use of makeRequest() and server side services; the way you would
> > >> > expect a modern web application to. In fact, I'd argue the huge delay
> > >> > in adding makeRequest() and the REST api is why Hi5 and Myspace
> > >> > applications never took off the way Facebook ones did (traffic too, to
> > >> > be fair).
>
> > >> > Still, practically speaking I strongly advise you not to use the
> > >> > gadget linker. It's old, barely supported (seriously, look at the
> > >> > change log...), generates very large files (no cute splitting into per-
> > >> > browser components like the normal linker does), and makes several of
> > >> > the powerful GWT features available; specifically RPC, code splitting,
> > >> > debugging and resource bundles.
>
> > >> > Still, you know. It's kind of fun for tooling around and making little
> > >> > bits and pieces with I guess.
>
> > >> > Regarding the wave container... I suspect we're re-inventing the
> > >> > wheel; I wonder if it wouldn't be a better plan to implement an
> > >> > independent wave client container on top of shindig (http://
> > >> > shindig.apache.org/) ...
>
> > >> > ~
> > >> > Doug.
>
> > >> > On Feb 11, 10:32 am, Jonas Huckestein <[email protected]> wrote:
>
> > >> > > Hi Doug,
>
> > >> > > nice, I didn't think of using a normal GWT application as a wave
> > >> > > gadget like that before. But I think that is just a way of manually
> > >> > > doing what the Gadget API for GWT is doing for you.
>
> > >> > > What you said about being able to see two different views of the
> > >> > > gadget side by side in local testing is easily accomplished in
> > >> > > WaveConnector (actually it's the primary design goal). We can view 
> > >> > > two
> > >> > > versions of the Gadget (which is no more than a GWT widget) side by
> > >> > > side in a browser. All we need to do is give them two different
> > >> > > eventBuses (to prevent them from interfering with one another) and
> > >> > > make sure that wave-related events are shared across the buses. (more
> > >> > > generally using singletons in the GWT widget might cause problems).
>
> > >> > > I don't think there is need to include a server in order to test the
> > >> > > gadget with more than one participant :)
>
> > >> > > We can also add a user interface to add/remove participants, switch
> > >> > > the wave mode etc.. I will try to get this done next week.
>
> > >> > > Thanks for your feedback. I'm glad you liked it!
>
> > >> > > Cheers, Jonas
>
> > >> > > On Feb 10, 6:08 pm, dougx <[email protected]> wrote:
>
> > >> > > > Mmm... did you realize you can use a normal GWT application in wave
> > >> as
> > >> > > > a gadget?
>
> > >> > > > All you need is a frame:
> > >> > > > <?xml version="1.0" encoding="UTF-8" ?>
> > >> > > > <Module>
> > >> > > > <ModulePrefs title="State Example" height="220">
> > >> > > >   <Require feature="wave" />
> > >> > > > </ModulePrefs>
> > >> > > > <Content type="html">
> > >> > > > <![CDATA[
> > >> > > > <html>
> > >> > > >   <head>
> > >> > > >     <meta http-equiv="content-type" content="text/html;
> > >> > > > charset=UTF-8">
> > >> > > >     <script type="text/javascript" src="http://xxx.appspot.com/xxx/
> > >> > > > xxx.nocache.js"></script>
> > >> > > >     <link type="text/css" rel="stylesheet" href="http:/
> > >> xxx.appspot.com/
> > >> > > > xxx/xxx.css">
> > >> > > >     <title>Jewels</title>
> > >> > > >   </head>
> > >> > > >   <body>
> > >> > > >   </body>
> > >> > > > </html>
> > >> > > >  ]]>
> > >> > > > </Content>
> > >> > > > </Module>
>
> > >> > > > Then use the cross domain compiler to compile the code (this is
> > >> > > > actually exactly what it's for...):
> > >> > > > <?xml version="1.0" encoding="UTF-8"?>
> > >> > > > <!DOCTYPE module PUBLIC "-//Google Inc.//DTD Google Web Toolkit
> > >> 1.7.0//
> > >> > > > EN" "
> > >>http://google-web-toolkit.googlecode.com/svn/tags/1.7.0/distro-
> > >> > > > source/core/src/gwt-module.dtd">
> > >> > > > <module rename-to='xxx'>
> > >> > > >   <inherits name='com.google.gwt.user.User'/>
> > >> > > >   <inherits name='com.google.gwt.user.theme.standard.Standard'/>
> > >> > > >   <entry-point class='com.hax.wave.xxx.client.XXXWidget'/>
> > >> > > >   <add-linker name="xs"/> <-- You _must_ include this step to 
> > >> > > > access
> > >> > > > teh wave API.
> > >> > > > </module>
>
> > >> > > > And finally, use JSNI to access the wave api:
> > >> > > > public static native boolean isInWaveContainer() throws Exception
> > >> /*-{
> > >> > > >   var rtn = false;
> > >> > > >   if (($wnd.wave) && ($wnd.wave.isInWaveContainer()))
> > >> > > >     rtn = true;
> > >> > > >   return(rtn);
>
> > >> > > > }-*/;
>
> > >> > > > ...
>
> > >> > > > So yeah. Might find that helpful. Note that in 2.0 you can't debug
> > >> > > > using the xs linker, so you'll need to comment that line out while
> > >> > > > you're developing your widget, and then put it back when you do a
> > >> > > > deployment build.
>
> > >> > > > That wave connector is very cool; nice work! :)
>
> > >> > > > Hm... I wonder if we could add an app engine based data store based
> > >> > > > state so just when you're debugging locally you can have two 
> > >> > > > browser
> > >> > > > windows open and it'll treat those as different viewers of the
> > >> gadget,
> > >> > > > so you can do full testing. That'd involve defining separate 
> > >> > > > servlet
> > >> > > > end points though; perhaps it'd be better as a separate gwt
> > >> > > > application, and you can include it on your testing pages...
>
> > >> > > > ~
> > >> > > > Doug.
>
> > >> > > > On Feb 11, 7:42 am, Jonas Huckestein <[email protected]>
> > >> wrote:
>
> > >> > > > > Hi Everybody,
>
> > >> > > > > I have just released WaveConnector - a turnkey solution for
> > >> developing
> > >> > > > > wave gadgets using GWT and testing them in hosted mode. Please
> > >> head
> > >> > > > > over to my blog athttp://thezukunft.comortheprojectpageathttp://
> > >> code.google.com/p/waveconnector-gwt/fordetails. It's as easy
> > >> > > > > as downloading a zip archive :D
>
> > >> > > > > Chris, how di you achieve the 90%? I assume you must also 
> > >> > > > > decouple
> > >> the
> > >> > > > > GWT code from the Gadget/Wave API? I have simply implemented a
> > >> mock
> > >> > > > > version of the wave API. That way I think I can do all testing
> > >> > > > > locally.
>
> > >> > > > > Kayode, WaveConnector is exactly the mock framework (+ some
> > >> > > > > convenience functions) I was talking about :)
>
> > >> > > > > Sorry for this shameless selfpromotion on this board but I think
> > >> this
> > >> > > > > might actually help a lot of people or get them to develop for
> > >> Wave in
> > >> > > > > the first place.
>
> > >> > > > > What do all of you think of a dedicated Wave+GWT group? I asked
> > >> that
> > >> > > > > question on the GWT groups earlier and people seemed to be
> > >> interested.
>
> > >> > > > > Cheers, Jonas
>
> > >> > > > > This is my first ever open source contribution so please give me
> > >> > > > > comments and feedback on my blog or the project page.
>
> > >> > > > > On Feb 10, 2:07 am, HaiColon <[email protected]> wrote:
>
> > >> > > > > > What I do is I write the gadget in a way that makes it work 
> > >> > > > > > both
> > >> > > > > > locally (or as a website on a remote server) and then I add a
> > >> layer on
> > >> > > > > > top that makes it work with Google Wave. That way I can test 
> > >> > > > > > 90%
> > >> of
> > >> > > > > > the gadget locally, no problem. And for the other 10% I just 
> > >> > > > > > use
> > >> the
> > >> > > > > > debug features of the sandbox Wave client. That has worked good
> > >> so far
> > >> > > > > > even for bigger/more involved gadgets and the bonus is that 
> > >> > > > > > your
> > >> > > > > > gadget then doesn't need to be Wave exclusive.
>
> > >> > > > > > If you'd want to use a test-driven development approach you
> > >> could only
> > >> > > > > > test this 90% non-Wave part of the application but none of the
> > >> Google
> > >> > > > > > Wave specific stuff in the other 10%, so this approach
>
> ...
>
> read more »

-- 
You received this message because you are subscribed to the Google Groups 
"Google Wave API" 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-wave-api?hl=en.

Reply via email to