You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@shindig.apache.org by Ian Boston <ie...@tfd.co.uk> on 2008/04/15 11:54:51 UTC

question: social rest api's

Is the intention with the rest based apis for opensocial in shindig  
to just provide the JS client libraries and leave the implementation   
of the server side of the api to the implementor.

or

will Shindig be implementing a rest based server component, with DB  
backend.

Also, is there any intention to use POST on the rest URL's to do  
updates to social data where it makes sense... sorry if this has been  
mentioned already.

---

 From our (selfish) point of view, we already have the rest  
scafolding deployed, so shindig providing the client side libraries  
is attractive as we can probably implement the rest based server  
quite quickly in out own infrastructure.


Ian




Re: question: social rest api's

Posted by David Primmer <da...@gmail.com>.
On Tue, Apr 15, 2008 at 3:35 PM, Ian Boston <ie...@tfd.co.uk> wrote:
> I don't know enough about CouchDB to say if its a good solution, but am I
> correct in thinking its another server to setup and wont run in the same JVM
> as the Shindig instance ? (Looking at the svn it see c code, and mention of
> mod_couch ... sounds like it needs apache httpd to run ).

CouchDB was recently added as an adapter type to Abdera. It, like JCR
is a natural fit for the data formats of an Atom server. I haven't
used the CouchDB adapter, but I assume it works with a little
configuration, like the other adapters.

>
>  To make it really easy for someone to take a Shindig instance out of the
> box, the approach that Jackrabbit took might be worth following. They used a
> default DB of Derby, which didn't need any config, as it will run embedded.
> This also allowed them to make the TCK run all its tests inside maven
> without additional config.
>
>  This may all be small point, since I see that Abdera has a number of other
> ColectionAdapters including iBatis, Hibernate and even JCR.
>
>  --------------
>
>  Another quick question.
>
>  With the REST api being implemented, is there any point in implementing the
> Services (eg PeopleService) that exist in the current code base against a DB
> backend .... or will they be deprecated shortly (within 4 weeks)

We're hoping to to 'punt' on this for now and stick to a simple system
that is easily replaceable. I've always like the embedded Derby idea.
The backend storage is kinda tricky because it's one part of the
reference implementation (along with your java container) we're
assuming everyone will replace with their own storage system. For
those that are truly starting from scratch, there may be some
incentive to create a more elaborate reference.

>
>
>
>  Ian
>
>
>
>
>
>  On 15 Apr 2008, at 17:28, Jun Yang (杨骏) wrote:
>
> > On Tue, Apr 15, 2008 at 7:30 AM, Santiago Gala <sa...@gmail.com>
> > wrote:
> >
> >
> > > El mar, 15-04-2008 a las 03:59 -0700, Kevin Brown escribió:
> > >
> > > > On Tue, Apr 15, 2008 at 2:54 AM, Ian Boston <ie...@tfd.co.uk> wrote:
> > > >
> > > >
> > > > > Is the intention with the rest based apis for opensocial in shindig
> to
> > > > > just provide the JS client libraries and leave the implementation
> of
> > > > >
> > > >
> > > the
> > >
> > > >
> > > > > server side of the api to the implementor.
> > > > >
> > > >
> > >
> > >
> >
> > Yes.
> >
> >
> >
> > >
> > > >
> > > > > or
> > > > >
> > > > > will Shindig be implementing a rest based server component, with DB
> > > > > backend
> > > > >
> > > >
> > >
> > >
> >
> > The first version will come with good support for relational databases, as
> > is the common case.
> >
> >
> >
> > > I wonder if using a very simple CouchDB backend could make sense.
> > > CouchDB offers a DB with native json API and javascript running in the
> > > server, so at least propotype support for initial experiments.
> > >
> > >
> >
> > Since the server is based on Abdera and Abdera already has an adapter for
> > CouchDB, this should be easy.
> >
> > Jun
> >
> > It looks a great tool for this, though for a prototype python +
> >
> > > simplejson + some dictionaries can actually be a similar very simple
> > > framework. Or s/python/<your favorite dynamic language>/ :)
> > >
> > >
> > > >
> > > > RESTful APIs are in development now, though nothing has been committed
> > > >
> > > yet.
> > >
> > > > See mail archives for discussion. I'd expect the first commit within
> the
> > > > next week or two at most. The RESTful  spec was just finalized last
> week
> > > >
> > > --
> > >
> > > > we need a little time! :)
> > > >
> > > > Also, is there any intention to use POST on the rest URL's to do
> updates
> > > >
> > > to
> > >
> > > >
> > > > > social data where it makes sense... sorry if this has been mentioned
> > > > > already.
> > > > >
> > > >
> > > >
> > > > We'll do whatever the spec requires.
> > > >
> > > >
> > >
> > > +1, ReST requires POST/PUT for non-idempotent request, and *updates* are
> > > always non-idempotent. Even if I'm not following the spec right now, I
> > > would be very surprised if the spec used GET for updates. But this, as
> > > Kevin said, belongs to the spec ground.
> > >
> > > --
> > > Santiago Gala
> > > http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/blog/>
> > >
> > >
> > >
> >
>
>

Re: question: social rest api's

Posted by Vasu Nori <vn...@google.com>.
On Tue, Apr 15, 2008 at 3:35 PM, Ian Boston <ie...@tfd.co.uk> wrote:

> I don't know enough about CouchDB to say if its a good solution, but am I
> correct in thinking its another server to setup and wont run in the same JVM
> as the Shindig instance ? (Looking at the svn it see c code, and mention of
> mod_couch ... sounds like it needs apache httpd to run ).
>
> To make it really easy for someone to take a Shindig instance out of the
> box, the approach that Jackrabbit took might be worth following. They used a
> default DB of Derby, which didn't need any config, as it will run embedded.
> This also allowed them to make the TCK run all its tests inside maven
> without additional config.
>
> This may all be small point, since I see that Abdera has a number of other
> ColectionAdapters including iBatis, Hibernate and even JCR.

The current design for reference implementation of OpenSocial API server
will allow any of the datasources to be used with the server - just like the
current Shindig server does.
In addition, thanks to Abdera, one shouldn't have to write any of the
adapters that Abdera already supports - that includes JCR.

The JavaDB (derby)embedded with Java 1.6 can be a datasource too.
you are right - it is worth having the Opensocial API server have an
concrete interface implementation to  JavaDB.
we should have that soon after the 1st cut is out, if not already included
in it..

>
>
> --------------
>
> Another quick question.
>
> With the REST api being implemented, is there any point in implementing
> the Services (eg PeopleService) that exist in the current code base against
> a DB backend .... or will they be deprecated shortly (within 4 weeks)
>
>
>
> Ian
>
>
>
>
> On 15 Apr 2008, at 17:28, Jun Yang (杨骏) wrote:
>
> > On Tue, Apr 15, 2008 at 7:30 AM, Santiago Gala <sa...@gmail.com>
> > wrote:
> >
> >  El mar, 15-04-2008 a las 03:59 -0700, Kevin Brown escribió:
> > >
> > > > On Tue, Apr 15, 2008 at 2:54 AM, Ian Boston <ie...@tfd.co.uk> wrote:
> > > >
> > > >  Is the intention with the rest based apis for opensocial in shindig
> > > > > to
> > > > > just provide the JS client libraries and leave the implementation
> > > > >  of
> > > > >
> > > > the
> > >
> > > > server side of the api to the implementor.
> > > > >
> > > >
> > >
> > Yes.
> >
> >
> >  or
> > > > >
> > > > > will Shindig be implementing a rest based server component, with
> > > > > DB
> > > > > backend
> > > > >
> > > >
> > >
> > The first version will come with good support for relational databases,
> > as
> > is the common case.
> >
> >
> >  I wonder if using a very simple CouchDB backend could make sense.
> > > CouchDB offers a DB with native json API and javascript running in the
> > > server, so at least propotype support for initial experiments.
> > >
> > >
> > Since the server is based on Abdera and Abdera already has an adapter
> > for
> > CouchDB, this should be easy.
> >
> > Jun
> >
> > It looks a great tool for this, though for a prototype python +
> >
> > > simplejson + some dictionaries can actually be a similar very simple
> > > framework. Or s/python/<your favorite dynamic language>/ :)
> > >
> > >
> > > > RESTful APIs are in development now, though nothing has been
> > > > committed
> > > >
> > > yet.
> > >
> > > > See mail archives for discussion. I'd expect the first commit within
> > > > the
> > > > next week or two at most. The RESTful  spec was just finalized last
> > > > week
> > > >
> > > --
> > >
> > > > we need a little time! :)
> > > >
> > > > Also, is there any intention to use POST on the rest URL's to do
> > > > updates
> > > >
> > > to
> > >
> > > > social data where it makes sense... sorry if this has been mentioned
> > > > > already.
> > > > >
> > > >
> > > >
> > > > We'll do whatever the spec requires.
> > > >
> > > >
> > > +1, ReST requires POST/PUT for non-idempotent request, and *updates*
> > > are
> > > always non-idempotent. Even if I'm not following the spec right now, I
> > > would be very surprised if the spec used GET for updates. But this, as
> > > Kevin said, belongs to the spec ground.
> > >
> > > --
> > > Santiago Gala
> > > http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/blog/> <
> > > http://memojo.com/%7Esgala/blog/>
> > >
> > >
> > >
>

Re: question: social rest api's

Posted by Raymond Auge <ra...@liferay.com>.
I would assume that a vast majority of end-developers who come around
and want to give Shindig whirl will simply want a complete running
example with the least effort involved to get started... fire it up,
point you browser to it and you're off...

Taking crossplatformability into consideration as a pre-req, I'd have to
say that I think it's far easier to grab a JDK, jetty (backed by JavaDB
transparently) seems the most logical approach.

At least that where my vote goes. 

JavaDB +1 (PS: I've never even used JavaDB before... it's just the
factor of simplicity, cause it's bundled with recent JDKs, that I'm
considering)

The end result might be that you emit more than one "bundle" from a
continuous build system... which, once setup is pretty trivial.

- An Apache HTTPD target bundle, based on PHP/CouchDB
- A Java bundle, based on Jetty/JavaDB
- A Perl bundle...
- A ROR bundle...


Ray

On Wed, 2008-04-16 at 10:10 -0700, Vasu Nori wrote:

