SK-Yang / memcached

Automatically exported from code.google.com/p/memcached
0 stars 0 forks source link

binary protocol TOUCH,GAT,GATQ bug #275

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
cache.set("x", "xxx", 3);
cache.touch("x", 1)
TimeUnit.SECONDS.sleep(1);
System.out.println(cache.get("x"));
=======output==============
xxx
----------------------
GAT, GATQ is the same

Original issue reported on code.google.com by mojid...@gmail.com on 28 May 2012 at 1:49

Attachments:

GoogleCodeExporter commented 9 years ago
What server is in use?  There is no checking of server responses.

Original comment by ingen...@gmail.com on 29 May 2012 at 4:36

GoogleCodeExporter commented 9 years ago

Original comment by ingen...@gmail.com on 29 May 2012 at 4:37

GoogleCodeExporter commented 9 years ago
Ubuntu 10.04.4 LTS,memcached 1.4.13
Red Hat Enterprise Linux Server release 5.5 (Tikanga),memcached 1.4.11
======================
The server response status: 0x0000

Original comment by mojid...@gmail.com on 29 May 2012 at 5:38

GoogleCodeExporter commented 9 years ago
If you sleep for 2 seconds instead of one, it should work. Memcached's internal 
clock updates once per second, so if you want to see things change at around 
the second level it becomes unreliable.

Original comment by dorma...@rydia.net on 29 May 2012 at 7:28

GoogleCodeExporter commented 9 years ago
cache.set("x", "xxx", 3);
cache.touch("x", 1)
while(true){
 TimeUnit.SECONDS.sleep(1);
 System.out.println(cache.get("x"));
}
=======output==============
xxx
xxx
xxx
xxx
xxx
.
.
----------------------------
I run a few minutes, It still did not expired

Original comment by mojid...@gmail.com on 30 May 2012 at 1:50

GoogleCodeExporter commented 9 years ago
This is similar to the issue which I reported before.

http://groups.google.com/group/memcached/browse_thread/thread/1a40b776e35bbf08/1
7b7c53cd914e7f7?lnk=gst&q=bongjae#17b7c53cd914e7f7

I experienced the same problem. :-)

Original comment by bongjae....@gmail.com on 30 May 2012 at 6:18

GoogleCodeExporter commented 9 years ago
Here is a patch that solves the problem. process_bin_touch() was reading only 
header without extra fields, so exptime was always 0.

Original comment by uzza...@gmail.com on 18 Jul 2012 at 2:13

Attachments:

GoogleCodeExporter commented 9 years ago
P.S. Send pull request at github with the same code.

Original comment by uzza...@gmail.com on 18 Jul 2012 at 2:27

GoogleCodeExporter commented 9 years ago
this got merged a year ago... forgot to close the issue. doing so now.

Original comment by dorma...@rydia.net on 20 Dec 2013 at 9:50

GoogleCodeExporter commented 9 years ago
not fixed i use install make test and give me this page link. i send using php 
test poster to qa. please check it. debian wheezy dot deb memcached 
5.5.17-1~dotdeb.1

Original comment by semnan...@gmail.com on 21 Oct 2014 at 10:10

GoogleCodeExporter commented 9 years ago
that's not a version of memcached.

Original comment by dorma...@rydia.net on 21 Oct 2014 at 6:12