Hi All,
I have finish my first GLASS application with Seaside. Now i want to add some REST-Services: Which Configuration are you using for REST services ? Which repository hold this version ? I have loaded REST but i think there is something wrong. After registering my subclass of WARestfulHandler or WAPragmaBasedRestfulHandler the rest api is listed in http://localhost:8888/ but if i click on orbeon-api (the REST services) i get: /orbeon-api not found It looks like the App is registered but the services are not working. Any idea ? Regards, Bruno |
Bruno, Could you provide some information about the version of Seaside and GemStone you are using? Plus some information about the configuration you are loading for the restful services and finally some snippets of code to give us an idea how you've configured the restful services.On Thu, May 1, 2014 at 3:35 PM, BrunoBB <[hidden email]> wrote: Hi All, _______________________________________________ Glass mailing list [hidden email] http://lists.gemtalksystems.com/mailman/listinfo/glass |
Hi,
(i'm using JADE client) Yes, i think i have loaded incorrect version packages. GemStone version: 3.1.04 Seaside (ConfigurationOfSeaside30): (from http://seaside.gemstone.com/ss/Seaside30) + Seaside-Core-gemstone: dkh.769 + Seaside-GemStone300-Core: DaleHenrichs.4 + Seaside-Gemstone-Core: dkh.63 (from http://www.squeaksource.com/Seaside30Addons) + Seaside-GemStone-REST-Core: topa.2 Any other info that you may need ? WAOrbeonServiceHandler (subclass of WARestfulHandler): createRoutes ^ WAPragmaBasedRouteBuilder createRoutesFor: self class list <get> self requestContext respond: [ :response | response contentType: 'text/plain'. response nextPutAll: 'TEST'; nextPutAll: String crlf ] WAOrbeonPragmaServiceHandler (subclass of WAPragmaBasedRestfulHandler): list <get> self requestContext respond: [ :response | response contentType: 'text/plain'. response nextPutAll: 'TEST'; nextPutAll: String crlf ] Regards, Bruno |
On Fri, May 2, 2014 at 2:44 AM, BrunoBB <[hidden email]> wrote:
> Hi, > (i'm using JADE client) > > Yes, i think i have loaded incorrect version packages. > > GemStone version: 3.1.04 > Seaside (ConfigurationOfSeaside30): > (from http://seaside.gemstone.com/ss/Seaside30) > + Seaside-Core-gemstone: dkh.769 > + Seaside-GemStone300-Core: DaleHenrichs.4 > + Seaside-Gemstone-Core: dkh.63 > (from http://www.squeaksource.com/Seaside30Addons) > + Seaside-GemStone-REST-Core: topa.2 > > Any other info that you may need ? > > WAOrbeonServiceHandler (subclass of WARestfulHandler): > createRoutes > ^ WAPragmaBasedRouteBuilder createRoutesFor: self class > list > <get> > self requestContext respond: [ :response | > response contentType: 'text/plain'. > response > nextPutAll: 'TEST'; > nextPutAll: String crlf ] > > WAOrbeonPragmaServiceHandler (subclass of WAPragmaBasedRestfulHandler): > list > <get> > self requestContext respond: [ :response | > response contentType: 'text/plain'. > response > nextPutAll: 'TEST'; > nextPutAll: String crlf ] You did something like this? WAAdmin register: WAOrbeonPragmaServiceHandler at: 'oberon' Cheers Philippe _______________________________________________ Glass mailing list [hidden email] http://lists.gemtalksystems.com/mailman/listinfo/glass |
Hi Philippe,
Yes and the application is listed in localhost:8888. But if i click on the link a not found message is the result. Regards, Bruno |
In reply to this post by BrunoBB
On Fri, May 2, 2014 at 2:44 AM, BrunoBB <[hidden email]> wrote:
> Hi, > (i'm using JADE client) > > Yes, i think i have loaded incorrect version packages. > > GemStone version: 3.1.04 > Seaside (ConfigurationOfSeaside30): > (from http://seaside.gemstone.com/ss/Seaside30) > + Seaside-Core-gemstone: dkh.769 > + Seaside-GemStone300-Core: DaleHenrichs.4 > + Seaside-Gemstone-Core: dkh.63 > (from http://www.squeaksource.com/Seaside30Addons) > + Seaside-GemStone-REST-Core: topa.2 > > Any other info that you may need ? > > WAOrbeonServiceHandler (subclass of WARestfulHandler): > createRoutes > ^ WAPragmaBasedRouteBuilder createRoutesFor: self class > list > <get> > self requestContext respond: [ :response | > response contentType: 'text/plain'. > response > nextPutAll: 'TEST'; > nextPutAll: String crlf ] > > WAOrbeonPragmaServiceHandler (subclass of WAPragmaBasedRestfulHandler): > list > <get> > self requestContext respond: [ :response | > response contentType: 'text/plain'. > response > nextPutAll: 'TEST'; > nextPutAll: String crlf ] try WAOrbeonPragmaServiceHandler (subclass of WAPragmaBasedRestfulHandler): list <get> <path: ''> or WAOrbeonPragmaServiceHandler (subclass of WAPragmaBasedRestfulHandler): list <get> <path: '/'> Cheers Philippe _______________________________________________ Glass mailing list [hidden email] http://lists.gemtalksystems.com/mailman/listinfo/glass |
Philippe,
Thanks for the answer but i'm having the same result: /orbeon-api not found. If i use <path: ''> or <path: '/'> what will be the url of the service ? Are you using REST services ? What packages and repositories are you using ? Regards, Bruno |
On Fri, May 2, 2014 at 10:02 PM, BrunoBB <[hidden email]> wrote:
> Philippe, > > Thanks for the answer but i'm having the same result: > /orbeon-api not found. > > If i use <path: ''> or <path: '/'> what will be the url of the service ? > > Are you using REST services ? > What packages and repositories are you using ? The latest Seaside 3.1 "trunk" on Pharo. The attached code works for me. It should work on older versions as well. You will have to do: WAOrbeonPragmaServiceHandler register after loading the code. After that the service is available under /orbeon-api. If you image still has a WAPragmaBasedRestfulHandler class you need change the superclass to WAPragmaBasedRestfulHandler. If things then still don't work you'll have to debug WARestfulHandler >> #handleFiltered: and find out why your method does not match the request. If you don't reach WARestfulHandler >> #handleFiltered: then something with your registration went wrong. Cheers Philippe _______________________________________________ Glass mailing list [hidden email] http://lists.gemtalksystems.com/mailman/listinfo/glass |
On Sat, May 10, 2014 at 10:34 AM, Philippe Marschall
<[hidden email]> wrote: > On Fri, May 2, 2014 at 10:02 PM, BrunoBB <[hidden email]> wrote: >> Philippe, >> >> Thanks for the answer but i'm having the same result: >> /orbeon-api not found. >> >> If i use <path: ''> or <path: '/'> what will be the url of the service ? >> >> Are you using REST services ? >> What packages and repositories are you using ? > > The latest Seaside 3.1 "trunk" on Pharo. > > The attached code works for me. Cheers Philippe _______________________________________________ Glass mailing list [hidden email] http://lists.gemtalksystems.com/mailman/listinfo/glass WAOrbeonPragmaServiceHandler.st (1K) Download Attachment |
Free forum by Nabble | Edit this page |