> let me put this proposal to vote.
> 
> Reference implementation of Opensocial API server (in java) should provide
> backend implementation for
>  (1) file system
>  (2) JavaDB
>  (3) CouchDB
>  (4) all the above
> 
> If you voted for any one of the these, how about volunteering? :)
> I can volunteer for (2).
> (1) already exists in Shindig. Could use help in adding/deleting/updating
> data. Right now, Shindig already implements SELECT on data.
> 
> thanks
> 
> On Tue, Apr 15, 2008 at 10:46 PM, Santiago Gala <sa...@gmail.com>
> wrote:
> 
> > El mar, 15-04-2008 a las 16:52 -0700, Kevin Brown escribió:
> > > Couldn't SQLite serve the same role?
> >
> > Of course. SQLite or Derby (embedded in the java server) or any
> > relational DB with the proper scripts for creation of the demo DB.
> >
> > I pointed at CouchDB because:
> > - it has a json on HTTP wire format used with a ReST API, i.e., it can
> > be mapped to directly serve what we want here.
> > - it is programmed using javascript in the server, i.e., quite natural
> > for people coding gadgets. (See for instance
> > http://wiki.apache.org/couchdb/GettingStartedWithJavaScript )
> > - it is designed as a "new breed" DB, easy to replicate and scale
> > - they joined incubation close to when shindig did, so they are
> > "neighbors" :)
> > - I wanted to be provocative and point to something quite out of the
> > ordinary
> >
> > I specifically told about "prototyping", as I was thinking that it might
> > be quite useful for someone working on the right interfaces and formats
> > to use such a tool. I was thinking about writing a quick snippet of code
> > and testing on the fly. I don't think it is the right thing for
> > production right now, as it might scare people.
> >
> > Regards
> > Santiago
> >
> > >
> > > On Tue, Apr 15, 2008 at 3:56 PM, Santiago Gala <sa...@gmail.com>
> > > wrote:
> > >
> > > > El mar, 15-04-2008 a las 23:35 +0100, Ian Boston escribió:
> > > > > I don't know enough about CouchDB to say if its a good solution, but
> > > > > am I correct in thinking its another server to setup and wont run in
> > > > > the same JVM as the Shindig instance ? (Looking at the svn it see c
> > > > > code, and mention of mod_couch ... sounds like it needs apache httpd
> > > > > to run ).
> > > >
> > > > It does not. It won't run in the same JVM as Shindig,... because it is
> > > > not java.  mod_couch is an erlang module. CouchDB is written in
> > Erlang
> > > > + C (the javascript interpreter and the glue).
> > > >
> > > > >
> > > > > To make it really easy for someone to take a Shindig instance out of
> > > > > the box, the approach that Jackrabbit took might be worth following.
> > > > > They used a default DB of Derby, which didn't need any config, as it
> > > > > will run embedded. This also allowed them to make the TCK run all
> > its
> > > > > tests inside maven without additional config.
> > > > >
> > > >
> > > > You are assuming that everybody wants to run java, which is not
> > > > something you are so free to assume, specially in this field. CouchDB
> > is
> > > > a DB that uses json as native wire format and javascript as backend
> > > > language, which makes it have an excellent impedance with shindig as
> > it
> > > > might serve straight from the DB. While it is a very young project, I
> > > > just mentioned its use for prototyping of the social stuff.
> > > >
> > > >
> > > > > This may all be small point, since I see that Abdera has a number of
> > > > > other ColectionAdapters including iBatis, Hibernate and even JCR.
> > > > >
> > > > > --------------
> > > > >
> > > > > Another quick question.
> > > > >
> > > > > With the REST api being implemented, is there any point in
> > > > > implementing the Services (eg PeopleService) that exist in the
> > > > > current code base against a DB backend .... or will they be
> > > > > deprecated shortly (within 4 weeks)
> > > > >
> > > > >
> > > > >
> > > > > Ian
> > > > >
> > > > >
> > > > >
> > > > > On 15 Apr 2008, at 17:28, Jun Yang (杨骏) wrote:
> > > > > > On Tue, Apr 15, 2008 at 7:30 AM, Santiago Gala
> > > > > > <sa...@gmail.com>
> > > > > > wrote:
> > > > > >
> > > > > >> El mar, 15-04-2008 a las 03:59 -0700, Kevin Brown escribió:
> > > > > >>> On Tue, Apr 15, 2008 at 2:54 AM, Ian Boston <ie...@tfd.co.uk>
> > wrote:
> > > > > >>>
> > > > > >>>> Is the intention with the rest based apis for opensocial in
> > > > > >>>> shindig to
> > > > > >>>> just provide the JS client libraries and leave the
> > > > > >>>> implementation  of
> > > > > >> the
> > > > > >>>> server side of the api to the implementor.
> > > > > >>
> > > > > >
> > > > > > Yes.
> > > > > >
> > > > > >
> > > > > >>>> or
> > > > > >>>>
> > > > > >>>> will Shindig be implementing a rest based server component,
> > with DB
> > > > > >>>> backend
> > > > > >>
> > > > > >
> > > > > > The first version will come with good support for relational
> > > > > > databases, as
> > > > > > is the common case.
> > > > > >
> > > > > >
> > > > > >> I wonder if using a very simple CouchDB backend could make sense.
> > > > > >> CouchDB offers a DB with native json API and javascript running
> > in
> > > > > >> the
> > > > > >> server, so at least propotype support for initial experiments.
> > > > > >>
> > > > > >
> > > > > > Since the server is based on Abdera and Abdera already has an
> > > > > > adapter for
> > > > > > CouchDB, this should be easy.
> > > > > >
> > > > > > Jun
> > > > > >
> > > > > > It looks a great tool for this, though for a prototype python +
> > > > > >> simplejson + some dictionaries can actually be a similar very
> > simple
> > > > > >> framework. Or s/python/<your favorite dynamic language>/ :)
> > > > > >>
> > > > > >>>
> > > > > >>> RESTful APIs are in development now, though nothing has been
> > > > > >>> committed
> > > > > >> yet.
> > > > > >>> See mail archives for discussion. I'd expect the first commit
> > > > > >>> within the
> > > > > >>> next week or two at most. The RESTful  spec was just finalized
> > > > > >>> last week
> > > > > >> --
> > > > > >>> we need a little time! :)
> > > > > >>>
> > > > > >>> Also, is there any intention to use POST on the rest URL's to do
> > > > > >>> updates
> > > > > >> to
> > > > > >>>> social data where it makes sense... sorry if this has been
> > > > > >>>> mentioned
> > > > > >>>> already.
> > > > > >>>
> > > > > >>>
> > > > > >>> We'll do whatever the spec requires.
> > > > > >>>
> > > > > >>
> > > > > >> +1, ReST requires POST/PUT for non-idempotent request, and
> > > > > >> *updates* are
> > > > > >> always non-idempotent. Even if I'm not following the spec right
> > > > > >> now, I
> > > > > >> would be very surprised if the spec used GET for updates. But
> > > > > >> this, as
> > > > > >> Kevin said, belongs to the spec ground.
> > > > > >>
> > > > > >> --
> > > > > >> Santiago Gala
> > > > > >> http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/blog/><
> > http://memojo.com/%7Esgala/blog/> <
> > > > http://memojo.com/%7Esgala/blog/>
> > > > > >>
> > > > > >>
> > > > >
> > > > --
> > > > Santiago Gala
> > > > http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/blog/> <
> > http://memojo.com/%7Esgala/blog/>
> > > >
> > > >
> > >
> > >
> > --
> > Santiago Gala
> > http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/blog/>
> >
> >

Raymond Augé
Software Engineer
Liferay, Inc.
Enterprise. Open Source. For Life.

Re: question: social rest api's

Posted by Kevin Brown <et...@google.com>.
On Wed, Apr 16, 2008 at 10:10 AM, Vasu Nori <vn...@google.com> wrote:

> let me put this proposal to vote.
>
> Reference implementation of Opensocial API server (in java) should provide
> backend implementation for
>  (1) file system
>  (2) JavaDB
>  (3) CouchDB
>  (4) all the above
>
> If you voted for any one of the these, how about volunteering? :)
> I can volunteer for (2).
> (1) already exists in Shindig. Could use help in adding/deleting/updating
> data. Right now, Shindig already implements SELECT on data.


There's really no need to worry about doing a whole bunch of implementations
right now. Get the core stuff working with at least one implementation well,
and if the interfaces are well structured others can layer whatever they
need. Making various implementations available as separate "plug ins" (or
service providers, if you will) would probably be ideal.


>
>
> thanks
>
> On Tue, Apr 15, 2008 at 10:46 PM, Santiago Gala <sa...@gmail.com>
> wrote:
>
> > El mar, 15-04-2008 a las 16:52 -0700, Kevin Brown escribió:
> > > Couldn't SQLite serve the same role?
> >
> > Of course. SQLite or Derby (embedded in the java server) or any
> > relational DB with the proper scripts for creation of the demo DB.
> >
> > I pointed at CouchDB because:
> > - it has a json on HTTP wire format used with a ReST API, i.e., it can
> > be mapped to directly serve what we want here.
> > - it is programmed using javascript in the server, i.e., quite natural
> > for people coding gadgets. (See for instance
> > http://wiki.apache.org/couchdb/GettingStartedWithJavaScript )
> > - it is designed as a "new breed" DB, easy to replicate and scale
> > - they joined incubation close to when shindig did, so they are
> > "neighbors" :)
> > - I wanted to be provocative and point to something quite out of the
> > ordinary
> >
> > I specifically told about "prototyping", as I was thinking that it might
> > be quite useful for someone working on the right interfaces and formats
> > to use such a tool. I was thinking about writing a quick snippet of code
> > and testing on the fly. I don't think it is the right thing for
> > production right now, as it might scare people.
> >
> > Regards
> > Santiago
> >
> > >
> > > On Tue, Apr 15, 2008 at 3:56 PM, Santiago Gala <
> santiago.gala@gmail.com>
> > > wrote:
> > >
> > > > El mar, 15-04-2008 a las 23:35 +0100, Ian Boston escribió:
> > > > > I don't know enough about CouchDB to say if its a good solution,
> but
> > > > > am I correct in thinking its another server to setup and wont run
> in
> > > > > the same JVM as the Shindig instance ? (Looking at the svn it see
> c
> > > > > code, and mention of mod_couch ... sounds like it needs apache
> httpd
> > > > > to run ).
> > > >
> > > > It does not. It won't run in the same JVM as Shindig,... because it
> is
> > > > not java.  mod_couch is an erlang module. CouchDB is written in
> > Erlang
> > > > + C (the javascript interpreter and the glue).
> > > >
> > > > >
> > > > > To make it really easy for someone to take a Shindig instance out
> of
> > > > > the box, the approach that Jackrabbit took might be worth
> following.
> > > > > They used a default DB of Derby, which didn't need any config, as
> it
> > > > > will run embedded. This also allowed them to make the TCK run all
> > its
> > > > > tests inside maven without additional config.
> > > > >
> > > >
> > > > You are assuming that everybody wants to run java, which is not
> > > > something you are so free to assume, specially in this field.
> CouchDB
> > is
> > > > a DB that uses json as native wire format and javascript as backend
> > > > language, which makes it have an excellent impedance with shindig as
> > it
> > > > might serve straight from the DB. While it is a very young project,
> I
> > > > just mentioned its use for prototyping of the social stuff.
> > > >
> > > >
> > > > > This may all be small point, since I see that Abdera has a number
> of
> > > > > other ColectionAdapters including iBatis, Hibernate and even JCR.
> > > > >
> > > > > --------------
> > > > >
> > > > > Another quick question.
> > > > >
> > > > > With the REST api being implemented, is there any point in
> > > > > implementing the Services (eg PeopleService) that exist in the
> > > > > current code base against a DB backend .... or will they be
> > > > > deprecated shortly (within 4 weeks)
> > > > >
> > > > >
> > > > >
> > > > > Ian
> > > > >
> > > > >
> > > > >
> > > > > On 15 Apr 2008, at 17:28, Jun Yang (杨骏) wrote:
> > > > > > On Tue, Apr 15, 2008 at 7:30 AM, Santiago Gala
> > > > > > <sa...@gmail.com>
> > > > > > wrote:
> > > > > >
> > > > > >> El mar, 15-04-2008 a las 03:59 -0700, Kevin Brown escribió:
> > > > > >>> On Tue, Apr 15, 2008 at 2:54 AM, Ian Boston <ie...@tfd.co.uk>
> > wrote:
> > > > > >>>
> > > > > >>>> Is the intention with the rest based apis for opensocial in
> > > > > >>>> shindig to
> > > > > >>>> just provide the JS client libraries and leave the
> > > > > >>>> implementation  of
> > > > > >> the
> > > > > >>>> server side of the api to the implementor.
> > > > > >>
> > > > > >
> > > > > > Yes.
> > > > > >
> > > > > >
> > > > > >>>> or
> > > > > >>>>
> > > > > >>>> will Shindig be implementing a rest based server component,
> > with DB
> > > > > >>>> backend
> > > > > >>
> > > > > >
> > > > > > The first version will come with good support for relational
> > > > > > databases, as
> > > > > > is the common case.
> > > > > >
> > > > > >
> > > > > >> I wonder if using a very simple CouchDB backend could make
> sense.
> > > > > >> CouchDB offers a DB with native json API and javascript running
> > in
> > > > > >> the
> > > > > >> server, so at least propotype support for initial experiments.
> > > > > >>
> > > > > >
> > > > > > Since the server is based on Abdera and Abdera already has an
> > > > > > adapter for
> > > > > > CouchDB, this should be easy.
> > > > > >
> > > > > > Jun
> > > > > >
> > > > > > It looks a great tool for this, though for a prototype python +
> > > > > >> simplejson + some dictionaries can actually be a similar very
> > simple
> > > > > >> framework. Or s/python/<your favorite dynamic language>/ :)
> > > > > >>
> > > > > >>>
> > > > > >>> RESTful APIs are in development now, though nothing has been
> > > > > >>> committed
> > > > > >> yet.
> > > > > >>> See mail archives for discussion. I'd expect the first commit
> > > > > >>> within the
> > > > > >>> next week or two at most. The RESTful  spec was just finalized
> > > > > >>> last week
> > > > > >> --
> > > > > >>> we need a little time! :)
> > > > > >>>
> > > > > >>> Also, is there any intention to use POST on the rest URL's to
> do
> > > > > >>> updates
> > > > > >> to
> > > > > >>>> social data where it makes sense... sorry if this has been
> > > > > >>>> mentioned
> > > > > >>>> already.
> > > > > >>>
> > > > > >>>
> > > > > >>> We'll do whatever the spec requires.
> > > > > >>>
> > > > > >>
> > > > > >> +1, ReST requires POST/PUT for non-idempotent request, and
> > > > > >> *updates* are
> > > > > >> always non-idempotent. Even if I'm not following the spec right
> > > > > >> now, I
> > > > > >> would be very surprised if the spec used GET for updates. But
> > > > > >> this, as
> > > > > >> Kevin said, belongs to the spec ground.
> > > > > >>
> > > > > >> --
> > > > > >> Santiago Gala
> > > > > >> http://memojo.com/~sgala/blog/<http://memojo.com/%7Esgala/blog/><
> http://memojo.com/%7Esgala/blog/><
> > http://memojo.com/%7Esgala/blog/> <
> > > > http://memojo.com/%7Esgala/blog/>
> > > > > >>
> > > > > >>
> > > > >
> > > > --
> > > > Santiago Gala
> > > > http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/blog/> <
> http://memojo.com/%7Esgala/blog/> <
> > http://memojo.com/%7Esgala/blog/>
> > > >
> > > >
> > >
> > >
> > --
> > Santiago Gala
> > http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/blog/> <
> http://memojo.com/%7Esgala/blog/>
> >
> >
>



