Redis calls the API in js to count and incr twice each time.

the value taken out each time is 2. Why
but the fiddler grab package also shows that it was only called once. There is no record of two calls.
this happens only in js, but not if you open the interface address in the browser.

Mar.20,2021

did you trigger $.post to submit this through the click event? it may be because the quick click called it twice; or if the value you open is 1, then it is normal to return 2 because incr returns the value after executing the command


the page where js is located and your interface address is not a cross-domain relationship, is it? If it is cross-domain, jq will initiate two requests, one for OPTION and one for POST.

< hr >

beside the point, it's not impossible for you to use string, for redis, that is, how many key will be exhausted when you manage them yourself, and it's not easy to rank keywords. Recommend hash set or ordered set

.
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1bdc058-30b0b.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1bdc058-30b0b.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?