RE: Restlet GWT RPC 2.0

2010-01-01 Thread Jerome Louvel
Hi Kevin,

Happy new year! Quick reply: 

1) I suggest that you have a look at this blog post:
http://blog.noelios.com/2009/12/17/restlet-a-restful-middleware-for-gwt-gae-
and-android/

2) Have a look at this tutorial:
http://wiki.restlet.org/docs_2.0/13-restlet/181-restlet/303-restlet.html

2) Please use a recent 2.0 snapshot to make the tutorial work:
http://www.restlet.org/downloads/unstable

Best regards,
Jerome Louvel
--
Restlet ~ Founder and Lead developer ~ http://www.restlet.org
Noelios Technologies ~ Co-founder ~ http://www.noelios.com



-Message d'origine-
De : Kevin Daly [mailto:ked...@sqm.ca] 
Envoyé : jeudi 31 décembre 2009 17:35
À : discuss@restlet.tigris.org
Objet : RE: Restlet GWT RPC 2.0

To give some more insight on the problem. When I run the code in the
debugger the code fails on line 229 of ClientAdapter.java. 

This line.

userCallback.handle(request, response);

I've looked at it in the debugger and there's no method to handle in the
Proxy Class that I provided, the debugger also show that the class generated
inherits from ClientResource, but I cannot find an implementation of
handle(request, response) in ClientResource or UniformResource (parent
class). 

This seems to be where the problem is occurring. Is this a bug, or am I
doing something wrong?

By the way, Restlet looks excellent and I am looking forward to using it in
2010. Happy New year to the Restlet Team.

--
http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447dsMessageId=24339
98

--
http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447dsMessageId=2434068


How to REST in SpringFramework

2010-01-01 Thread gozfidan
Hi,
I am new to REST and trying to integrate with my Spring application. I have
done
some searching bu got stuck. I have changed the web.xml and add
RestletServlet-servlet.xml
but not sure how to implement Resource?


web.xml
servlet
servlet-nameRestletServlet/servlet-name
   
servlet-classorg.restlet.ext.spring.RestletFrameworkServlet/servlet-class
/servlet


RestletServlet-servlet.xml

?xml version=1.0 encoding=UTF-8?
beans xmlns=http://www.springframework.org/schema/beans;
xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
xsi:schemaLocation=http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-2.0.xsd;

bean id=root class=org.restlet.ext.spring.SpringRouter
property name=attachments
map
entry key=/poll
bean class=org.restlet.ext.spring.SpringFinder
lookup-method name=createResource
bean=pollSystemResource /
/bean
/entry
/map
/property
/bean

bean id=pollSystemResource
class=com.smartcrop.webapp.service.PollSystemResource autowire=byName/
/beans


and I have this PollSystemResource if I extend it with SpringResource
I get an error for  [cannot find symbol constructor SpringResource()]

If my steps are correct, how do I implement my Resources
thanks.
-- 
View this message in context: 
http://n2.nabble.com/How-to-REST-in-SpringFramework-tp4237720p4237720.html
Sent from the Restlet Discuss mailing list archive at Nabble.com.

--
http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447dsMessageId=2434026


Restlet 2.0 GWT 2.0 Dev Mode

2010-01-01 Thread Bryan Hunt
I'm starting to look at using Restlet 2.0 with GWT 2.0.  The docs for setting 
up a project:

http://wiki.restlet.org/docs_2.0/13-restlet/275-restlet/144-restlet/186-restlet.html

talk about setting up the old GWT Hosted Mode.  The new Dev Mode seems to be 
using Jetty instead of Tomcat, and there doesn't seem to be any web.xml files 
for configuring the shell servlet.  Are there any new docs on how to set up a 
project using Restlet 2.0 with GWT 2.0 Dev Mode?

Bryan

--
http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447dsMessageId=2434081


Re: Restlet 2.0 GWT 2.0 Dev Mode

2010-01-01 Thread Rob Heittman
We should write some now that GWT 2.0 is not a moving target any more.  When
working with Jetty and Dev Mode under 2.0 trunk, I have always just used the
ServerServlet to attach Restlet to a path.  I do not believe it is really
possible any more to attach Restlet to the root of the container (/), at
least not without surgery to GWT's DefaultServlet, which in turn is a
modified version of Jetty's that understands how to handle GWT modules ...
and I hope we don't have to attack that.