-- 
~Kevin

Re: question: social rest api's

Posted by Ian Boston <ie...@tfd.co.uk>.
Very quick update,
I have a first pass at a DB based datamodel using all the entities  
and attributes in the social model. I am using Cayenne and Derby, but  
it should be applicable to most databases. This is a totally separate  
module from social-api since there are clean service boundaries.

I trust no one has a problem with Cayenne as a ORM. When I looked at  
the size of the model it started to make sense rather than hand  
coding jdbc.
Ian



On 16 Apr 2008, at 18:44, Vasu Nori wrote:
> On Wed, Apr 16, 2008 at 10:25 AM, Ian Boston <ie...@tfd.co.uk> wrote:
>
>> +1 for 2, and willing to work on 2 (infact I need to anyway), but  
>> would
>> like to put sufficient abstraction in to make 1,2,3 all work.
>
> you are it for JavaDB impl
>
>>
>>

Re: question: social rest api's

Posted by Ian Boston <ie...@tfd.co.uk>.
Ok, cool, much clearer now, thanks.

I will generate something for the DB impl., in the next 24-48h.

Ian



On 16 Apr 2008, at 18:44, Vasu Nori wrote:
> On Wed, Apr 16, 2008 at 10:25 AM, Ian Boston <ie...@tfd.co.uk> wrote:
>
>> +1 for 2, and willing to work on 2 (infact I need to anyway), but  
>> would
>> like to put sufficient abstraction in to make 1,2,3 all work.
>
> you are it for JavaDB impl
>
>>
>>
>> and sorry to be confused and a pain, but the code base as of  
>> r648723 has
>> PeopleService, ActivitiesService and DataService.... are we  
>> talking about
>> implementing (2),(3) versions of (1) [as listed below] as it  
>> exists now,  or
>> , a new impl of the restful API ontop of Abdera which potentially  
>> would not
>> use PeopleService, ActivitiesService and DataService at all.
>>
> sorry, I wasn't clear. let me explain. (this is about java  
> implmentation.
> not sure if it will be directly applicable to php/any other lang)
>
> I am talking about enhancing the current interfaces in
> org.apache.shindig.social.opensocial package for People/Activities/ 
> Data to
> handle RESTful API.
>
> Right now, shindig implementation has an impl class  
> XmlStateFileFetcher.java
> to READ (xml file with data) from a filesystem.  It reads data to  
> fulfill
> various RETRIEVE requests for People/Activities/Data.
>
> To implement backend for RESTful API,
> The interfaces in org.apache.shindig.social.opensocial package are  
> to be
> enhanced to include methods to Retrieve a single entity for the given
> criteria, Insert/Update/Delete a single entity. (Signatures for these
> methods are not completely defined yet. but hopefully within a week)
>
> and then implement the following
>
>    1. *Filesystem *impl ( needs augmenting the current
>    XmlStateFileFetcher.java to handle Insert/Update/Delete to  
> correspond with
>    Post/Put/Delete Restful operations, respectively.
>    2. For *JavaDB and CouchDB*, we need NEW impl classes to handle
>    Select/Insert/Update/Delete. Select can be a single entity (for  
> RESTful API)
>    or it can return 0 or more entities (to correspond with the current
>    social-api in Shindig).
>
> hope it is clearer now..
>
> thanks
>
>
>
>> Just trying to get the layers clear in my head.
>>
>> Ian
>>
>>
>>
>>
>> On 16 Apr 2008, at 18:10, Vasu Nori wrote:
>>
>>> let me put this proposal to vote.
>>>
>>> Reference implementation of Opensocial API server (in java) should
>>> provide
>>> backend implementation for
>>>  (1) file system
>>>  (2) JavaDB
>>>  (3) CouchDB
>>>  (4) all the above
>>>
>>> If you voted for any one of the these, how about volunteering? :)
>>> I can volunteer for (2).
>>> (1) already exists in Shindig. Could use help in
>>> adding/deleting/updating
>>> data. Right now, Shindig already implements SELECT on data.
>>>
>>> thanks
>>>
>>> On Tue, Apr 15, 2008 at 10:46 PM, Santiago Gala  
>>> <santiago.gala@gmail.com
>>>>
>>> wrote:
>>>
>>>  El mar, 15-04-2008 a las 16:52 -0700, Kevin Brown escribió:
>>>>
>>>>> Couldn't SQLite serve the same role?
>>>>>
>>>>
>>>> Of course. SQLite or Derby (embedded in the java server) or any
>>>> relational DB with the proper scripts for creation of the demo DB.
>>>>
>>>> I pointed at CouchDB because:
>>>> - it has a json on HTTP wire format used with a ReST API, i.e.,  
>>>> it can
>>>> be mapped to directly serve what we want here.
>>>> - it is programmed using javascript in the server, i.e., quite  
>>>> natural
>>>> for people coding gadgets. (See for instance
>>>> http://wiki.apache.org/couchdb/GettingStartedWithJavaScript )
>>>> - it is designed as a "new breed" DB, easy to replicate and scale
>>>> - they joined incubation close to when shindig did, so they are
>>>> "neighbors" :)
>>>> - I wanted to be provocative and point to something quite out of  
>>>> the
>>>> ordinary
>>>>
>>>> I specifically told about "prototyping", as I was thinking that it
>>>> might
>>>> be quite useful for someone working on the right interfaces and
>>>> formats
>>>> to use such a tool. I was thinking about writing a quick snippet of
>>>> code
>>>> and testing on the fly. I don't think it is the right thing for
>>>> production right now, as it might scare people.
>>>>
>>>> Regards
>>>> Santiago
>>>>
>>>>
>>>>> On Tue, Apr 15, 2008 at 3:56 PM, Santiago Gala <
>>>>> santiago.gala@gmail.com>
>>>>> wrote:
>>>>>
>>>>>  El mar, 15-04-2008 a las 23:35 +0100, Ian Boston escribió:
>>>>>>
>>>>>>> I don't know enough about CouchDB to say if its a good solution,
>>>>>>> but
>>>>>>> am I correct in thinking its another server to setup and wont
>>>>>>> run in
>>>>>>> the same JVM as the Shindig instance ? (Looking at the svn it
>>>>>>> see c
>>>>>>> code, and mention of mod_couch ... sounds like it needs apache
>>>>>>> httpd
>>>>>>> to run ).
>>>>>>>
>>>>>>
>>>>>> It does not. It won't run in the same JVM as Shindig,... because
>>>>>> it is
>>>>>> not java. mod_couch is an erlang module. CouchDB is written in
>>>>>>
>>>>> Erlang
>>>>
>>>>> + C (the javascript interpreter and the glue).
>>>>>>
>>>>>>
>>>>>>> To make it really easy for someone to take a Shindig instance
>>>>>>> out of
>>>>>>> the box, the approach that Jackrabbit took might be worth
>>>>>>> following.
>>>>>>> They used a default DB of Derby, which didn't need any config,
>>>>>>> as it
>>>>>>> will run embedded. This also allowed them to make the TCK run
>>>>>>> all
>>>>>>>
>>>>>> its
>>>>
>>>>> tests inside maven without additional config.
>>>>>>>
>>>>>>>
>>>>>> You are assuming that everybody wants to run java, which is not
>>>>>> something you are so free to assume, specially in this field.
>>>>>> CouchDB
>>>>>>
>>>>> is
>>>>
>>>>> a DB that uses json as native wire format and javascript as  
>>>>> backend
>>>>>> language, which makes it have an excellent impedance with shindig
>>>>>> as
>>>>>>
>>>>> it
>>>>
>>>>> might serve straight from the DB. While it is a very young  
>>>>> project,
>>>>>> I
>>>>>> just mentioned its use for prototyping of the social stuff.
>>>>>>
>>>>>>
>>>>>>  This may all be small point, since I see that Abdera has a  
>>>>>> number
>>>>>>> of
>>>>>>> other ColectionAdapters including iBatis, Hibernate and even
>>>>>>> JCR.
>>>>>>>
>>>>>>> --------------
>>>>>>>
>>>>>>> Another quick question.
>>>>>>>
>>>>>>> With the REST api being implemented, is there any point in
>>>>>>> implementing the Services (eg PeopleService) that exist in the
>>>>>>> current code base against a DB backend .... or will they be
>>>>>>> deprecated shortly (within 4 weeks)
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> Ian
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> On 15 Apr 2008, at 17:28, Jun Yang (杨骏) wrote:
>>>>>>>
>>>>>>>> On Tue, Apr 15, 2008 at 7:30 AM, Santiago Gala
>>>>>>>> <sa...@gmail.com>
>>>>>>>> wrote:
>>>>>>>>
>>>>>>>>  El mar, 15-04-2008 a las 03:59 -0700, Kevin Brown escribió:
>>>>>>>>>
>>>>>>>>>> On Tue, Apr 15, 2008 at 2:54 AM, Ian Boston <ieb@tfd.co.uk
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>> wrote:
>>>>
>>>>>
>>>>>>>>>>  Is the intention with the rest based apis for opensocial
>>>>>>>>>>> in
>>>>>>>>>>> shindig to
>>>>>>>>>>> just provide the JS client libraries and leave the
>>>>>>>>>>> implementation  of
>>>>>>>>>>>
>>>>>>>>>> the
>>>>>>>>>
>>>>>>>>>> server side of the api to the implementor.
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>> Yes.
>>>>>>>>
>>>>>>>>
>>>>>>>>  or
>>>>>>>>>>>
>>>>>>>>>>> will Shindig be implementing a rest based server
>>>>>>>>>>> component,
>>>>>>>>>>>
>>>>>>>>>> with DB
>>>>
>>>>> backend
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>> The first version will come with good support for relational
>>>>>>>> databases, as
>>>>>>>> is the common case.
>>>>>>>>
>>>>>>>>
>>>>>>>>  I wonder if using a very simple CouchDB backend could make
>>>>>>>>> sense.
>>>>>>>>> CouchDB offers a DB with native json API and javascript
>>>>>>>>> running
>>>>>>>>>
>>>>>>>> in
>>>>
>>>>> the
>>>>>>>>> server, so at least propotype support for initial
>>>>>>>>> experiments.
>>>>>>>>>
>>>>>>>>>
>>>>>>>> Since the server is based on Abdera and Abdera already has an
>>>>>>>> adapter for
>>>>>>>> CouchDB, this should be easy.
>>>>>>>>
>>>>>>>> Jun
>>>>>>>>
>>>>>>>> It looks a great tool for this, though for a prototype python
>>>>>>>> +
>>>>>>>>
>>>>>>>>> simplejson + some dictionaries can actually be a similar
>>>>>>>>> very
>>>>>>>>>
>>>>>>>> simple
>>>>
>>>>> framework. Or s/python/<your favorite dynamic language>/ :)
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>> RESTful APIs are in development now, though nothing has
>>>>>>>>>> been
>>>>>>>>>> committed
>>>>>>>>>>
>>>>>>>>> yet.
>>>>>>>>>
>>>>>>>>>> See mail archives for discussion. I'd expect the first
>>>>>>>>>> commit
>>>>>>>>>> within the
>>>>>>>>>> next week or two at most. The RESTful  spec was just
>>>>>>>>>> finalized
>>>>>>>>>> last week
>>>>>>>>>>
>>>>>>>>> --
>>>>>>>>>
>>>>>>>>>> we need a little time! :)
>>>>>>>>>>
>>>>>>>>>> Also, is there any intention to use POST on the rest URL's
>>>>>>>>>> to do
>>>>>>>>>> updates
>>>>>>>>>>
>>>>>>>>> to
>>>>>>>>>
>>>>>>>>>> social data where it makes sense... sorry if this has been
>>>>>>>>>>> mentioned
>>>>>>>>>>> already.
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> We'll do whatever the spec requires.
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>> +1, ReST requires POST/PUT for non-idempotent request, and
>>>>>>>>> *updates* are
>>>>>>>>> always non-idempotent. Even if I'm not following the spec
>>>>>>>>> right
>>>>>>>>> now, I
>>>>>>>>> would be very surprised if the spec used GET for updates.
>>>>>>>>> But
>>>>>>>>> this, as
>>>>>>>>> Kevin said, belongs to the spec ground.
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> Santiago Gala
>>>>>>>>> http://memojo.com/~sgala/blog/<http://memojo.com/%7Esgala/ 
>>>>>>>>> blog/><
>>>>>>>>> http://memojo.com/%7Esgala/blog/><
>>>>>>>>>
>>>>>>>> http://memojo.com/%7Esgala/blog/> <
>>>>
>>>>> http://memojo.com/%7Esgala/blog/>
>>>>>>
>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>  --
>>>>>> Santiago Gala
>>>>>> http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/ 
>>>>>> blog/><
>>>>>> http://memojo.com/%7Esgala/blog/> <
>>>>>>
>>>>> http://memojo.com/%7Esgala/blog/>
>>>>
>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>>  --
>>>> Santiago Gala
>>>> http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/blog/> <
>>>> http://memojo.com/%7Esgala/blog/>
>>>>
>>>>
>>>>
>>


