Search code examples
djangoreactjsrethinkdbrethinkdb-python

Instructions or tutorial on how to access data from Rethink DB in django framework?


I'm searching for the instructions on how to access data from RethinkDB in Django framework but couldn't find in Django official web site. I could install rethinkdb driver in python3.4 using pip, but could find no simple demo on how to use it in the models and views to access data and perform simple data access operations.

I'm learning RethinkDB and Reactjs, and found them very interesting to harness the power of real time web interactions.

My objective is to use these three, but couldn't find a simple demo on usage of these three [Python(Django) + RethinkDB + React JS].

Can someone help me by pointing to any simple demo on accessing data from RethinkDB and displaying on template in Django ?

If possible any simple demo which has all the three technologies for learning purpose.

Thanks a lot!


Solution

  • I see you've made a few StackOverflow questions regarding Django and RethinkDB:

    Is this correct way to access RethinkDB in Django? How to retrieve data from RethinkDB via Django view?

    But let me try to address the main problem here.

    I think the overall answer is that RethinkDB cannot be the primary datastore for Django without some serious overhauling. It just makes more sense to keep the main datastore of Django as Postgres or some other SQL db. Where RethinkDB can assist Django is using it with middleware to give it some great reactive features with things like RethinkDB changefeeds. This will definitely take some considerable work though to get going.

    But, if you're just trying to get started with using Reactjs, RethinkDB, and Python. I definitely recommend Bottle or Flask. Django is opinionated on how your app should be developed, using Flask is a bit more free-form and gives you some flexibility that you won't get with Django.

    If you really like Django, by all means continue, but I think if learning is more your priority, I'd recommend trying a different framework that you won't have to break or bend too much to getting a working product.

    If you have any thoughts/questions, hit me up at @dalanmiller.