[Django] #33760: Allow setting session cookie name dynamically

27 views
Skip to first unread message

Django

unread,
Jun 1, 2022, 4:36:21 PM6/1/22
to django-...@googlegroups.com
#33760: Allow setting session cookie name dynamically
--------------------------------------------+------------------------
Reporter: Dan Strokirk | Owner: nobody
Type: New feature | Status: new
Component: contrib.sessions | Version: 4.1
Severity: Normal | Keywords:
Triage Stage: Unreviewed | Has patch: 0
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 0
UI/UX: 0 |
--------------------------------------------+------------------------
Currently it's only possible to use a single session cookie, but it can be
useful in a multi-tenant application to use multiple session cookies.

Adding a new `get_cookie_name` or `get_cookie_params` method to the
`SessionMiddleware` class might be one way to implement this, which means
that you can then then use your own subclassed middleware to override it.

If this seems like a reasonable feature to add I'd be glad to supply a
patch.

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

Django

unread,
Jun 2, 2022, 2:22:02 AM6/2/22
to django-...@googlegroups.com
#33760: Allow setting session cookie name dynamically
----------------------------------+--------------------------------------

Reporter: Dan Strokirk | Owner: nobody
Type: New feature | Status: closed
Component: contrib.sessions | Version: 4.1
Severity: Normal | Resolution: wontfix

Keywords: | Triage Stage: Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
----------------------------------+--------------------------------------
Changes (by Carlton Gibson):

* status: new => closed
* resolution: => wontfix


Comment:

Hi.

I'd likely think this too niche to justify the additional hooks.

Can I ask you to post to the DevelopersMailingList, which is a better
venue for these kind of feature requests than the ticket tracker here,
which gets far fewer eyes? If there's a general approval then we can
reopen. Thanks.

--
Ticket URL: <https://code.djangoproject.com/ticket/33760#comment:1>

Django

unread,
Jun 2, 2022, 3:52:08 AM6/2/22
to django-...@googlegroups.com
#33760: Allow setting session cookie name dynamically
----------------------------------+--------------------------------------
Reporter: Dan Strokirk | Owner: nobody
Type: New feature | Status: closed
Component: contrib.sessions | Version: 4.1
Severity: Normal | Resolution: wontfix
Keywords: | Triage Stage: Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
----------------------------------+--------------------------------------

Comment (by Dan Strokirk):

Absolutely, thanks!

--
Ticket URL: <https://code.djangoproject.com/ticket/33760#comment:2>

Reply all
Reply to author
Forward
0 new messages