I haven't found clear documentation or explanation on this one. I guess it prefixes cache keys with the cache name but I am not sure.
Thanks.
if true, redis key use zset to store, false is string
Related
Ansible: 2.4.9
I have a duplicated var "office_suite", one in host_var file "office_suite: msoffice" and in group_var "office_suite: openoffice".
Which one of these are selected on install?
Thanks again.
First, Thank's a lot #U880D for this link: Understanding variable precedence
"host_var" override a "group_var" as per the list in the link.
But this is false for my, my "group_vars" override "host_vars".
Cordially
I want to get all keys in redis?
this is a codis version
so, there is no scan() or scan_iter() or keys()...
I know there is a function
SLOTSSCAN
but how to use it in python?
not redis-cli
i made it!!!
use SLOTSSCAN
in python, just use send_command('SLOTSSCAN', slot, cursor)
then the response is what i want
Salt has a state module to manage .ssh/authorized_keys
https://docs.saltstack.com/en/develop/ref/states/all/salt.states.ssh_auth.html
I am not happy with it, since it combines code and data.
The state file is for me some kind of source code.
The ssh-key is for me data.
I don't want to combine both in one file.
Is there an other solution which separates code and data?
you don't have to put them together in one file:
as per documentation: https://docs.saltstack.com/en/latest/ref/states/all/salt.states.ssh_auth.html
you can use this method:
thatch:
ssh_auth.present:
- user: root
- source: salt://ssh_keys/thatch.id_rsa.pub
- config: /%h/.ssh/authorized_keys
(contrary to the example in the documentation, i get an error if the config: value starts with a '%')
this keeps your keys in their appropriate files and only links them from your code by their filenames.
Please have a look at the OpenSSH Formula. openssh/auth.sls contains the code for a state that pulls all data from a pillar. In the root folder of the formula you find pillar.example that shows how to structure the data for a pillar.
Maybe this formula is a starting point for you.
Hi I need your opinion on the design pattern for comments for REDIS:
is it better to store text comments for 1 post as :
- a single LIST where I will RPUSH all comments (may be up to 100chr each string)
- a single LIST of commentID (with RPUSH) and a new comment object each time...?
Thank you!
You should be fine with 1000 comments with 100 characters each. I like John's suggestion of a sorted set.
Keep things simple, but don't paint yourself into a corner on the client side if you later find you have reason to go the other route.
I have a store, I am loading records from it successfully. Now i need to clear all the records in it. How can i do this ?
myStore.remove(); // DID NOT WORK
myStore.clear(); // ENDED UP WITH AN ERROR TypeError: myStore.clear is not a function
How could i solve this?
Remove will remove the records you pass in. You want removeAll as in myStore.removeAll();
I find out that, at least on ExtJS 4.2.3, removeAll give an error the first time it is issued after a load. I got it resolved by doing:
store.clearData();
store.removeAll();
myStore.loadData([],false); is the solution.
I'm using version 2.0.12 and none of the above solutions worked. I read their readme.md and found store.clearAll();.
That was my solution.