Re: question: social rest api's

Posted by Vasu Nori <vn...@google.com>.
On Wed, Apr 16, 2008 at 10:25 AM, Ian Boston <ie...@tfd.co.uk> wrote:

> +1 for 2, and willing to work on 2 (infact I need to anyway), but would
> like to put sufficient abstraction in to make 1,2,3 all work.

you are it for JavaDB impl

>
>
> and sorry to be confused and a pain, but the code base as of r648723 has
> PeopleService, ActivitiesService and DataService.... are we talking about
> implementing (2),(3) versions of (1) [as listed below] as it exists now,  or
> , a new impl of the restful API ontop of Abdera which potentially would not
> use PeopleService, ActivitiesService and DataService at all.
>
sorry, I wasn't clear. let me explain. (this is about java implmentation.
not sure if it will be directly applicable to php/any other lang)

I am talking about enhancing the current interfaces in
org.apache.shindig.social.opensocial package for People/Activities/Data to
handle RESTful API.

Right now, shindig implementation has an impl class XmlStateFileFetcher.java
to READ (xml file with data) from a filesystem.  It reads data to fulfill
various RETRIEVE requests for People/Activities/Data.

To implement backend for RESTful API,
The interfaces in org.apache.shindig.social.opensocial package are to be
enhanced to include methods to Retrieve a single entity for the given
criteria, Insert/Update/Delete a single entity. (Signatures for these
methods are not completely defined yet. but hopefully within a week)

