2025上半年,最新 AI实践都在这!20+ 应用案例,任听一场议题就值回票价 了解详情
写点什么

mongos-sharding 连接池配置

  • 2020-03-04
  • 本文字数:880 字

    阅读完需:约 3 分钟

mongos-sharding连接池配置

ShardingTaskExecutorPoolMaxSize

Maximum number of outbound connections each TaskExecutor connection pool can open to any given mongod instance. The maximum possible connections to any given host across all TaskExecutor pools is
复制代码


连接池最大大小,默认没有限制


对于 mongod 最大连接控制:ShardingTaskExecutorPoolMaxSize * taskExecutorPoolSize

ShardingTaskExecutorPoolMinSize

Minimum number of outbound connections each TaskExecutor connection pool can open to any given mongod instance.
复制代码


连接池最小大小,默认为 1

taskExecutorPoolSize

The number of Task Executor connection pools to use for a given mongos. The parameter has a minimum value of 4 and a maximum value of 64.
复制代码


任务池大小,默认是 cpu 核数

ShardingTaskExecutorPoolMaxConnecting

Maximum number of simultaneous initiating connections (including pending connections in setup/refresh state) each TaskExecutor connection pool can have to a mongod instance. You can set this parameter to control the rate at which mongos adds connections to a mongod instance.
复制代码


并发进行初始连接的数量,默认没有限制,该值保持在 ShardingTaskExecutorPoolMaxSize 以下

ShardingTaskExecutorPoolRefreshRequirementMS

Maximum time the mongos waits before attempting to heartbeat a resting connection in the pool.
复制代码


连接池保活心跳的间隔时间,默认 1 分钟

ShardingTaskExecutorPoolRefreshTimeoutMS

Maximum time the mongos waits for a heartbeat before timing out the heartbeat
复制代码


连接池保活心跳的超时时间,默认 20 秒

ShardingTaskExecutorPoolHostTimeoutMS

Maximum time that mongos goes without communication to a host before mongos drops all connections to the host.
复制代码


空闲时间阈值,默认 30 秒,当 mongos 与 mongod 在指定时间内没有交互时会释放连接。


参考文档


https://docs.mongodb.com/v3.4/reference/parameters/#param.ShardingTaskExecutorPoolMaxSize


作者简介


华为云专家唐章卓


2020-03-04 14:25899

评论

发布
暂无评论
发现更多内容

Android高级工程师必备知识!享学课堂vip怎么样

android 程序员 移动开发

apk瘦身,动脑学院vip课程分享

android 程序员 移动开发

2021云栖大会开源引力峰会重磅发布的战略合作,Grafana服务到底是什么?

阿里巴巴中间件

阿里云 开源 云原生 Grafana 云栖大会

第一周学习总结

lxz

模块6作业

cherrycheek

模块8作业

cherrycheek

TX-LCN分布式事务之TCC模式

北漂码农有话说

模块9作业

cherrycheek

模块一作业

AHUI

架构实战营 「架构实战营」

《我想进大厂》之kafka夺命连环11问

艾小仙

kafka 面试 后端

To B的网易

海比研究院

用新视角理解新消费里的人货场

石云升

学习笔记 10月月更

架构训练营-模块一作业

21°Char

自定义View:触摸反馈

Changing Lin

10月月更

分布式事务之TX-LCN

北漂码农有话说

Tapdata Cloud 版本上新 | 支持通知自配置,支持GP、MQ数据源,界面更友好!

tapdata

数据库 mongodb

架构实战营 模块二作业

felix

架构实战营

TX-LCN分布式事务之LCN模式

北漂码农有话说

Android高级工程师必看系列,Android基础入门教程

android 程序员 移动开发

Android高级:动脑学院android全套

android 程序员 移动开发

apm应用性能管理,享学课堂架构师vip

android 程序员 移动开发

模块一作业

lxz

kubernetes设置共享内存

ilinux

二本渣渣辛酸面试之旅:5 面阿里 Java 岗侥幸上岸,定级 P6

收到请回复

Java 后端 阿里巴巴内部资料

Prometheus 内置函数(五)

耳东@Erdong

Prometheus PromQL 10月月更

通过题目来讲一讲存储器分层体系结构相关知识 1 | 计算机组成与系统结构专题

Regan Yue

计算机组成原理 10月月更

模块7作业

cherrycheek

海量数据分析更快、更稳、更准!GaussDB(for MySQL) HTAP只读分析特性详解

华为云数据库小助手

GaussDB 华为云数据库 GaussDB(for MySQL)

2021年最新基于Spring Cloud的微服务架构分析

程序员 架构 SpringCloud

模块一

🌾🌾🌾小麦🌾🌾🌾

架构实战营

大模型的未来在哪?

脑极体

mongos-sharding连接池配置_服务革新_华为云开发者联盟_InfoQ精选文章