<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	>
<channel>
	<title>Comments on: Thinking of alternatives to GWT-RPC</title>
	<atom:link href="http://www.pathf.com/blogs/2007/11/thinking-of-alt/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.pathf.com/blogs/2007/11/thinking-of-alt/</link>
	<description>Running commentary about agile development, user experience design and Ajax.</description>
	<pubDate>Fri, 05 Dec 2008 17:36:54 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.5.1</generator>
		<item>
		<title>By: Austria</title>
		<link>http://www.pathf.com/blogs/2007/11/thinking-of-alt/#comment-2772</link>
		<dc:creator>Austria</dc:creator>
		<pubDate>Wed, 06 Aug 2008 08:10:50 +0000</pubDate>
		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=188#comment-2772</guid>
		<description>Better late than never:
is there a possibilty to use RMI in GWT? can't get my RPC server running!</description>
		<content:encoded><![CDATA[<p>Better late than never:<br />
is there a possibilty to use RMI in GWT? can&#8217;t get my RPC server running!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Carl Scott</title>
		<link>http://www.pathf.com/blogs/2007/11/thinking-of-alt/#comment-208</link>
		<dc:creator>Carl Scott</dc:creator>
		<pubDate>Tue, 29 Apr 2008 03:30:43 +0000</pubDate>
		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=188#comment-208</guid>
		<description>&lt;p&gt;Better late than never, check out my blog on this topic, it basically goes along with some comments here.  Feel free to leave comments, I plan to follow up directly in regards to them!&lt;/p&gt;

&lt;p&gt;&lt;a href="http://gogocarl.blogspot.com/2008/04/internet-alternative-to-gwts-rpc.html" rel="nofollow"&gt;http://gogocarl.blogspot.com/2008/04/internet-alternative-to-gwts-rpc.html&lt;/a&gt;&lt;/p&gt;

</description>
		<content:encoded><![CDATA[<p>Better late than never, check out my blog on this topic, it basically goes along with some comments here.  Feel free to leave comments, I plan to follow up directly in regards to them!</p>
<p><a href="http://gogocarl.blogspot.com/2008/04/internet-alternative-to-gwts-rpc.html" rel="nofollow">http://gogocarl.blogspot.com/2008/04/internet-alternative-to-gwts-rpc.html</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: BIll K</title>
		<link>http://www.pathf.com/blogs/2007/11/thinking-of-alt/#comment-207</link>
		<dc:creator>BIll K</dc:creator>
		<pubDate>Sun, 27 Jan 2008 12:17:27 +0000</pubDate>
		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=188#comment-207</guid>
		<description>&lt;p&gt;I was just thinking about this problem and trying to find out if someone else had looked into it.&lt;/p&gt;

&lt;p&gt;I've implmented what I think is my ideal client/server communication on another project (non-web).  It involved locating all the code and data for the transaction in a single object.&lt;/p&gt;

&lt;p&gt;It is implemented something like this:&lt;/p&gt;

&lt;p&gt;public MyXferObject extends MyXferObjectBase {&lt;br /&gt;
private int x;&lt;br /&gt;
private int y;&lt;br /&gt;
private int result;&lt;/p&gt;

&lt;p&gt;  public MyXferObject(int px, int py) {&lt;br /&gt;
x=px;&lt;br /&gt;
y=py;&lt;br /&gt;
}&lt;/p&gt;

&lt;p&gt;  public arrivedServer() {&lt;br /&gt;
result = x + y;  // Long complicated operation&lt;br /&gt;
}&lt;/p&gt;

&lt;p&gt;  public arrivedClient() {&lt;br /&gt;
aLabel.setText("The result was:"+result);&lt;br /&gt;
}&lt;br /&gt;
}&lt;/p&gt;

&lt;p&gt;This has a few advantages and some pretty serious problems.&lt;/p&gt;

&lt;p&gt;As for the advantages, it keeps everything needed for a given client/server transaction in one file.  The shared data makes coding trivial, and there is no need to futz around with specialized interfaces or async callbacks, there are just two methods to override and that's it--the arrivedServer is executed when the object arrives at the server, and the arrivedClient is executed by what is currently called the callback.&lt;/p&gt;

&lt;p&gt;This also makes the calling as simple as "(new MyXferObject(1, 2)).send()" if we assume that the parent class implements a .send method to kick things off.&lt;/p&gt;

&lt;p&gt;The disadvantages:&lt;br /&gt;
References to classes that exist only on the client or server will not compile on the "other side".&lt;/p&gt;

&lt;p&gt;Twoi possible solutions to this are:&lt;br /&gt;
- Pre-compiling to split the class into something that resembles the current RPC mechanism, or&lt;br /&gt;
- Using annotations to prevent the errors by specifying methods that shouldn't compile on one side or the other.&lt;/p&gt;

&lt;p&gt;There is also a perceived problem that you are "Mixing" client and server code in the same object, but since the concept is one that actually bridges the client and server, I think it's completely appropriate.&lt;/p&gt;

&lt;p&gt;Besides, the real advantage comes when the client and server portions are implemented separately.  One abstract class implements the arrivedServer method--sy it does some generic database I/O, on some data fields.  This could later be extended, overriding the "arrivedClient" method and possibly the constructor to set up the data, which should lead to quite a bit more reuse.&lt;/p&gt;

&lt;p&gt;What I mean by "more reuse" is that this approach completely isolates and removes the RPC portion of the problem allowing a mid-level portion to be added on top of the communications without re-implementing it every time.  I don't know an easy way to do that with the existing RPC mechanism.&lt;/p&gt;

&lt;p&gt;I am kind of working on this right now, and I'm just not familiar with the GWT compiler or annotations so I'm not sure where to start with the first problem I listed, but I'll keep hacking at it.&lt;/p&gt;

&lt;p&gt;Oh, also if this sits on top of the existing RPC mechanism there is the problem that I'll always be passing a generic object around which the docs said was inefficient.  Using a pre-compiler should solve that too.&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>I was just thinking about this problem and trying to find out if someone else had looked into it.</p>
<p>I&#8217;ve implmented what I think is my ideal client/server communication on another project (non-web).  It involved locating all the code and data for the transaction in a single object.</p>
<p>It is implemented something like this:</p>
<p>public MyXferObject extends MyXferObjectBase {<br />
private int x;<br />
private int y;<br />
private int result;</p>
<p>  public MyXferObject(int px, int py) {<br />
x=px;<br />
y=py;<br />
}</p>
<p>  public arrivedServer() {<br />
result = x + y;  // Long complicated operation<br />
}</p>
<p>  public arrivedClient() {<br />
aLabel.setText(&#8221;The result was:&#8221;+result);<br />
}<br />
}</p>
<p>This has a few advantages and some pretty serious problems.</p>
<p>As for the advantages, it keeps everything needed for a given client/server transaction in one file.  The shared data makes coding trivial, and there is no need to futz around with specialized interfaces or async callbacks, there are just two methods to override and that&#8217;s it&#8211;the arrivedServer is executed when the object arrives at the server, and the arrivedClient is executed by what is currently called the callback.</p>
<p>This also makes the calling as simple as &#8220;(new MyXferObject(1, 2)).send()&#8221; if we assume that the parent class implements a .send method to kick things off.</p>
<p>The disadvantages:<br />
References to classes that exist only on the client or server will not compile on the &#8220;other side&#8221;.</p>
<p>Twoi possible solutions to this are:<br />
- Pre-compiling to split the class into something that resembles the current RPC mechanism, or<br />
- Using annotations to prevent the errors by specifying methods that shouldn&#8217;t compile on one side or the other.</p>
<p>There is also a perceived problem that you are &#8220;Mixing&#8221; client and server code in the same object, but since the concept is one that actually bridges the client and server, I think it&#8217;s completely appropriate.</p>
<p>Besides, the real advantage comes when the client and server portions are implemented separately.  One abstract class implements the arrivedServer method&#8211;sy it does some generic database I/O, on some data fields.  This could later be extended, overriding the &#8220;arrivedClient&#8221; method and possibly the constructor to set up the data, which should lead to quite a bit more reuse.</p>
<p>What I mean by &#8220;more reuse&#8221; is that this approach completely isolates and removes the RPC portion of the problem allowing a mid-level portion to be added on top of the communications without re-implementing it every time.  I don&#8217;t know an easy way to do that with the existing RPC mechanism.</p>
<p>I am kind of working on this right now, and I&#8217;m just not familiar with the GWT compiler or annotations so I&#8217;m not sure where to start with the first problem I listed, but I&#8217;ll keep hacking at it.</p>
<p>Oh, also if this sits on top of the existing RPC mechanism there is the problem that I&#8217;ll always be passing a generic object around which the docs said was inefficient.  Using a pre-compiler should solve that too.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Bruce Johnson</title>
		<link>http://www.pathf.com/blogs/2007/11/thinking-of-alt/#comment-206</link>
		<dc:creator>Bruce Johnson</dc:creator>
		<pubDate>Sat, 01 Dec 2007 14:25:56 +0000</pubDate>
		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=188#comment-206</guid>
		<description>&lt;p&gt;"GWT wants to abstract away the web. REST embraces the web. As such, I wouldn't hold your breath for a REST interface coming out of Mountain View."&lt;/p&gt;

&lt;p&gt;@Justin: We must be doing a bad job of explaining the full philosophy of GWT. We are most definitely *not* trying to abstract away the web; we're just trying to add leverage to make better apps possible. That's why GWT has the JavaScript Native Interface (JSNI), JSON, and XML libraries in addition to GWT-RPC. Widgets are styled with CSS. &lt;/p&gt;

&lt;p&gt;If you have the time, please check out the GWT mission statement in "Making GWT Better" (&lt;a href="http://code.google.com/webtoolkit/makinggwtbetter.html)" rel="nofollow"&gt;http://code.google.com/webtoolkit/makinggwtbetter.html)&lt;/a&gt; to hear the full story. All that said, if we can be doing more to simplify interop or enhance the web user experience, please say so on the GWT contributor fourm.&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>&#8220;GWT wants to abstract away the web. REST embraces the web. As such, I wouldn&#8217;t hold your breath for a REST interface coming out of Mountain View.&#8221;</p>
<p>@Justin: We must be doing a bad job of explaining the full philosophy of GWT. We are most definitely *not* trying to abstract away the web; we&#8217;re just trying to add leverage to make better apps possible. That&#8217;s why GWT has the JavaScript Native Interface (JSNI), JSON, and XML libraries in addition to GWT-RPC. Widgets are styled with CSS. </p>
<p>If you have the time, please check out the GWT mission statement in &#8220;Making GWT Better&#8221; (<a href="http://code.google.com/webtoolkit/makinggwtbetter.html)" rel="nofollow"></a><a href="http://code.google.com/webtoolkit/makinggwtbetter.html" rel="nofollow">http://code.google.com/webtoolkit/makinggwtbetter.html</a>) to hear the full story. All that said, if we can be doing more to simplify interop or enhance the web user experience, please say so on the GWT contributor fourm.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jon Crosby</title>
		<link>http://www.pathf.com/blogs/2007/11/thinking-of-alt/#comment-205</link>
		<dc:creator>Jon Crosby</dc:creator>
		<pubDate>Thu, 29 Nov 2007 15:45:56 +0000</pubDate>
		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=188#comment-205</guid>
		<description>&lt;p&gt;I believe that Jester (&lt;a href="http://jesterjs.org)" rel="nofollow"&gt;http://jesterjs.org)&lt;/a&gt; coupled with JAX-RS (or even Rails) on the server side might be a nice way to go.&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>I believe that Jester (<a href="http://jesterjs.org)" rel="nofollow"></a><a href="http://jesterjs.org" rel="nofollow">http://jesterjs.org</a>) coupled with JAX-RS (or even Rails) on the server side might be a nice way to go.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Justin Makeig</title>
		<link>http://www.pathf.com/blogs/2007/11/thinking-of-alt/#comment-204</link>
		<dc:creator>Justin Makeig</dc:creator>
		<pubDate>Thu, 29 Nov 2007 00:03:34 +0000</pubDate>
		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=188#comment-204</guid>
		<description>&lt;p&gt;GWT wants to abstract away the web. REST embraces the web. As such, I wouldn't hold your breath for a REST interface coming out of Mountain View.&lt;br /&gt;
I think something like Enunciate [&lt;a href="http://enunciate.codehaus.org/module_gwt.html]" rel="nofollow"&gt;http://enunciate.codehaus.org/module_gwt.html]&lt;/a&gt; is the way to go. I haven't used it, but it looks pretty interesting. It purports to generate SOAP, REST, and GWT-RPC interface layers based on some annotations and minimal XML configuration.&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>GWT wants to abstract away the web. REST embraces the web. As such, I wouldn&#8217;t hold your breath for a REST interface coming out of Mountain View.<br />
I think something like Enunciate [<a href="http://enunciate.codehaus.org/module_gwt.html]&#8221; rel=&#8221;nofollow&#8221;>http://enunciate.codehaus.org/module_gwt.html</a> is the way to go. I haven&#8217;t used it, but it looks pretty interesting. It purports to generate SOAP, REST, and GWT-RPC interface layers based on some annotations and minimal XML configuration.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ivan Moscoso</title>
		<link>http://www.pathf.com/blogs/2007/11/thinking-of-alt/#comment-203</link>
		<dc:creator>Ivan Moscoso</dc:creator>
		<pubDate>Wed, 28 Nov 2007 23:09:40 +0000</pubDate>
		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=188#comment-203</guid>
		<description>&lt;p&gt;Good point- I have something like that in mind as well.&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Good point- I have something like that in mind as well.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ryan Dewsbury</title>
		<link>http://www.pathf.com/blogs/2007/11/thinking-of-alt/#comment-202</link>
		<dc:creator>Ryan Dewsbury</dc:creator>
		<pubDate>Wed, 28 Nov 2007 15:05:31 +0000</pubDate>
		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=188#comment-202</guid>
		<description>&lt;p&gt;It would be interesting to see a REST implementation.&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>It would be interesting to see a REST implementation.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