and then implement the following

   1. *Filesystem *impl ( needs augmenting the current
   XmlStateFileFetcher.java to handle Insert/Update/Delete to correspond with
   Post/Put/Delete Restful operations, respectively.
   2. For *JavaDB and CouchDB*, we need NEW impl classes to handle
   Select/Insert/Update/Delete. Select can be a single entity (for RESTful API)
   or it can return 0 or more entities (to correspond with the current
   social-api in Shindig).

hope it is clearer now..

thanks



> Just trying to get the layers clear in my head.
>
> Ian
>
>
>
>
> On 16 Apr 2008, at 18:10, Vasu Nori wrote:
>
> > let me put this proposal to vote.
> >
> > Reference implementation of Opensocial API server (in java) should
> > provide
> > backend implementation for
> >  (1) file system
> >  (2) JavaDB
> >  (3) CouchDB
> >  (4) all the above
> >
> > If you voted for any one of the these, how about volunteering? :)
> > I can volunteer for (2).
> > (1) already exists in Shindig. Could use help in
> > adding/deleting/updating
> > data. Right now, Shindig already implements SELECT on data.
> >
> > thanks
> >
> > On Tue, Apr 15, 2008 at 10:46 PM, Santiago Gala <santiago.gala@gmail.com
> > >
> > wrote:
> >
> >  El mar, 15-04-2008 a las 16:52 -0700, Kevin Brown escribió:
> > >
> > > > Couldn't SQLite serve the same role?
> > > >
> > >
> > > Of course. SQLite or Derby (embedded in the java server) or any
> > > relational DB with the proper scripts for creation of the demo DB.
> > >
> > > I pointed at CouchDB because:
> > > - it has a json on HTTP wire format used with a ReST API, i.e., it can
> > > be mapped to directly serve what we want here.
> > > - it is programmed using javascript in the server, i.e., quite natural
> > > for people coding gadgets. (See for instance
> > > http://wiki.apache.org/couchdb/GettingStartedWithJavaScript )
> > > - it is designed as a "new breed" DB, easy to replicate and scale
> > > - they joined incubation close to when shindig did, so they are
> > > "neighbors" :)
> > > - I wanted to be provocative and point to something quite out of the
> > > ordinary
> > >
> > > I specifically told about "prototyping", as I was thinking that it
> > > might
> > > be quite useful for someone working on the right interfaces and
> > > formats
> > > to use such a tool. I was thinking about writing a quick snippet of
> > > code
> > > and testing on the fly. I don't think it is the right thing for
> > > production right now, as it might scare people.
> > >
> > > Regards
> > > Santiago
> > >
> > >
> > > > On Tue, Apr 15, 2008 at 3:56 PM, Santiago Gala <
> > > > santiago.gala@gmail.com>
> > > > wrote:
> > > >
> > > >  El mar, 15-04-2008 a las 23:35 +0100, Ian Boston escribió:
> > > > >
> > > > > > I don't know enough about CouchDB to say if its a good solution,
> > > > > > but
> > > > > > am I correct in thinking its another server to setup and wont
> > > > > > run in
> > > > > > the same JVM as the Shindig instance ? (Looking at the svn it
> > > > > > see c
> > > > > > code, and mention of mod_couch ... sounds like it needs apache
> > > > > > httpd
> > > > > > to run ).
> > > > > >
> > > > >
> > > > > It does not. It won't run in the same JVM as Shindig,... because
> > > > > it is
> > > > > not java. mod_couch is an erlang module. CouchDB is written in
> > > > >
> > > > Erlang
> > >
> > > > + C (the javascript interpreter and the glue).
> > > > >
> > > > >
> > > > > > To make it really easy for someone to take a Shindig instance
> > > > > > out of
> > > > > > the box, the approach that Jackrabbit took might be worth
> > > > > > following.
> > > > > > They used a default DB of Derby, which didn't need any config,
> > > > > > as it
> > > > > > will run embedded. This also allowed them to make the TCK run
> > > > > > all
> > > > > >
> > > > > its
> > >
> > > > tests inside maven without additional config.
> > > > > >
> > > > > >
> > > > > You are assuming that everybody wants to run java, which is not
> > > > > something you are so free to assume, specially in this field.
> > > > > CouchDB
> > > > >
> > > > is
> > >
> > > > a DB that uses json as native wire format and javascript as backend
> > > > > language, which makes it have an excellent impedance with shindig
> > > > > as
> > > > >
> > > > it
> > >
> > > > might serve straight from the DB. While it is a very young project,
> > > > > I
> > > > > just mentioned its use for prototyping of the social stuff.
> > > > >
> > > > >
> > > > >  This may all be small point, since I see that Abdera has a number
> > > > > > of
> > > > > > other ColectionAdapters including iBatis, Hibernate and even
> > > > > > JCR.
> > > > > >
> > > > > > --------------
> > > > > >
> > > > > > Another quick question.
> > > > > >
> > > > > > With the REST api being implemented, is there any point in
> > > > > > implementing the Services (eg PeopleService) that exist in the
> > > > > > current code base against a DB backend .... or will they be
> > > > > > deprecated shortly (within 4 weeks)
> > > > > >
> > > > > >
> > > > > >
> > > > > > Ian
> > > > > >
> > > > > >
> > > > > >
> > > > > > On 15 Apr 2008, at 17:28, Jun Yang (杨骏) wrote:
> > > > > >
> > > > > > > On Tue, Apr 15, 2008 at 7:30 AM, Santiago Gala
> > > > > > > <sa...@gmail.com>
> > > > > > > wrote:
> > > > > > >
> > > > > > >  El mar, 15-04-2008 a las 03:59 -0700, Kevin Brown escribió:
> > > > > > > >
> > > > > > > > > On Tue, Apr 15, 2008 at 2:54 AM, Ian Boston <ieb@tfd.co.uk
> > > > > > > > > >
> > > > > > > > >
> > > > > > > > wrote:
> > >
> > > >
> > > > > > > > >  Is the intention with the rest based apis for opensocial
> > > > > > > > > > in
> > > > > > > > > > shindig to
> > > > > > > > > > just provide the JS client libraries and leave the
> > > > > > > > > > implementation  of
> > > > > > > > > >
> > > > > > > > > the
> > > > > > > >
> > > > > > > > > server side of the api to the implementor.
> > > > > > > > > >
> > > > > > > > >
> > > > > > > >
> > > > > > > Yes.
> > > > > > >
> > > > > > >
> > > > > > >  or
> > > > > > > > > >
> > > > > > > > > > will Shindig be implementing a rest based server
> > > > > > > > > > component,
> > > > > > > > > >
> > > > > > > > > with DB
> > >
> > > > backend
> > > > > > > > > >
> > > > > > > > >
> > > > > > > >
> > > > > > > The first version will come with good support for relational
> > > > > > > databases, as
> > > > > > > is the common case.
> > > > > > >
> > > > > > >
> > > > > > >  I wonder if using a very simple CouchDB backend could make
> > > > > > > > sense.
> > > > > > > > CouchDB offers a DB with native json API and javascript
> > > > > > > > running
> > > > > > > >
> > > > > > > in
> > >
> > > > the
> > > > > > > > server, so at least propotype support for initial
> > > > > > > > experiments.
> > > > > > > >
> > > > > > > >
> > > > > > > Since the server is based on Abdera and Abdera already has an
> > > > > > > adapter for
> > > > > > > CouchDB, this should be easy.
> > > > > > >
> > > > > > > Jun
> > > > > > >
> > > > > > > It looks a great tool for this, though for a prototype python
> > > > > > > +
> > > > > > >
> > > > > > > > simplejson + some dictionaries can actually be a similar
> > > > > > > > very
> > > > > > > >
> > > > > > > simple
> > >
> > > > framework. Or s/python/<your favorite dynamic language>/ :)
> > > > > > > >
> > > > > > > >
> > > > > > > > > RESTful APIs are in development now, though nothing has
> > > > > > > > > been
> > > > > > > > > committed
> > > > > > > > >
> > > > > > > > yet.
> > > > > > > >
> > > > > > > > > See mail archives for discussion. I'd expect the first
> > > > > > > > > commit
> > > > > > > > > within the
> > > > > > > > > next week or two at most. The RESTful  spec was just
> > > > > > > > > finalized
> > > > > > > > > last week
> > > > > > > > >
> > > > > > > > --
> > > > > > > >
> > > > > > > > > we need a little time! :)
> > > > > > > > >
> > > > > > > > > Also, is there any intention to use POST on the rest URL's
> > > > > > > > > to do
> > > > > > > > > updates
> > > > > > > > >
> > > > > > > > to
> > > > > > > >
> > > > > > > > > social data where it makes sense... sorry if this has been
> > > > > > > > > > mentioned
> > > > > > > > > > already.
> > > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > We'll do whatever the spec requires.
> > > > > > > > >
> > > > > > > > >
> > > > > > > > +1, ReST requires POST/PUT for non-idempotent request, and
> > > > > > > > *updates* are
> > > > > > > > always non-idempotent. Even if I'm not following the spec
> > > > > > > > right
> > > > > > > > now, I
> > > > > > > > would be very surprised if the spec used GET for updates.
> > > > > > > > But
> > > > > > > > this, as
> > > > > > > > Kevin said, belongs to the spec ground.
> > > > > > > >
> > > > > > > > --
> > > > > > > > Santiago Gala
> > > > > > > > http://memojo.com/~sgala/blog/<http://memojo.com/%7Esgala/blog/><
> > > > > > > > http://memojo.com/%7Esgala/blog/><
> > > > > > > >
> > > > > > > http://memojo.com/%7Esgala/blog/> <
> > >
> > > > http://memojo.com/%7Esgala/blog/>
> > > > >
> > > > > >
> > > > > > > >
> > > > > > > >
> > > > > >  --
> > > > > Santiago Gala
> > > > > http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/blog/><
> > > > > http://memojo.com/%7Esgala/blog/> <
> > > > >
> > > > http://memojo.com/%7Esgala/blog/>
> > >
> > > >
> > > > >
> > > > >
> > > >
> > > >  --
> > > Santiago Gala
> > > http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/blog/> <
> > > http://memojo.com/%7Esgala/blog/>
> > >
> > >
> > >
>

Re: question: social rest api's

Posted by Ian Boston <ie...@tfd.co.uk>.
+1 for 2, and willing to work on 2 (infact I need to anyway), but  
would like to put sufficient abstraction in to make 1,2,3 all work.

and sorry to be confused and a pain, but the code base as of r648723  
has PeopleService, ActivitiesService and DataService.... are we  
talking about implementing (2),(3) versions of (1) [as listed below]  
as it exists now,  or , a new impl of the restful API ontop of Abdera  
which potentially would not use PeopleService, ActivitiesService and  
DataService at all.

Just trying to get the layers clear in my head.

Ian



On 16 Apr 2008, at 18:10, Vasu Nori wrote:
> let me put this proposal to vote.
>
> Reference implementation of Opensocial API server (in java) should  
> provide
> backend implementation for
>  (1) file system
>  (2) JavaDB
>  (3) CouchDB
>  (4) all the above
>
> If you voted for any one of the these, how about volunteering? :)
> I can volunteer for (2).
> (1) already exists in Shindig. Could use help in adding/deleting/ 
> updating
> data. Right now, Shindig already implements SELECT on data.
>
> thanks
>
> On Tue, Apr 15, 2008 at 10:46 PM, Santiago Gala  
> <sa...@gmail.com>
> wrote:
>
>> El mar, 15-04-2008 a las 16:52 -0700, Kevin Brown escribió:
>>> Couldn't SQLite serve the same role?
>>
>> Of course. SQLite or Derby (embedded in the java server) or any
>> relational DB with the proper scripts for creation of the demo DB.
>>
>> I pointed at CouchDB because:
>> - it has a json on HTTP wire format used with a ReST API, i.e., it  
>> can
>> be mapped to directly serve what we want here.
>> - it is programmed using javascript in the server, i.e., quite  
>> natural
>> for people coding gadgets. (See for instance
>> http://wiki.apache.org/couchdb/GettingStartedWithJavaScript )
>> - it is designed as a "new breed" DB, easy to replicate and scale
>> - they joined incubation close to when shindig did, so they are
>> "neighbors" :)
>> - I wanted to be provocative and point to something quite out of the
>> ordinary
>>
>> I specifically told about "prototyping", as I was thinking that it  
>> might
>> be quite useful for someone working on the right interfaces and  
>> formats
>> to use such a tool. I was thinking about writing a quick snippet  
>> of code
>> and testing on the fly. I don't think it is the right thing for
>> production right now, as it might scare people.
>>
>> Regards
>> Santiago
>>
>>>
>>> On Tue, Apr 15, 2008 at 3:56 PM, Santiago Gala  
>>> <sa...@gmail.com>
>>> wrote:
>>>
>>>> El mar, 15-04-2008 a las 23:35 +0100, Ian Boston escribió:
>>>>> I don't know enough about CouchDB to say if its a good  
>>>>> solution, but
>>>>> am I correct in thinking its another server to setup and wont  
>>>>> run in
>>>>> the same JVM as the Shindig instance ? (Looking at the svn it  
>>>>> see c
>>>>> code, and mention of mod_couch ... sounds like it needs apache  
>>>>> httpd
>>>>> to run ).
>>>>
>>>> It does not. It won't run in the same JVM as Shindig,... because  
>>>> it is
>>>> not java. mod_couch is an erlang module. CouchDB is written in
>> Erlang
>>>> + C (the javascript interpreter and the glue).
>>>>
>>>>>
>>>>> To make it really easy for someone to take a Shindig instance  
>>>>> out of
>>>>> the box, the approach that Jackrabbit took might be worth  
>>>>> following.
>>>>> They used a default DB of Derby, which didn't need any config,  
>>>>> as it
>>>>> will run embedded. This also allowed them to make the TCK run all
>> its
>>>>> tests inside maven without additional config.
>>>>>
>>>>
>>>> You are assuming that everybody wants to run java, which is not
>>>> something you are so free to assume, specially in this field.  
>>>> CouchDB
>> is
>>>> a DB that uses json as native wire format and javascript as backend
>>>> language, which makes it have an excellent impedance with  
>>>> shindig as
>> it
>>>> might serve straight from the DB. While it is a very young  
>>>> project, I
>>>> just mentioned its use for prototyping of the social stuff.
>>>>
>>>>
>>>>> This may all be small point, since I see that Abdera has a  
>>>>> number of
>>>>> other ColectionAdapters including iBatis, Hibernate and even JCR.
>>>>>
>>>>> --------------
>>>>>
>>>>> Another quick question.
>>>>>
>>>>> With the REST api being implemented, is there any point in
>>>>> implementing the Services (eg PeopleService) that exist in the
>>>>> current code base against a DB backend .... or will they be
>>>>> deprecated shortly (within 4 weeks)
>>>>>
>>>>>
>>>>>
>>>>> Ian
>>>>>
>>>>>
>>>>>
>>>>> On 15 Apr 2008, at 17:28, Jun Yang (杨骏) wrote:
>>>>>> On Tue, Apr 15, 2008 at 7:30 AM, Santiago Gala
>>>>>> <sa...@gmail.com>
>>>>>> wrote:
>>>>>>
>>>>>>> El mar, 15-04-2008 a las 03:59 -0700, Kevin Brown escribió:
>>>>>>>> On Tue, Apr 15, 2008 at 2:54 AM, Ian Boston <ie...@tfd.co.uk>
>> wrote:
>>>>>>>>
>>>>>>>>> Is the intention with the rest based apis for opensocial in
>>>>>>>>> shindig to
>>>>>>>>> just provide the JS client libraries and leave the
>>>>>>>>> implementation  of
>>>>>>> the
>>>>>>>>> server side of the api to the implementor.
>>>>>>>
>>>>>>
>>>>>> Yes.
>>>>>>
>>>>>>
>>>>>>>>> or
>>>>>>>>>
>>>>>>>>> will Shindig be implementing a rest based server component,
>> with DB
>>>>>>>>> backend
>>>>>>>
>>>>>>
>>>>>> The first version will come with good support for relational
>>>>>> databases, as
>>>>>> is the common case.
>>>>>>
>>>>>>
>>>>>>> I wonder if using a very simple CouchDB backend could make  
>>>>>>> sense.
>>>>>>> CouchDB offers a DB with native json API and javascript running
>> in
>>>>>>> the
>>>>>>> server, so at least propotype support for initial experiments.
>>>>>>>
>>>>>>
>>>>>> Since the server is based on Abdera and Abdera already has an
>>>>>> adapter for
>>>>>> CouchDB, this should be easy.
>>>>>>
>>>>>> Jun
>>>>>>
>>>>>> It looks a great tool for this, though for a prototype python +
>>>>>>> simplejson + some dictionaries can actually be a similar very
>> simple
>>>>>>> framework. Or s/python/<your favorite dynamic language>/ :)
>>>>>>>
>>>>>>>>
>>>>>>>> RESTful APIs are in development now, though nothing has been
>>>>>>>> committed
>>>>>>> yet.
>>>>>>>> See mail archives for discussion. I'd expect the first commit
>>>>>>>> within the
>>>>>>>> next week or two at most. The RESTful  spec was just finalized
>>>>>>>> last week
>>>>>>> --
>>>>>>>> we need a little time! :)
>>>>>>>>
>>>>>>>> Also, is there any intention to use POST on the rest URL's  
>>>>>>>> to do
>>>>>>>> updates
>>>>>>> to
>>>>>>>>> social data where it makes sense... sorry if this has been
>>>>>>>>> mentioned
>>>>>>>>> already.
>>>>>>>>
>>>>>>>>
>>>>>>>> We'll do whatever the spec requires.
>>>>>>>>
>>>>>>>
>>>>>>> +1, ReST requires POST/PUT for non-idempotent request, and
>>>>>>> *updates* are
>>>>>>> always non-idempotent. Even if I'm not following the spec right
>>>>>>> now, I
>>>>>>> would be very surprised if the spec used GET for updates. But
>>>>>>> this, as
>>>>>>> Kevin said, belongs to the spec ground.
>>>>>>>
>>>>>>> --
>>>>>>> Santiago Gala
>>>>>>> http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/ 
>>>>>>> blog/><
>> http://memojo.com/%7Esgala/blog/> <
>>>> http://memojo.com/%7Esgala/blog/>
>>>>>>>
>>>>>>>
>>>>>
>>>> --
>>>> Santiago Gala
>>>> http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/blog/> <
>> http://memojo.com/%7Esgala/blog/>
>>>>
>>>>
>>>
>>>
>> --
>> Santiago Gala
>> http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/blog/>
>>
>>


