Re: [Django] #10088: for_share() as well as for_update() addition to Model.QuerySet

22 views
Skip to first unread message

Django

unread,
Jan 22, 2012, 10:19:14 AM1/22/12
to django-...@googlegroups.com
#10088: for_share() as well as for_update() addition to Model.QuerySet
-------------------------------------+-------------------------------------
Reporter: epandurski | Owner:
Type: New feature | Status: new
Component: Database layer | Version: 1.0
(models, ORM) | Resolution:
Severity: Normal | Triage Stage: Accepted
Keywords: | Needs documentation: 0
Has patch: 0 | Patch needs improvement: 0
Needs tests: 0 | UI/UX: 0
Easy pickings: 0 |
-------------------------------------+-------------------------------------
Changes (by aaugustin):

* ui_ux: => 0
* stage: Design decision needed => Accepted


Comment:

Assuming it's possible to implement this cleanly, it sounds useful.

--
Ticket URL: <https://code.djangoproject.com/ticket/10088#comment:9>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

Django

unread,
Sep 3, 2018, 3:49:59 PM9/3/18
to django-...@googlegroups.com
#10088: for_share() as well as for_update() addition to Model.QuerySet
-------------------------------------+-------------------------------------
Reporter: epandurski | Owner: (none)

Type: New feature | Status: new
Component: Database layer | Version: 1.0
(models, ORM) |
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by David Schwärzle):

I was recently searching for a shared lock in Django and then came across
this very old ticket. Because not using locks is in some cases dangerous
and exclusive locks are less efficient for read only operations I think
this should be implemented in Django.

So I created a quick and dirty monkey patch which adds this feature for
MySQL and MariaDB syntax to Django including MariaDBs (>10.3.0) "WAIT
<seconds>" feature. The patch is ~400 lines long, but most of that are
blank lines and copied Django functions. I am not very experienced with
Python nor with Django, so I probably won't implement it properly and
create a pull request, but I'll upload the patch if someone is still
interested.

--
Ticket URL: <https://code.djangoproject.com/ticket/10088#comment:10>

Django

unread,
Jul 9, 2020, 12:19:11 PM7/9/20
to django-...@googlegroups.com
#10088: for_share() as well as for_update() addition to Model.QuerySet
-------------------------------------+-------------------------------------
Reporter: epandurski | Owner: (none)
Type: New feature | Status: new
Component: Database layer | Version: 1.0
(models, ORM) |
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Adam (Chainz) Johnson):

* cc: Adam (Chainz) Johnson (added)


--
Ticket URL: <https://code.djangoproject.com/ticket/10088#comment:11>

Django

unread,
Oct 11, 2022, 7:44:17 AM10/11/22
to django-...@googlegroups.com
#10088: for_share() as well as for_update() addition to Model.QuerySet
-------------------------------------+-------------------------------------
Reporter: epandurski | Owner: xyd
Type: New feature | Status: assigned
Component: Database layer | Version: dev

(models, ORM) |
Severity: Normal | Resolution:
Keywords: select_for_share | Triage Stage: Accepted
Has patch: 0 | Needs documentation: 1
Needs tests: 1 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by xyd):

* status: new => assigned
* needs_tests: 0 => 1
* owner: (none) => xyd
* version: 1.0 => dev
* keywords: => select_for_share
* needs_docs: 0 => 1


Comment:

i am so new , but i want try

--
Ticket URL: <https://code.djangoproject.com/ticket/10088#comment:12>

Django

unread,
Oct 14, 2022, 7:19:41 AM10/14/22
to django-...@googlegroups.com
#10088: for_share() as well as for_update() addition to Model.QuerySet
-------------------------------------+-------------------------------------
Reporter: epandurski | Owner: xyd
Type: New feature | Status: assigned
Component: Database layer | Version: dev
(models, ORM) |
Severity: Normal | Resolution:
Keywords: select_for_share | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 1

Needs tests: 1 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Keryn Knight):

* has_patch: 0 => 1


Comment:

PR is here: https://github.com/django/django/pull/16172

--
Ticket URL: <https://code.djangoproject.com/ticket/10088#comment:13>

Django

unread,
Dec 13, 2022, 1:25:23 PM12/13/22
to django-...@googlegroups.com
#10088: for_share() as well as for_update() addition to Model.QuerySet
-------------------------------------+-------------------------------------
Reporter: epandurski | Owner: Nick Pope

Type: New feature | Status: assigned
Component: Database layer | Version: dev
(models, ORM) |
Severity: Normal | Resolution:
Keywords: select_for_share | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Nick Pope):

* owner: xyd => Nick Pope
* needs_docs: 1 => 0
* needs_tests: 1 => 0


Comment:

New [https://github.com/django/django/pull/16381 PR].

--
Ticket URL: <https://code.djangoproject.com/ticket/10088#comment:14>

Django

unread,
Jan 26, 2023, 3:57:40 AM1/26/23
to django-...@googlegroups.com
#10088: for_share() as well as for_update() addition to Model.QuerySet
-------------------------------------+-------------------------------------
Reporter: epandurski | Owner: Nick Pope
Type: New feature | Status: assigned
Component: Database layer | Version: dev
(models, ORM) |
Severity: Normal | Resolution:
Keywords: select_for_share | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 1

Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Mariusz Felisiak):

* needs_better_patch: 0 => 1


--
Ticket URL: <https://code.djangoproject.com/ticket/10088#comment:15>

Reply all
Reply to author
Forward
0 new messages