All I do in practice, in my GWT 2.0 client applications, is make sure the
root of any RESTful resources is configurable, and set it differently in Dev
Mode than in production.  Then I usually attach Restlet (usually a
redirector to my real Restlet server side running somewhere else) to /r
under GWT using ServerServlet, same as any other JEE container.

If that practice sounds sane to everybody else, I'll write it up.

On Fri, Jan 1, 2010 at 9:56 AM, Bryan Hunt bh...@mac.com wrote:

 I'm starting to look at using Restlet 2.0 with GWT 2.0.  The docs for
 setting up a project:


 http://wiki.restlet.org/docs_2.0/13-restlet/275-restlet/144-restlet/186-restlet.html

 talk about setting up the old GWT Hosted Mode.  The new Dev Mode seems to
 be using Jetty instead of Tomcat, and there doesn't seem to be any web.xml
 files for configuring the shell servlet.  Are there any new docs on how to
 set up a project using Restlet 2.0 with GWT 2.0 Dev Mode?

 Bryan

 --

 http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447dsMessageId=2434081


--
http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447dsMessageId=2434082

Re: Restlet 2.0 GWT 2.0 Dev Mode

2010-01-01 Thread Tim Peierls
That answers the question I was trying to formulate, Rob. Yes, please do
write it up.

The current Restlet-GWT sample
projecthttp://wiki.restlet.org/docs_1.1/162-restlet/version/default/part/AttachmentData/data/RestletGWTSimpleExample.zipis
already set up for Restlet 2.0 and GWT 2.0 -- I had no trouble getting
things running in dev mode using Ant.

--tim

On Fri, Jan 1, 2010 at 10:18 AM, Rob Heittman rob.heitt...@solertium.comwrote:

 We should write some now that GWT 2.0 is not a moving target any more.
  When working with Jetty and Dev Mode under 2.0 trunk, I have always just
 used the ServerServlet to attach Restlet to a path.  I do not believe it is
 really possible any more to attach Restlet to the root of the container (/),
 at least not without surgery to GWT's DefaultServlet, which in turn is a
 modified version of Jetty's that understands how to handle GWT modules ...
 and I hope we don't have to attack that.

 All I do in practice, in my GWT 2.0 client applications, is make sure the
 root of any RESTful resources is configurable, and set it differently in Dev
 Mode than in production.  Then I usually attach Restlet (usually a
 redirector to my real Restlet server side running somewhere else) to /r
 under GWT using ServerServlet, same as any other JEE container.

 If that practice sounds sane to everybody else, I'll write it up.

 On Fri, Jan 1, 2010 at 9:56 AM, Bryan Hunt bh...@mac.com wrote:

 I'm starting to look at using Restlet 2.0 with GWT 2.0.  The docs for
 setting up a project:


 http://wiki.restlet.org/docs_2.0/13-restlet/275-restlet/144-restlet/186-restlet.html

 talk about setting up the old GWT Hosted Mode.  The new Dev Mode seems to
 be using Jetty instead of Tomcat, and there doesn't seem to be any web.xml
 files for configuring the shell servlet.  Are there any new docs on how to
 set up a project using Restlet 2.0 with GWT 2.0 Dev Mode?

 Bryan

 --

 http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447dsMessageId=2434081




--
http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447dsMessageId=2434092

Re: Restlet 2.0 GWT 2.0 Dev Mode

2010-01-01 Thread Bryan Hunt
Rob,

How are you registering the ServerServlet with the embedded Jetty that GWT is 
launching?

Bryan

