Redis

Setting spring session on redis server

给你一囗甜甜゛ 提交于 2020-08-27 07:21:11
问题 I am writing my rest apis using spring boot. And I am trying to maintain user's session on redis server. Redis is up and running on the default port 6379 . I have used the lettuce jar to make connection to the redis server. But seems like my session is not being set on redis server. I try to get the session object set using uuid, and it return something like this 127.0.0.1:6379> get 02978830-2f35-47b7-a367-1f48e40d0ea0 (nil) From redis cli, I am able to set and get the key values. 127.0.0.1

Setting spring session on redis server

懵懂的女人 提交于 2020-08-27 07:21:08
问题 I am writing my rest apis using spring boot. And I am trying to maintain user's session on redis server. Redis is up and running on the default port 6379 . I have used the lettuce jar to make connection to the redis server. But seems like my session is not being set on redis server. I try to get the session object set using uuid, and it return something like this 127.0.0.1:6379> get 02978830-2f35-47b7-a367-1f48e40d0ea0 (nil) From redis cli, I am able to set and get the key values. 127.0.0.1

Setting spring session on redis server

牧云@^-^@ 提交于 2020-08-27 07:20:31
问题 I am writing my rest apis using spring boot. And I am trying to maintain user's session on redis server. Redis is up and running on the default port 6379 . I have used the lettuce jar to make connection to the redis server. But seems like my session is not being set on redis server. I try to get the session object set using uuid, and it return something like this 127.0.0.1:6379> get 02978830-2f35-47b7-a367-1f48e40d0ea0 (nil) From redis cli, I am able to set and get the key values. 127.0.0.1

Possible security attack on redis

家住魔仙堡 提交于 2020-08-27 06:46:37
问题 Running the command redis-server it returns: The server is now ready to accept connections on port 6379 Trying to connect in my browser localhost:6379 I get this message: Possible SECURITY ATTACK detected. It looks like somebody is sending POST or Host: commands to Redis. This is likely due to an attacker attempting to use Cross Protocol Scripting to compromise your Redis instance. Connection aborted. Can anyone help me fix this error please? 回答1: You'll need to use a Redis client to connect

Save SSE-Emitter object into MongoDB/Redis, Fetch it from Database and send event over it

故事扮演 提交于 2020-08-26 07:27:37
问题 I am trying to make my REST API stateless. For that what I need is, to save client's SSE-Emitter object to mongo or redis so that it will be centrally accessible by other instances. Current behavior: I am able to save the SSE-emitter object to mongoDb but I think that object is being modified somehow because of which, after fetching it from mongoDb I am not able to send an event to client. If I save same emitter object in Map/List locally, the events are being sent out successfully. Expected

Python-redis keys() returns list of bytes objects instead of strings

这一生的挚爱 提交于 2020-08-21 04:59:12
问题 I'm using the regular redis package in order to connect my Python code to my Redis server. As part of my code I check if a string object is existed in my Redis server keys. string = 'abcde' if string in redis.keys(): do something.. For some reasons, redis.keys() returns a list with bytes objects, such as [b'abcde'] , while my string is, of course, a str object. I already tried to set charset , encoding and decode_responses in my redis generator, but it did not help. My goal is to insert the