5 ms·
That's the thing, you need to explicitly run on a transaction.atomic, with sqlalchemy, that's something that just works..
by jordic 6y ago
That's the thing, you need to explicitly run on a transaction.atomic, with sqlalchemy, that's something that just works..
- bildung 6y agoWhich is reasonable with sqalchemy because it operates at a lower level, where you manually handle sessions anyway. You don't do that in Django, by design. You can change commit behaviour if you want, though, and then you can just use transaction.atomic and still don't handle the session manually. If you'd want atomic transactions for the whole Django project, you could just set the ATOMIC_REQUESTS flag in the settings.
- jordic 6y agoThat's a nice feature, when landed it?
- bildung 6y agoAt least in Django 1.6 from 2014, couldn't find older docs.
- jordic 6y agoDoes still django lacks a connection pooling? If I'm not wrong sometime ago I saw people using the sqlalchemy pool on Django projects.
- bildung 6y agoNot since Django 1.6 from 2014.