[Django] #27480: A method to touch an entry in a cache

瀏覽次數:20 次
跳到第一則未讀訊息

Django

未讀,
2016年11月12日 中午12:54:342016/11/12
收件者:django-...@googlegroups.com
#27480: A method to touch an entry in a cache
-----------------------------------------------+------------------------
Reporter: Victor Porton | Owner: nobody
Type: New feature | Status: new
Component: Core (Cache system) | Version: 1.10
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 |
-----------------------------------------------+------------------------
I do `cache.set(crypt, cache.get(crypt))` in order to prolong the life of
an entry of the cache.

There should be a shorter easier way like: `cache.touch(crypt)`.

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

Django

未讀,
2016年11月12日 下午1:08:252016/11/12
收件者:django-...@googlegroups.com
#27480: A method to touch an entry in a cache
-------------------------------------+-------------------------------------

Reporter: Victor Porton | Owner: nobody
Type: New feature | Status: new
Component: Core (Cache system) | Version: 1.10
Severity: Normal | Resolution:

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 Victor Porton):

It also should have optional `timeout` argument.

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

Django

未讀,
2016年11月16日 清晨7:39:002016/11/16
收件者:django-...@googlegroups.com
#27480: Add a Cache.touch(key, timeout=DEFAULT_TIMEOUT) method
-------------------------------------+------------------------------------

Reporter: Victor Porton | Owner: nobody
Type: New feature | Status: new
Component: Core (Cache system) | Version: 1.10
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 Tim Graham):

* stage: Unreviewed => Accepted


Comment:

Seems reasonable since python-memcached and pyblicmc both implement a
`touch()` method, I think.

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

Django

未讀,
2016年11月19日 凌晨4:23:362016/11/19
收件者:django-...@googlegroups.com
#27480: Add a Cache.touch(key, timeout=DEFAULT_TIMEOUT) method
-------------------------------------+-------------------------------------
Reporter: Victor Porton | Owner: Nicolas
| Noé
Type: New feature | Status: assigned

Component: Core (Cache system) | Version: 1.10
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 Nicolas Noé):

* owner: nobody => Nicolas Noé
* status: new => assigned


--
Ticket URL: <https://code.djangoproject.com/ticket/27480#comment:3>

Django

未讀,
2016年11月24日 凌晨4:53:082016/11/24
收件者:django-...@googlegroups.com
#27480: Add a Cache.touch(key, timeout=DEFAULT_TIMEOUT) method
-------------------------------------+-------------------------------------
Reporter: Victor Porton | Owner: Nicolas
| Noé
Type: New feature | Status: assigned
Component: Core (Cache system) | Version: 1.10
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Nicolas Noé):

* has_patch: 0 => 1


--
Ticket URL: <https://code.djangoproject.com/ticket/27480#comment:4>

Django

未讀,
2016年11月24日 清晨6:14:492016/11/24
收件者:django-...@googlegroups.com
#27480: Add a Cache.touch(key, timeout=DEFAULT_TIMEOUT) method
-------------------------------------+-------------------------------------
Reporter: Victor Porton | Owner: Nicolas
| Noé
Type: New feature | Status: assigned
Component: Core (Cache system) | Version: 1.10
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 1

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

* needs_better_patch: 0 => 1


Comment:

Comments for improvement are on the
[https://github.com/django/django/pull/7610 PR].

--
Ticket URL: <https://code.djangoproject.com/ticket/27480#comment:5>

Django

未讀,
2016年12月13日 上午9:19:442016/12/13
收件者:django-...@googlegroups.com
#27480: Add a Cache.touch(key, timeout=DEFAULT_TIMEOUT) method
-------------------------------------+-------------------------------------
Reporter: Victor Porton | Owner: Nicolas
| Noé
Type: New feature | Status: assigned
Component: Core (Cache system) | Version: 1.10
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Nicolas Noé):

* needs_better_patch: 1 => 0


Comment:

Patch was improved, please review.

--
Ticket URL: <https://code.djangoproject.com/ticket/27480#comment:6>

Django

