NoSQL with Lift, couchdb ?

9 views
Skip to first unread message

Lukasz Kuczera

unread,
Mar 29, 2010, 9:03:03 AM3/29/10
to Lift
Hi Guys.
I've started new Lift project that will benefit from NoSQL
persistency. So far couchdb looks best for me but i would love to read
your opinions.
Regarding couchdb i've found two libs: scouchdb and lift-couchdb.
Which one is more stable/feature blown ? Could you share your
experiences with NoSQL and Lift ?

Cheers.

Timothy Perrett

unread,
Mar 29, 2010, 9:11:36 AM3/29/10
to lif...@googlegroups.com
Lift doesn't prescribe how you work or with what persistence mech. You can drop in whatever you want :-) lift-record will probably give you a slightly nicer lift integration in terms of making forms and stuff, but otherwise its probably down to taste / style.

I've just started using Akka backed by mongo and the Persistance Map/Vector stuff is again working no problem within Lift... your free to use whatever you want.

Cheers, Tim

> --
> You received this message because you are subscribed to the Google Groups "Lift" group.
> To post to this group, send email to lif...@googlegroups.com.
> To unsubscribe from this group, send email to liftweb+u...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/liftweb?hl=en.
>
>

TylerWeir

unread,
Mar 29, 2010, 9:20:15 AM3/29/10
to Lift
Tim, I think a ton of people would benefit from even the simplest
project that married Lift/Akka/<mongo, riak, whatever>

Can you throw something up on github?

Timothy Perrett

unread,
Mar 29, 2010, 9:38:43 AM3/29/10
to lif...@googlegroups.com
That reminds me, I need to integrate my Riakka project into Lift at some point. Hmm, too many ideas not enough time ;-)

I unfortunately cant share what im working on, as its an internal prototype and "not official" or anything like that.

<shameless_plug>

However, for my book I will be distributing the backend in the "advanced" chapters with Akka... so when I get to those sections, the code will be public. *cough* buy my book *cough*

</shameless_plug>

I did speak with Jonas + Debasish about integrating Riakka into Akka proper, but again, not enough time right now.

Cheers, Tim

Alexander Azarov

unread,
Mar 29, 2010, 2:20:39 PM3/29/10
to Lift
Lukasz, Tyler,

I have ported Pocketchange app (from Lift Book) to use MongoDB:
http://github.com/alaz/pocketchangeapp

TylerWeir

unread,
Mar 29, 2010, 2:33:47 PM3/29/10
to Lift
Excellent!

Grabbing it now.

Lukasz Kuczera

unread,
Mar 30, 2010, 2:56:31 PM3/30/10
to Lift
Great stuff ! Could you please tell me how much different would be
using couch db ?

Ross Mellgren

unread,
Mar 30, 2010, 3:13:21 PM3/30/10
to lif...@googlegroups.com
I have it on my todo tonight to port pocket change to couchdb, since it seems to be a pretty good example and we need a record example to be used with a squeryl implementation.

I've not used mongodb directly, but I think the major difference between it and couchdb is that mongo supports freeform queries better, while couch is more geared towards prepackaged views.

-Ross

Alexander Azarov

unread,
Mar 30, 2010, 3:36:44 PM3/30/10
to Lift

On 30 мар, 23:13, Ross Mellgren <dri...@gmail.com> wrote:
> I've not used mongodb directly, but I think the major difference between it and couchdb is that mongo supports freeform queries better, while couch is more geared towards prepackaged views.

I have the same feeling. Mongo-scala-driver has a type-safe DSL to
build queries on documents and it was pretty easy to use this
functionality to replace original Mapper methods in Pocketchange. I
have no idea how it could look like for CouchDB

>
> -Ross
>
> On Mar 30, 2010, at 2:56 PM, Lukasz Kuczera wrote:
>
> > Great stuff ! Could you please tell me how much different would be
> > using couch db ?
>
> > On Mar 29, 7:20 pm, Alexander Azarov <aza...@aha.ru> wrote:
> >> Lukasz, Tyler,
>
> >> I have ported Pocketchange app (from Lift Book) to use MongoDB:http://github.com/alaz/pocketchangeapp
>

Ross Mellgren

unread,
Mar 30, 2010, 3:39:58 PM3/30/10
to lif...@googlegroups.com
Currently, you specify the views as a separate document and store it into couchdb. There is no DSL for this (I felt it was overkill at the time), so you just write the JavaScript directly.

It means that one has to go through and harvest the various query patterns and distill them into some views, then program them into couchdb on application startup. You can see these from the lift-couchdb unit tests if you're interested:

http://github.com/dpp/liftweb/blob/master/framework/lift-persistence/lift-couchdb/src/test/scala/net/liftweb/couchdb/CouchRecordSpecs.scala

Near line 58 the design with the views is specified, then later near line 68 the design document is installed.

-Ross

Lukasz Kuczera

unread,
Mar 30, 2010, 6:08:02 PM3/30/10
to Lift
Thanks, will check that.

On Mar 30, 8:39 pm, Ross Mellgren <dri...@gmail.com> wrote:
> Currently, you specify the views as a separate document and store it into couchdb. There is no DSL for this (I felt it was overkill at the time), so you just write the JavaScript directly.
>
> It means that one has to go through and harvest the various query patterns and distill them into some views, then program them into couchdb on application startup. You can see these from the lift-couchdb unit tests if you're interested:
>

> http://github.com/dpp/liftweb/blob/master/framework/lift-persistence/...

Reply all
Reply to author
Forward
0 new messages