Redis sentinel不会自动发现其他哨兵(Redis sentinel doesn't auto-discover other sentinels)
我将redis配置为master,有两个slave,每个slave都在一个单独的盒子上。 我还在每个盒子上运行了一个哨兵进程。 这是这里的文档中描述的设置:
http://redis.io/topics/sentinel#example-2-basic-setup-with-three-boxes
每个哨兵都可以连接到我的主人,并且可以看到奴隶。 他们能够独立检测主设备或从设备是否发生故障。 问题是哨兵无法互相发现。
我已经验证了每个
__sentinel__:hello
按预期向__sentinel__:hello
通道发布消息,但似乎没有一个实际上是从其他消息接收消息。我如何让哨兵看到对方?
I have redis configured as master with two slaves, each on a separate box. I also have a sentinel process running on each box. It's the setup as described in the documentation here:
http://redis.io/topics/sentinel#example-2-basic-setup-with-three-boxes
Each of the sentinels can connect to my master, and can see the slaves. They are able to independently detect if the master or slaves go down. The problem is that the sentinels can't detect each other.
I have verified that each sentinel is publishing a message to the
__sentinel__:hello
channel as expected, but it seems that none of them are actually receiving the messages from the other ones.How do I get the sentinels to see each other?
原文:https://stackoverflow.com/questions/38033911
满意答案
更新了一个非常冒险的春季模特。 使用鼠标悬停和鼠标离开追踪鼠标。
https://jsfiddle.net/eex3aphm/
你在你的mousemove和你的动画之间有一场战斗。
我改变了你的鼠标移动处理器来使用一个临时变量来保存这个动作:
var pullX = 0; var onMouseMove = function(event) { event.preventDefault(); pullX = event.movementX||event.mozMovementX||event.webkitMovementX||0; };
然后将更新移至减速方程:
animX = (animX + pullX) * Math.pow(0.99, delta); pullX = 0;
这可以防止你在鼠标移动时减速。
Updated with a really hacky spring model. Using mouse over and mouse leave to track mouse.
https://jsfiddle.net/eex3aphm/
You have a fight between your mousemove and your animation.
I changed your mouse movement handler to use a temporary variable to hold the movement:
var pullX = 0; var onMouseMove = function(event) { event.preventDefault(); pullX = event.movementX||event.mozMovementX||event.webkitMovementX||0; };
Then moved the update to the deceleration equation:
animX = (animX + pullX) * Math.pow(0.99, delta); pullX = 0;
This keeps you from messing with your deceleration on mouse move.
相关问答
更多平滑毛躁的javascript动画(逻辑问题)(Smoothing out glitchy javascript animation (logical issue))
用JavaScript动画(Animation with JavaScript)
在javascript中平滑动画(Smooth animation in javascript)
请使用加速度计javascript阅读帮助平滑动画?(Please help smoothing animation using accelerometer javascript reading?)
在Javascript中平滑鼠标动画(Smoothing mouse animation in Javascript)
更多基本的Javascript动画问题(More Basic Javascript Animation Problems)
如何使用css创建具有平滑鼠标输出效果的无限缩放鼠标悬停动画?(How can I create an infinite scale mouseover animation with a smooth mouseout effect with css?)
使javascript动画流畅吗?(Making javascript animation smooth?)
草像beziercurve上的平滑动画?(Grass like smoothing animation on beziercurve?)
如何创建响应水平鼠标移动的CSS动画?(How to create a CSS Animation that is responding to horizontal mouse movement? [closed])
相关文章
更多redis sentinel.conf详解-redis集群管理
redis sentinel(哨兵) 配置详解-redis集群管理
快速了解Sentinel 如何使用
Redis Cookbook
redis 集群环境搭建-redis集群管理
redis安装-redis集群管理
Sentinel快速入门
基于linux下redis安装与配置
Redis配置文件详解
Sentinel更新计划 Roadmap
最新问答
更多获取MVC 4使用的DisplayMode后缀(Get the DisplayMode Suffix being used by MVC 4)
如何通过引用返回对象?(How is returning an object by reference possible?)
矩阵如何存储在内存中?(How are matrices stored in memory?)
每个请求的Java新会话?(Java New Session For Each Request?)
css:浮动div中重叠的标题h1(css: overlapping headlines h1 in floated divs)
无论图像如何,Caffe预测同一类(Caffe predicts same class regardless of image)
xcode语法颜色编码解释?(xcode syntax color coding explained?)
在Access 2010 Runtime中使用Office 2000校对工具(Use Office 2000 proofing tools in Access 2010 Runtime)
从单独的Web主机将图像传输到服务器上(Getting images onto server from separate web host)
从旧版本复制文件并保留它们(旧/新版本)(Copy a file from old revision and keep both of them (old / new revision))
Copyright ©2023 peixunduo.com All Rights Reserved.粤ICP备14003112号
本站部分内容来源于互联网,仅供学习和参考使用,请莫用于商业用途。如有侵犯你的版权,请联系我们(neng862121861#163.com),本站将尽快处理。谢谢合作!