未讀,
2016年12月16日 中午12:14:572016/12/16
收件者:django-...@googlegroups.com
#27480: Add a Cache.touch(key, timeout=DEFAULT_TIMEOUT) method
-------------------------------------+-------------------------------------
Reporter: Victor Porton | Owner: Nicolas
| Noé
Type: New feature | Status: assigned
Component: Core (Cache system) | Version: 1.10
Severity: Normal | Resolution:
Keywords: | Triage Stage:
| Someday/Maybe
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Tim Graham):

* stage: Accepted => Someday/Maybe


Comment:

This is blocked on two fixes for python-memcached
([https://github.com/linsomniac/python-memcached/pull/107 PR #107],
[https://github.com/linsomniac/python-memcached/pull/108 PR #108]) so that
the Django tests can use the latest version (#25277) where `touch()`
works.

--
Ticket URL: <https://code.djangoproject.com/ticket/27480#comment:7>

Django

未讀,
2018年3月20日 凌晨4:30:092018/3/20
收件者:django-...@googlegroups.com
#27480: Add a Cache.touch(key, timeout=DEFAULT_TIMEOUT) method
-------------------------------------+-------------------------------------
Reporter: Victor Porton | Owner: Nicolas
| Noé
Type: New feature | Status: assigned
Component: Core (Cache system) | Version: 1.10
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Nicolas Noé):

* stage: Someday/Maybe => Accepted


Comment:

Python-memcached blocking issues solved and patch updated, please review.

--
Ticket URL: <https://code.djangoproject.com/ticket/27480#comment:8>

Django

未讀,
2018年4月27日 下午5:49:042018/4/27
收件者:django-...@googlegroups.com
#27480: Add a Cache.touch(key, timeout=DEFAULT_TIMEOUT) method
-------------------------------------+-------------------------------------
Reporter: Victor Porton | Owner: Nicolas
| Noé
Type: New feature | Status: closed

Component: Core (Cache system) | Version: 1.10
Severity: Normal | Resolution: fixed
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Tim Graham <timograham@…>):

* status: assigned => closed
* resolution: => fixed


Comment:

In [changeset:"3246ad106517e61437f80e8ef3c9d216754039e7" 3246ad10]:
{{{
#!CommitTicketReference repository=""
revision="3246ad106517e61437f80e8ef3c9d216754039e7"
Fixed #27480 -- Added cache.touch().
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/27480#comment:9>

Django

未讀,
2018年7月9日 中午12:12:372018/7/9
收件者:django-...@googlegroups.com
#27480: Add a Cache.touch(key, timeout=DEFAULT_TIMEOUT) method
-------------------------------------+-------------------------------------
Reporter: Victor Porton | Owner: Nicolas
| Noé
Type: New feature | Status: closed
Component: Core (Cache system) | Version: 1.10
Severity: Normal | Resolution: fixed
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by Tim Graham <timograham@…>):

In [changeset:"2d75509bcb1db910da3c568f99b6ac778a79a98f" 2d75509b]:
{{{
#!CommitTicketReference repository=""
revision="2d75509bcb1db910da3c568f99b6ac778a79a98f"
Refs #27480 -- Moved FileBasedCache content writing logic to a method.
}}}

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

Django

未讀,
2020年8月20日 凌晨3:04:362020/8/20
收件者:django-...@googlegroups.com
#27480: Add a Cache.touch(key, timeout=DEFAULT_TIMEOUT) method
-------------------------------------+-------------------------------------
Reporter: Victor Porton | Owner: Nicolas
| Noé
Type: New feature | Status: closed
Component: Core (Cache system) | Version: 1.10
Severity: Normal | Resolution: fixed
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by Mariusz Felisiak <felisiak.mariusz@…>):

In [changeset:"e2013b260a8f689eee280d00b96a9507895ec236" e2013b26]:
{{{
#!CommitTicketReference repository=""
revision="e2013b260a8f689eee280d00b96a9507895ec236"
Refs #29887, #27480 -- Moved touch() to BaseMemcachedCache.
}}}

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

回覆所有人
回覆作者
轉寄
0 則新訊息