alcarney / moduleplanner-django

Our attempt at using Django with MongoDB to build a module planner
0 stars 2 forks source link

Database choice #2

Open drvinceknight opened 10 years ago

drvinceknight commented 10 years ago

I couldn't make any progress at all (I gave up pretty fast) with the current setup. I'm not convinced the project needs an underlying json database but I know nothing about all that. I'll def be at the next code club so if we don't get a chance to talk before we can talk then...

drvinceknight commented 10 years ago

(Also did you create the django app using the command for that or are you trying to build it all from scratch? I'd suggest using the command that just builds it all for you...)

alcarney commented 10 years ago

If the command you are talking about is django-admin.py startapp name then yes otherwise probably not.

drvinceknight commented 10 years ago

Yup that's what I meant. Cool. On 19 Oct 2014 17:52, "Alex Carney" notifications@github.com wrote:

If the command you are talking about is django-admin.py startapp name then yes otherwise probably not.

— Reply to this email directly or view it on GitHub https://github.com/alcarney/moduleplanner-django/issues/2#issuecomment-59656024 .

alcarney commented 10 years ago

We have a dilemma.

We either have to ditch mongodb and go with one of the sql type databases. Or we have to roll back our django version to 1.5 since the extra plugins needed to get it working haven't been updated in over a year...

Is there anything amazing in 1.7 that we can't live without?

Is the flexibility that using mongodb would give us worth starting from scratch in an earlier django version?

Any thoughts

drvinceknight commented 10 years ago

On 24 October 2014 14:58, Alex Carney notifications@github.com wrote:

We either have to ditch mongodb and go with one of the sql type databases. Or we have to roll back our django version to 1.5 since the extra plugins needed to get it working haven't been updated in over a year...

Is there anything amazing in 1.7 that we can't live without?

Not that I know of.

Is the flexibility that using mongodb would give us worth starting from scratch in an earlier django version?

I don't know, I'm still not sure I get the mongodb thing.

I'd suggest using virtualenv to get us rolled back to 1.5. If and when we need to make a change we can use a db migration tool and simply have git branches that take care of all this.

Dr Vincent Knight Cardiff School of Mathematics Senghennydd Road, Cardiff CF24 4AG (+44) 29 2087 5548

alcarney commented 9 years ago

I might have been going about this the wrong way. I think I've been trying to shoehorn mongodb into django's ORM. Which goes against some of the benefits of using mongodb in the first place (or so I'm told). Whereas we should just be using mongoengine and/or pymongo to interact with the database direct from the python code.

Doing it this way we might lose the ability to use django's admin interface but at this stage I'm more inclined to try and get something working and worry about admin later - who knows we may be able to produce a wrapper for it :p.

This article should give us a nice set of examples to work from

http://www.ibm.com/developerworks/opensource/library/os-django-mongo/index.html

Any thoughts?

drvinceknight commented 9 years ago

I'm happy to follow your lead. Let's go with your suggestion so ditching Django for now and get something working. We can always fix it later. I'd suggest just staying in the one repo and branching (although rename to drop django). It's a better overall dev process so we keep the history of everything.

On Mon, 27 Oct 2014 17:32 Alex Carney notifications@github.com wrote:

I might have been going about this the wrong way. I think I've been trying to shoehorn mongodb into django's ORM. Which goes against some of the benefits of using mongodb in the first place (or so I'm told). Whereas we should just be using mongoengine and/or pymongo to interact with the database direct from the python code.

Doing it this way we might lose the ability to use django's admin interface but at this stage I'm more inclined to try and get something working and worry about admin later - who knows we may be able to produce a wrapper for it :p.

This article should give us a nice set of examples to work from

http://www.ibm.com/developerworks/opensource/library/os-django-mongo/index.html

Any thoughts?

— Reply to this email directly or view it on GitHub https://github.com/alcarney/moduleplanner-django/issues/2#issuecomment-60633979 .

alcarney commented 9 years ago

Sorry if I was unclear, i didn't mean ditching django entirely just the aspects we can't get working. We should be able to make use of django's templates and views etc , while taking a more manual approach when it comes to administrating the database

drvinceknight commented 9 years ago

Ah my mistake (long day). Cool, yeah all sounds good to me. Glad we're not ditching Django entirely as it'll be important to get tests in there and that's something that Jason and I know how to do.

On Mon Oct 27 2014 at 19:21:43 Alex Carney notifications@github.com wrote:

Sorry if I was unclear, i didn't mean ditching django entirely just the aspects we can't get working. We should be able to make use of django's templates and views etc , while taking a more manual approach when it comes to administrating the database

— Reply to this email directly or view it on GitHub https://github.com/alcarney/moduleplanner-django/issues/2#issuecomment-60653245 .