Re: question: social rest api's

Posted by Vasu Nori <vn...@google.com>.
let me put this proposal to vote.

Reference implementation of Opensocial API server (in java) should provide
backend implementation for
 (1) file system
 (2) JavaDB
 (3) CouchDB
 (4) all the above

If you voted for any one of the these, how about volunteering? :)
I can volunteer for (2).
(1) already exists in Shindig. Could use help in adding/deleting/updating
data. Right now, Shindig already implements SELECT on data.

thanks

On Tue, Apr 15, 2008 at 10:46 PM, Santiago Gala <sa...@gmail.com>
wrote:

> El mar, 15-04-2008 a las 16:52 -0700, Kevin Brown escribió:
> > Couldn't SQLite serve the same role?
>
> Of course. SQLite or Derby (embedded in the java server) or any
> relational DB with the proper scripts for creation of the demo DB.
>
> I pointed at CouchDB because:
> - it has a json on HTTP wire format used with a ReST API, i.e., it can
> be mapped to directly serve what we want here.
> - it is programmed using javascript in the server, i.e., quite natural
> for people coding gadgets. (See for instance
> http://wiki.apache.org/couchdb/GettingStartedWithJavaScript )
> - it is designed as a "new breed" DB, easy to replicate and scale
> - they joined incubation close to when shindig did, so they are
> "neighbors" :)
> - I wanted to be provocative and point to something quite out of the
> ordinary
>
> I specifically told about "prototyping", as I was thinking that it might
> be quite useful for someone working on the right interfaces and formats
> to use such a tool. I was thinking about writing a quick snippet of code
> and testing on the fly. I don't think it is the right thing for
> production right now, as it might scare people.
>
> Regards
> Santiago
>
> >
> > On Tue, Apr 15, 2008 at 3:56 PM, Santiago Gala <sa...@gmail.com>
> > wrote:
> >
> > > El mar, 15-04-2008 a las 23:35 +0100, Ian Boston escribió:
> > > > I don't know enough about CouchDB to say if its a good solution, but
> > > > am I correct in thinking its another server to setup and wont run in
> > > > the same JVM as the Shindig instance ? (Looking at the svn it see c
> > > > code, and mention of mod_couch ... sounds like it needs apache httpd
> > > > to run ).
> > >
> > > It does not. It won't run in the same JVM as Shindig,... because it is
> > > not java.  mod_couch is an erlang module. CouchDB is written in
> Erlang
> > > + C (the javascript interpreter and the glue).
> > >
> > > >
> > > > To make it really easy for someone to take a Shindig instance out of
> > > > the box, the approach that Jackrabbit took might be worth following.
> > > > They used a default DB of Derby, which didn't need any config, as it
> > > > will run embedded. This also allowed them to make the TCK run all
> its
> > > > tests inside maven without additional config.
> > > >
> > >
> > > You are assuming that everybody wants to run java, which is not
> > > something you are so free to assume, specially in this field. CouchDB
> is
> > > a DB that uses json as native wire format and javascript as backend
> > > language, which makes it have an excellent impedance with shindig as
> it
> > > might serve straight from the DB. While it is a very young project, I
> > > just mentioned its use for prototyping of the social stuff.
> > >
> > >
> > > > This may all be small point, since I see that Abdera has a number of
> > > > other ColectionAdapters including iBatis, Hibernate and even JCR.
> > > >
> > > > --------------
> > > >
> > > > Another quick question.
> > > >
> > > > With the REST api being implemented, is there any point in
> > > > implementing the Services (eg PeopleService) that exist in the
> > > > current code base against a DB backend .... or will they be
> > > > deprecated shortly (within 4 weeks)
> > > >
> > > >
> > > >
> > > > Ian
> > > >
> > > >
> > > >
> > > > On 15 Apr 2008, at 17:28, Jun Yang (杨骏) wrote:
> > > > > On Tue, Apr 15, 2008 at 7:30 AM, Santiago Gala
> > > > > <sa...@gmail.com>
> > > > > wrote:
> > > > >
> > > > >> El mar, 15-04-2008 a las 03:59 -0700, Kevin Brown escribió:
> > > > >>> On Tue, Apr 15, 2008 at 2:54 AM, Ian Boston <ie...@tfd.co.uk>
> wrote:
> > > > >>>
> > > > >>>> Is the intention with the rest based apis for opensocial in
> > > > >>>> shindig to
> > > > >>>> just provide the JS client libraries and leave the
> > > > >>>> implementation  of
> > > > >> the
> > > > >>>> server side of the api to the implementor.
> > > > >>
> > > > >
> > > > > Yes.
> > > > >
> > > > >
> > > > >>>> or
> > > > >>>>
> > > > >>>> will Shindig be implementing a rest based server component,
> with DB
> > > > >>>> backend
> > > > >>
> > > > >
> > > > > The first version will come with good support for relational
> > > > > databases, as
> > > > > is the common case.
> > > > >
> > > > >
> > > > >> I wonder if using a very simple CouchDB backend could make sense.
> > > > >> CouchDB offers a DB with native json API and javascript running
> in
> > > > >> the
> > > > >> server, so at least propotype support for initial experiments.
> > > > >>
> > > > >
> > > > > Since the server is based on Abdera and Abdera already has an
> > > > > adapter for
> > > > > CouchDB, this should be easy.
> > > > >
> > > > > Jun
> > > > >
> > > > > It looks a great tool for this, though for a prototype python +
> > > > >> simplejson + some dictionaries can actually be a similar very
> simple
> > > > >> framework. Or s/python/<your favorite dynamic language>/ :)
> > > > >>
> > > > >>>
> > > > >>> RESTful APIs are in development now, though nothing has been
> > > > >>> committed
> > > > >> yet.
> > > > >>> See mail archives for discussion. I'd expect the first commit
> > > > >>> within the
> > > > >>> next week or two at most. The RESTful  spec was just finalized
> > > > >>> last week
> > > > >> --
> > > > >>> we need a little time! :)
> > > > >>>
> > > > >>> Also, is there any intention to use POST on the rest URL's to do
> > > > >>> updates
> > > > >> to
> > > > >>>> social data where it makes sense... sorry if this has been
> > > > >>>> mentioned
> > > > >>>> already.
> > > > >>>
> > > > >>>
> > > > >>> We'll do whatever the spec requires.
> > > > >>>
> > > > >>
> > > > >> +1, ReST requires POST/PUT for non-idempotent request, and
> > > > >> *updates* are
> > > > >> always non-idempotent. Even if I'm not following the spec right
> > > > >> now, I
> > > > >> would be very surprised if the spec used GET for updates. But
> > > > >> this, as
> > > > >> Kevin said, belongs to the spec ground.
> > > > >>
> > > > >> --
> > > > >> Santiago Gala
> > > > >> http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/blog/><
> http://memojo.com/%7Esgala/blog/> <
> > > http://memojo.com/%7Esgala/blog/>
> > > > >>
> > > > >>
> > > >
> > > --
> > > Santiago Gala
> > > http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/blog/> <
> http://memojo.com/%7Esgala/blog/>
> > >
> > >
> >
> >
> --
> Santiago Gala
> http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/blog/>
>
>

Re: question: social rest api's

Posted by Santiago Gala <sa...@gmail.com>.
El mar, 15-04-2008 a las 16:52 -0700, Kevin Brown escribió:
> Couldn't SQLite serve the same role?

Of course. SQLite or Derby (embedded in the java server) or any
relational DB with the proper scripts for creation of the demo DB.

I pointed at CouchDB because:
- it has a json on HTTP wire format used with a ReST API, i.e., it can
be mapped to directly serve what we want here.
- it is programmed using javascript in the server, i.e., quite natural
for people coding gadgets. (See for instance
http://wiki.apache.org/couchdb/GettingStartedWithJavaScript )
- it is designed as a "new breed" DB, easy to replicate and scale
- they joined incubation close to when shindig did, so they are
"neighbors" :)
- I wanted to be provocative and point to something quite out of the
ordinary

I specifically told about "prototyping", as I was thinking that it might
be quite useful for someone working on the right interfaces and formats
to use such a tool. I was thinking about writing a quick snippet of code
and testing on the fly. I don't think it is the right thing for
production right now, as it might scare people.

Regards
Santiago

