amazon-web-services - 连接到 AWS ElastiCache 复制组只读副本

标签 amazon-web-services redis amazon-elasticache

使用 AWS-ElastiCache-Redis 的复制组时,有没有办法指定连接到只读副本的首选项?

目标是提供只读访问权限。

在另一个方向上,很容易更喜欢以一种即使在切换时也保持一致的方式连接到主节点。

From the docs :

For read-only activity, applications can connect to any node in the replication group. However, for write activity, we recommend that your applications connect to the primary endpoint for the replication group instead of connecting directly to the primary node. This will ensure that your applications can always find the current primary node, even if you decide to reconfigure your replication group by promoting a read replica to the primary role.

最佳答案

没有。

一组解决方案依赖于 DNS 以“首选”主机作为最不受欢迎的连接来连接到实例,并简单地检查已连接实例的状态。由于促销事件,这不是保证。

slave-allow-chaining,它“[d]确定 Redis 中的只读副本是否可以拥有自己的只读副本。”目前是required to be "no" .)

关于amazon-web-services - 连接到 AWS ElastiCache 复制组只读副本,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/30001732/

相关文章:

node.js - 使用 nodeJs 和 AWS 调整图像大小

amazon-web-services - 亚马逊 SNS : "Platform credentials are invalid" when re-entering a GCM API key that previously worked

amazon-web-services - AWS CloudFormation 替代 VPCEndPoint 策略

amazon-web-services - AWS CLI : How to set VPC of New Replication Instance

spring-boot - SpringBoot 弹性缓存 JedisMovedDataException : MOVED

node.js - 如何使用 node.js 连接到 ElastiCache 集群

amazon-web-services - 由于服务 : AmazonElastiCache; Status Code: 400; Error Code: InvalidParameterCombination 导致 Cloudformation 堆栈失败

django - 将 Elastic Beanstalk 与 Django channel 一起使用时出现 Websocket 错误

PHP + SockJS + Redis : Unicast

node.js - ioredis - ClusterAllFailedError : Failed to refresh slots cache