On Jan 1, 2010, at 9:18 AM, Rob Heittman wrote:

 We should write some now that GWT 2.0 is not a moving target any more.  When 
 working with Jetty and Dev Mode under 2.0 trunk, I have always just used the 
 ServerServlet to attach Restlet to a path.  I do not believe it is really 
 possible any more to attach Restlet to the root of the container (/), at 
 least not without surgery to GWT's DefaultServlet, which in turn is a 
 modified version of Jetty's that understands how to handle GWT modules ... 
 and I hope we don't have to attack that.
 
 All I do in practice, in my GWT 2.0 client applications, is make sure the 
 root of any RESTful resources is configurable, and set it differently in Dev 
 Mode than in production.  Then I usually attach Restlet (usually a redirector 
 to my real Restlet server side running somewhere else) to /r under GWT 
 using ServerServlet, same as any other JEE container.
 
 If that practice sounds sane to everybody else, I'll write it up.
 
 On Fri, Jan 1, 2010 at 9:56 AM, Bryan Hunt bh...@mac.com wrote:
 I'm starting to look at using Restlet 2.0 with GWT 2.0.  The docs for setting 
 up a project:
 
 http://wiki.restlet.org/docs_2.0/13-restlet/275-restlet/144-restlet/186-restlet.html
 
 talk about setting up the old GWT Hosted Mode.  The new Dev Mode seems to be 
 using Jetty instead of Tomcat, and there doesn't seem to be any web.xml files 
 for configuring the shell servlet.  Are there any new docs on how to set up a 
 project using Restlet 2.0 with GWT 2.0 Dev Mode?
 
 Bryan
 
 --
 http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447dsMessageId=2434081


--
http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447dsMessageId=2434093

Re: Restlet 2.0 GWT 2.0 Dev Mode

2010-01-01 Thread Rob Heittman
I use Eclipse and OSGi manifests, so the Restlet bundles are open in my IDE
and declared as dependencies of my GWT project -- I need org.restlet and
org.restlet.ext.servlet.  But however you get the jars onto the classpath
will be fine -- I'll document a few other choices when I write this up
officially.  Then in the war directory of my GWT project, I place a
WEB-INF/lib/web.xml with contents like this:

?xml version=1.0 encoding=UTF-8?
web-app

servlet
servlet-nameadapter/servlet-name
servlet-classorg.restlet.ext.servlet.ServerServlet/servlet-class
init-param !--  In my case I have a dummy value here, as my component
takes care of application attachment ... but see the ServerServlet docs--
  param-nameorg.restlet.application/param-name
  param-valueorg.restlet.Application [or your actual
Application]/param-value
/init-param
init-param
  param-nameorg.restlet.component/param-name
  param-value[my component here]/param-value
/init-param
/servlet
 servlet-mapping
servlet-nameadapter/servlet-name
url-pattern/r/*/url-pattern
/servlet-mapping

/web-app


On Fri, Jan 1, 2010 at 12:16 PM, Bryan Hunt bh...@mac.com wrote:

 Rob,

 How are you registering the ServerServlet with the embedded Jetty that GWT
 is launching?

 Bryan

 On Jan 1, 2010, at 9:18 AM, Rob Heittman wrote:

 We should write some now that GWT 2.0 is not a moving target any more.
  When working with Jetty and Dev Mode under 2.0 trunk, I have always just
 used the ServerServlet to attach Restlet to a path.  I do not believe it is
 really possible any more to attach Restlet to the root of the container (/),
 at least not without surgery to GWT's DefaultServlet, which in turn is a
 modified version of Jetty's that understands how to handle GWT modules ...
 and I hope we don't have to attack that.

 All I do in practice, in my GWT 2.0 client applications, is make sure the
 root of any RESTful resources is configurable, and set it differently in Dev
 Mode than in production.  Then I usually attach Restlet (usually a
 redirector to my real Restlet server side running somewhere else) to /r
 under GWT using ServerServlet, same as any other JEE container.

 If that practice sounds sane to everybody else, I'll write it up.

 On Fri, Jan 1, 2010 at 9:56 AM, Bryan Hunt bh...@mac.com wrote:

 I'm starting to look at using Restlet 2.0 with GWT 2.0.  The docs for
 setting up a project:


 http://wiki.restlet.org/docs_2.0/13-restlet/275-restlet/144-restlet/186-restlet.html

 talk about setting up the old GWT Hosted Mode.  The new Dev Mode seems to
 be using Jetty instead of Tomcat, and there doesn't seem to be any web.xml
 files for configuring the shell servlet.  Are there any new docs on how to
 set up a project using Restlet 2.0 with GWT 2.0 Dev Mode?

 Bryan

 --

 http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447dsMessageId=2434081





--
http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447dsMessageId=2434095