> 
> On Tue, Apr 15, 2008 at 3:56 PM, Santiago Gala <sa...@gmail.com>
> wrote:
> 
> > El mar, 15-04-2008 a las 23:35 +0100, Ian Boston escribió:
> > > I don't know enough about CouchDB to say if its a good solution, but
> > > am I correct in thinking its another server to setup and wont run in
> > > the same JVM as the Shindig instance ? (Looking at the svn it see c
> > > code, and mention of mod_couch ... sounds like it needs apache httpd
> > > to run ).
> >
> > It does not. It won't run in the same JVM as Shindig,... because it is
> > not java.  mod_couch is an erlang module. CouchDB is written in Erlang
> > + C (the javascript interpreter and the glue).
> >
> > >
> > > To make it really easy for someone to take a Shindig instance out of
> > > the box, the approach that Jackrabbit took might be worth following.
> > > They used a default DB of Derby, which didn't need any config, as it
> > > will run embedded. This also allowed them to make the TCK run all its
> > > tests inside maven without additional config.
> > >
> >
> > You are assuming that everybody wants to run java, which is not
> > something you are so free to assume, specially in this field. CouchDB is
> > a DB that uses json as native wire format and javascript as backend
> > language, which makes it have an excellent impedance with shindig as it
> > might serve straight from the DB. While it is a very young project, I
> > just mentioned its use for prototyping of the social stuff.
> >
> >
> > > This may all be small point, since I see that Abdera has a number of
> > > other ColectionAdapters including iBatis, Hibernate and even JCR.
> > >
> > > --------------
> > >
> > > Another quick question.
> > >
> > > With the REST api being implemented, is there any point in
> > > implementing the Services (eg PeopleService) that exist in the
> > > current code base against a DB backend .... or will they be
> > > deprecated shortly (within 4 weeks)
> > >
> > >
> > >
> > > Ian
> > >
> > >
> > >
> > > On 15 Apr 2008, at 17:28, Jun Yang (杨骏) wrote:
> > > > On Tue, Apr 15, 2008 at 7:30 AM, Santiago Gala
> > > > <sa...@gmail.com>
> > > > wrote:
> > > >
> > > >> El mar, 15-04-2008 a las 03:59 -0700, Kevin Brown escribió:
> > > >>> On Tue, Apr 15, 2008 at 2:54 AM, Ian Boston <ie...@tfd.co.uk> wrote:
> > > >>>
> > > >>>> Is the intention with the rest based apis for opensocial in
> > > >>>> shindig to
> > > >>>> just provide the JS client libraries and leave the
> > > >>>> implementation  of
> > > >> the
> > > >>>> server side of the api to the implementor.
> > > >>
> > > >
> > > > Yes.
> > > >
> > > >
> > > >>>> or
> > > >>>>
> > > >>>> will Shindig be implementing a rest based server component, with DB
> > > >>>> backend
> > > >>
> > > >
> > > > The first version will come with good support for relational
> > > > databases, as
> > > > is the common case.
> > > >
> > > >
> > > >> I wonder if using a very simple CouchDB backend could make sense.
> > > >> CouchDB offers a DB with native json API and javascript running in
> > > >> the
> > > >> server, so at least propotype support for initial experiments.
> > > >>
> > > >
> > > > Since the server is based on Abdera and Abdera already has an
> > > > adapter for
> > > > CouchDB, this should be easy.
> > > >
> > > > Jun
> > > >
> > > > It looks a great tool for this, though for a prototype python +
> > > >> simplejson + some dictionaries can actually be a similar very simple
> > > >> framework. Or s/python/<your favorite dynamic language>/ :)
> > > >>
> > > >>>
> > > >>> RESTful APIs are in development now, though nothing has been
> > > >>> committed
> > > >> yet.
> > > >>> See mail archives for discussion. I'd expect the first commit
> > > >>> within the
> > > >>> next week or two at most. The RESTful  spec was just finalized
> > > >>> last week
> > > >> --
> > > >>> we need a little time! :)
> > > >>>
> > > >>> Also, is there any intention to use POST on the rest URL's to do
> > > >>> updates
> > > >> to
> > > >>>> social data where it makes sense... sorry if this has been
> > > >>>> mentioned
> > > >>>> already.
> > > >>>
> > > >>>
> > > >>> We'll do whatever the spec requires.
> > > >>>
> > > >>
> > > >> +1, ReST requires POST/PUT for non-idempotent request, and
> > > >> *updates* are
> > > >> always non-idempotent. Even if I'm not following the spec right
> > > >> now, I
> > > >> would be very surprised if the spec used GET for updates. But
> > > >> this, as
> > > >> Kevin said, belongs to the spec ground.
> > > >>
> > > >> --
> > > >> Santiago Gala
> > > >> http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/blog/> <
> > http://memojo.com/%7Esgala/blog/>
> > > >>
> > > >>
> > >
> > --
> > Santiago Gala
> > http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/blog/>
> >
> >
> 
> 
-- 
Santiago Gala
http://memojo.com/~sgala/blog/


Re: question: social rest api's

Posted by Kevin Brown <et...@google.com>.
Couldn't SQLite serve the same role?

On Tue, Apr 15, 2008 at 3:56 PM, Santiago Gala <sa...@gmail.com>
wrote:

> El mar, 15-04-2008 a las 23:35 +0100, Ian Boston escribió:
> > I don't know enough about CouchDB to say if its a good solution, but
> > am I correct in thinking its another server to setup and wont run in
> > the same JVM as the Shindig instance ? (Looking at the svn it see c
> > code, and mention of mod_couch ... sounds like it needs apache httpd
> > to run ).
>
> It does not. It won't run in the same JVM as Shindig,... because it is
> not java.  mod_couch is an erlang module. CouchDB is written in Erlang
> + C (the javascript interpreter and the glue).
>
> >
> > To make it really easy for someone to take a Shindig instance out of
> > the box, the approach that Jackrabbit took might be worth following.
> > They used a default DB of Derby, which didn't need any config, as it
> > will run embedded. This also allowed them to make the TCK run all its
> > tests inside maven without additional config.
> >
>
> You are assuming that everybody wants to run java, which is not
> something you are so free to assume, specially in this field. CouchDB is
> a DB that uses json as native wire format and javascript as backend
> language, which makes it have an excellent impedance with shindig as it
> might serve straight from the DB. While it is a very young project, I
> just mentioned its use for prototyping of the social stuff.
>
>
> > This may all be small point, since I see that Abdera has a number of
> > other ColectionAdapters including iBatis, Hibernate and even JCR.
> >
> > --------------
> >
> > Another quick question.
> >
> > With the REST api being implemented, is there any point in
> > implementing the Services (eg PeopleService) that exist in the
> > current code base against a DB backend .... or will they be
> > deprecated shortly (within 4 weeks)
> >
> >
> >
> > Ian
> >
> >
> >
> > On 15 Apr 2008, at 17:28, Jun Yang (杨骏) wrote:
> > > On Tue, Apr 15, 2008 at 7:30 AM, Santiago Gala
> > > <sa...@gmail.com>
> > > wrote:
> > >
> > >> El mar, 15-04-2008 a las 03:59 -0700, Kevin Brown escribió:
> > >>> On Tue, Apr 15, 2008 at 2:54 AM, Ian Boston <ie...@tfd.co.uk> wrote:
> > >>>
> > >>>> Is the intention with the rest based apis for opensocial in
> > >>>> shindig to
> > >>>> just provide the JS client libraries and leave the
> > >>>> implementation  of
> > >> the
> > >>>> server side of the api to the implementor.
> > >>
> > >
> > > Yes.
> > >
> > >
> > >>>> or
> > >>>>
> > >>>> will Shindig be implementing a rest based server component, with DB
> > >>>> backend
> > >>
> > >
> > > The first version will come with good support for relational
> > > databases, as
> > > is the common case.
> > >
> > >
> > >> I wonder if using a very simple CouchDB backend could make sense.
> > >> CouchDB offers a DB with native json API and javascript running in
> > >> the
> > >> server, so at least propotype support for initial experiments.
> > >>
> > >
> > > Since the server is based on Abdera and Abdera already has an
> > > adapter for
> > > CouchDB, this should be easy.
> > >
> > > Jun
> > >
> > > It looks a great tool for this, though for a prototype python +
> > >> simplejson + some dictionaries can actually be a similar very simple
> > >> framework. Or s/python/<your favorite dynamic language>/ :)
> > >>
> > >>>
> > >>> RESTful APIs are in development now, though nothing has been
> > >>> committed
> > >> yet.
> > >>> See mail archives for discussion. I'd expect the first commit
> > >>> within the
> > >>> next week or two at most. The RESTful  spec was just finalized
> > >>> last week
> > >> --
> > >>> we need a little time! :)
> > >>>
> > >>> Also, is there any intention to use POST on the rest URL's to do
> > >>> updates
> > >> to
> > >>>> social data where it makes sense... sorry if this has been
> > >>>> mentioned
> > >>>> already.
> > >>>
> > >>>
> > >>> We'll do whatever the spec requires.
> > >>>
> > >>
> > >> +1, ReST requires POST/PUT for non-idempotent request, and
> > >> *updates* are
> > >> always non-idempotent. Even if I'm not following the spec right
> > >> now, I
> > >> would be very surprised if the spec used GET for updates. But
> > >> this, as
> > >> Kevin said, belongs to the spec ground.
> > >>
> > >> --
> > >> Santiago Gala
> > >> http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/blog/> <
> http://memojo.com/%7Esgala/blog/>
> > >>
> > >>
> >
> --
> Santiago Gala
> http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/blog/>
>
>


-- 
~Kevin

Re: question: social rest api's

Posted by Ian Boston <ie...@tfd.co.uk>.
very good point,
I had my head buried in Lucene, Jackrabbit ...... thinking Shindig  
was Java.... but completely forgetting the php code thats already  
there, and other code that will (certainly) follow.
Ian



On 15 Apr 2008, at 23:56, Santiago Gala wrote:
> You are assuming that everybody wants to run java, which is not
> something you are so free to assume, specially in this field.


Re: question: social rest api's

Posted by Santiago Gala <sa...@gmail.com>.
El mar, 15-04-2008 a las 23:35 +0100, Ian Boston escribió:
> I don't know enough about CouchDB to say if its a good solution, but  
> am I correct in thinking its another server to setup and wont run in  
> the same JVM as the Shindig instance ? (Looking at the svn it see c  
> code, and mention of mod_couch ... sounds like it needs apache httpd  
> to run ).

It does not. It won't run in the same JVM as Shindig,... because it is
not java.  mod_couch is an erlang module. CouchDB is written in Erlang
+ C (the javascript interpreter and the glue). 

> 
> To make it really easy for someone to take a Shindig instance out of  
> the box, the approach that Jackrabbit took might be worth following.  
> They used a default DB of Derby, which didn't need any config, as it  
> will run embedded. This also allowed them to make the TCK run all its  
> tests inside maven without additional config.
> 

You are assuming that everybody wants to run java, which is not
something you are so free to assume, specially in this field. CouchDB is
a DB that uses json as native wire format and javascript as backend
language, which makes it have an excellent impedance with shindig as it
might serve straight from the DB. While it is a very young project, I
just mentioned its use for prototyping of the social stuff.


> This may all be small point, since I see that Abdera has a number of  
> other ColectionAdapters including iBatis, Hibernate and even JCR.
> 
> --------------
> 
> Another quick question.
> 
> With the REST api being implemented, is there any point in  
> implementing the Services (eg PeopleService) that exist in the  
> current code base against a DB backend .... or will they be  
> deprecated shortly (within 4 weeks)
> 
> 
> 
> Ian
> 
> 
> 
> On 15 Apr 2008, at 17:28, Jun Yang (杨骏) wrote:
> > On Tue, Apr 15, 2008 at 7:30 AM, Santiago Gala  
> > <sa...@gmail.com>
> > wrote:
> >
> >> El mar, 15-04-2008 a las 03:59 -0700, Kevin Brown escribió:
> >>> On Tue, Apr 15, 2008 at 2:54 AM, Ian Boston <ie...@tfd.co.uk> wrote:
> >>>
> >>>> Is the intention with the rest based apis for opensocial in  
> >>>> shindig to
> >>>> just provide the JS client libraries and leave the  
> >>>> implementation  of
> >> the
> >>>> server side of the api to the implementor.
> >>
> >
> > Yes.
> >
> >
> >>>> or
> >>>>
> >>>> will Shindig be implementing a rest based server component, with DB
> >>>> backend
> >>
> >
> > The first version will come with good support for relational  
> > databases, as
> > is the common case.
> >
> >
> >> I wonder if using a very simple CouchDB backend could make sense.
> >> CouchDB offers a DB with native json API and javascript running in  
> >> the
> >> server, so at least propotype support for initial experiments.
> >>
> >
> > Since the server is based on Abdera and Abdera already has an  
> > adapter for
> > CouchDB, this should be easy.
> >
> > Jun
> >
> > It looks a great tool for this, though for a prototype python +
> >> simplejson + some dictionaries can actually be a similar very simple
> >> framework. Or s/python/<your favorite dynamic language>/ :)
> >>
> >>>
> >>> RESTful APIs are in development now, though nothing has been  
> >>> committed
> >> yet.
> >>> See mail archives for discussion. I'd expect the first commit  
> >>> within the
> >>> next week or two at most. The RESTful  spec was just finalized  
> >>> last week
> >> --
> >>> we need a little time! :)
> >>>
> >>> Also, is there any intention to use POST on the rest URL's to do  
> >>> updates
> >> to
> >>>> social data where it makes sense... sorry if this has been  
> >>>> mentioned
> >>>> already.
> >>>
> >>>
> >>> We'll do whatever the spec requires.
> >>>
> >>
> >> +1, ReST requires POST/PUT for non-idempotent request, and  
> >> *updates* are
> >> always non-idempotent. Even if I'm not following the spec right  
> >> now, I
> >> would be very surprised if the spec used GET for updates. But  
> >> this, as
> >> Kevin said, belongs to the spec ground.
> >>
> >> --
> >> Santiago Gala
> >> http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/blog/>
> >>
> >>
> 
-- 
Santiago Gala
http://memojo.com/~sgala/blog/


Re: question: social rest api's

Posted by Ian Boston <ie...@tfd.co.uk>.
I don't know enough about CouchDB to say if its a good solution, but  
am I correct in thinking its another server to setup and wont run in  
the same JVM as the Shindig instance ? (Looking at the svn it see c  
code, and mention of mod_couch ... sounds like it needs apache httpd  
to run ).

To make it really easy for someone to take a Shindig instance out of  
the box, the approach that Jackrabbit took might be worth following.  
They used a default DB of Derby, which didn't need any config, as it  
will run embedded. This also allowed them to make the TCK run all its  
tests inside maven without additional config.

This may all be small point, since I see that Abdera has a number of  
other ColectionAdapters including iBatis, Hibernate and even JCR.

--------------

Another quick question.

With the REST api being implemented, is there any point in  
implementing the Services (eg PeopleService) that exist in the  
current code base against a DB backend .... or will they be  
deprecated shortly (within 4 weeks)



Ian



On 15 Apr 2008, at 17:28, Jun Yang (杨骏) wrote:
> On Tue, Apr 15, 2008 at 7:30 AM, Santiago Gala  
> <sa...@gmail.com>
> wrote:
>
>> El mar, 15-04-2008 a las 03:59 -0700, Kevin Brown escribió:
>>> On Tue, Apr 15, 2008 at 2:54 AM, Ian Boston <ie...@tfd.co.uk> wrote:
>>>
>>>> Is the intention with the rest based apis for opensocial in  
>>>> shindig to
>>>> just provide the JS client libraries and leave the  
>>>> implementation  of
>> the
>>>> server side of the api to the implementor.
>>
>
> Yes.
>
>
>>>> or
>>>>
>>>> will Shindig be implementing a rest based server component, with DB
>>>> backend
>>
>
> The first version will come with good support for relational  
> databases, as
> is the common case.
>
>
>> I wonder if using a very simple CouchDB backend could make sense.
>> CouchDB offers a DB with native json API and javascript running in  
>> the
>> server, so at least propotype support for initial experiments.
>>
>
> Since the server is based on Abdera and Abdera already has an  
> adapter for
> CouchDB, this should be easy.
>
> Jun
>
> It looks a great tool for this, though for a prototype python +
>> simplejson + some dictionaries can actually be a similar very simple
>> framework. Or s/python/<your favorite dynamic language>/ :)
>>
>>>
>>> RESTful APIs are in development now, though nothing has been  
>>> committed
>> yet.
>>> See mail archives for discussion. I'd expect the first commit  
>>> within the
>>> next week or two at most. The RESTful  spec was just finalized  
>>> last week
>> --
>>> we need a little time! :)
>>>
>>> Also, is there any intention to use POST on the rest URL's to do  
>>> updates
>> to
>>>> social data where it makes sense... sorry if this has been  
>>>> mentioned
>>>> already.
>>>
>>>
>>> We'll do whatever the spec requires.
>>>
>>
>> +1, ReST requires POST/PUT for non-idempotent request, and  
>> *updates* are
>> always non-idempotent. Even if I'm not following the spec right  
>> now, I
>> would be very surprised if the spec used GET for updates. But  
>> this, as
>> Kevin said, belongs to the spec ground.
>>
>> --
>> Santiago Gala
>> http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/blog/>
>>
>>


Re: question: social rest api's

Posted by "Jun Yang (杨骏)" <jy...@google.com>.
On Tue, Apr 15, 2008 at 7:30 AM, Santiago Gala <sa...@gmail.com>
wrote:

> El mar, 15-04-2008 a las 03:59 -0700, Kevin Brown escribió:
> > On Tue, Apr 15, 2008 at 2:54 AM, Ian Boston <ie...@tfd.co.uk> wrote:
> >
> > > Is the intention with the rest based apis for opensocial in shindig to
> > > just provide the JS client libraries and leave the implementation  of
> the
> > > server side of the api to the implementor.
>

Yes.


> > > or
> > >
> > > will Shindig be implementing a rest based server component, with DB
> > > backend
>

The first version will come with good support for relational databases, as
is the common case.


> I wonder if using a very simple CouchDB backend could make sense.
> CouchDB offers a DB with native json API and javascript running in the
> server, so at least propotype support for initial experiments.
>

Since the server is based on Abdera and Abdera already has an adapter for
CouchDB, this should be easy.

Jun

It looks a great tool for this, though for a prototype python +
> simplejson + some dictionaries can actually be a similar very simple
> framework. Or s/python/<your favorite dynamic language>/ :)
>
> >
> > RESTful APIs are in development now, though nothing has been committed
> yet.
> > See mail archives for discussion. I'd expect the first commit within the
> > next week or two at most. The RESTful  spec was just finalized last week
> --
> > we need a little time! :)
> >
> > Also, is there any intention to use POST on the rest URL's to do updates
> to
> > > social data where it makes sense... sorry if this has been mentioned
> > > already.
> >
> >
> > We'll do whatever the spec requires.
> >
>
> +1, ReST requires POST/PUT for non-idempotent request, and *updates* are
> always non-idempotent. Even if I'm not following the spec right now, I
> would be very surprised if the spec used GET for updates. But this, as
> Kevin said, belongs to the spec ground.
>
> --
> Santiago Gala
> http://memojo.com/~sgala/blog/ <http://memojo.com/%7Esgala/blog/>
>
>

Re: question: social rest api's

Posted by Santiago Gala <sa...@gmail.com>.
El mar, 15-04-2008 a las 03:59 -0700, Kevin Brown escribió:
> On Tue, Apr 15, 2008 at 2:54 AM, Ian Boston <ie...@tfd.co.uk> wrote:
> 
> > Is the intention with the rest based apis for opensocial in shindig to
> > just provide the JS client libraries and leave the implementation  of the
> > server side of the api to the implementor.
> >
> > or
> >
> > will Shindig be implementing a rest based server component, with DB
> > backend.
> 

I wonder if using a very simple CouchDB backend could make sense.
CouchDB offers a DB with native json API and javascript running in the
server, so at least propotype support for initial experiments.

It looks a great tool for this, though for a prototype python +
simplejson + some dictionaries can actually be a similar very simple
framework. Or s/python/<your favorite dynamic language>/ :)

> 
> RESTful APIs are in development now, though nothing has been committed yet.
> See mail archives for discussion. I'd expect the first commit within the
> next week or two at most. The RESTful  spec was just finalized last week --
> we need a little time! :)
> 
> Also, is there any intention to use POST on the rest URL's to do updates to
> > social data where it makes sense... sorry if this has been mentioned
> > already.
> 
> 
> We'll do whatever the spec requires.
> 

+1, ReST requires POST/PUT for non-idempotent request, and *updates* are
always non-idempotent. Even if I'm not following the spec right now, I
would be very surprised if the spec used GET for updates. But this, as
Kevin said, belongs to the spec ground.

-- 
Santiago Gala
http://memojo.com/~sgala/blog/


Re: question: social rest api's

Posted by Kevin Brown <et...@google.com>.
On Tue, Apr 15, 2008 at 2:54 AM, Ian Boston <ie...@tfd.co.uk> wrote:

> Is the intention with the rest based apis for opensocial in shindig to
> just provide the JS client libraries and leave the implementation  of the
> server side of the api to the implementor.
>
> or
>
> will Shindig be implementing a rest based server component, with DB
> backend.


RESTful APIs are in development now, though nothing has been committed yet.
See mail archives for discussion. I'd expect the first commit within the
next week or two at most. The RESTful  spec was just finalized last week --
we need a little time! :)

Also, is there any intention to use POST on the rest URL's to do updates to
> social data where it makes sense... sorry if this has been mentioned
> already.


We'll do whatever the spec requires.

-- 
~Kevin

Re: question: social rest api's

Posted by Chris Chabot <ch...@xs4all.nl>.
The second one, shindig's intention is to provide a 'social-api' back  
end (there's been a few discussions on the list earlier which toolkit  
to use for building this on the java side), and there's been some talk  
as well about providing a sample MySql interface or something as well.

See http://docs.google.com/View?docid=dc43mmng_2g6k9qzfb in regards to  
what the current thinking is about post/get/put/etc http methods.

On Apr 15, 2008, at 11:54 AM, Ian Boston wrote:

> Is the intention with the rest based apis for opensocial in shindig  
> to just provide the JS client libraries and leave the  
> implementation  of the server side of the api to the implementor.
>
> or
>
> will Shindig be implementing a rest based server component, with DB  
> backend.
>
> Also, is there any intention to use POST on the rest URL's to do  
> updates to social data where it makes sense... sorry if this has  
> been mentioned already.
>
> ---
>
> From our (selfish) point of view, we already have the rest  
> scafolding deployed, so shindig providing the client side libraries  
> is attractive as we can probably implement the rest based server  
> quite quickly in out own infrastructure.
>
>
> Ian
>
>