转自https://yq.aliyun.com/articles/117825?t=t1,主要结论如下:

经过源码分析,得出SessionTimeOut的协商如下:

  • 情况1: 配置文件配置了maxSessionTimeOut和minSessionTimeOut

    最终SessionTimeOut,必须在minSessionTimeOut和maxSessionTimeOut区间里,如果跨越上下界,则以跨越的上届或下界为准。

  • 情况2:配置文件没有配置maxSessionTimeOut和minSessionTimeOut

    maxSessionTimeout没配置则 maxSessionTimeOut设置为 20 * tickTime

    minSessionTimeOut没配置则 minSessionTimeOut设置为 2 * tickTime

    也就是默认情况下, SessionTimeOut的合法范围为 4秒~40秒,默认配置中tickTime为2秒。

    如果tickTime也没配置,那么tickTime缺省为3秒。

关于zookeeper中session timeout的更多相关文章

  1. Zookeeper中Session Timeout的那些事

    前言: RDS系统致力于MySQL数据的高可用,高可靠,高性能以及在线扩展功能,实现这些特性的主要逻辑功能都运行在管理服务器上,一旦管理服务器宕机,数据库的在线扩展功能/备份功能/故障恢复功能等都无从 ...

  2. 项目server中设置session timeout遇到的问题

    RT:在项目server中的web.xml设置session timeout=10,当10分钟后,继续右键执行jsp文件,运行失败,如下图所示: 但是单独启动tomcat server后,在浏览器中输 ...

  3. ASP.NET中Session的sessionState 4种mode模式

    1. sessionState的4种mode模式 在ASP.NET中Session的sessionState的4中mode模式:Off.InProc.StateServer及SqlServer. 2. ...

  4. java 中Session 持久化问题

    首先: 今天发现了个session 持久化的问题 在Tomcat 停止运行后再启动  session  中保存的东西还会存在 ,百度了一下 原理 1.Session Create 时 2.Sessio ...

  5. zookeeper中Watcher和Notifications

    问题导读:1.zookeeper观察者什么时候调用?2.传统远程轮询服务存在什么问题?3.zk中回调服务的机制是什么?4.zk中watcher为什么不永久注册?5.什么是znode? 在阅读之前首先明 ...

  6. zookeeper中client命令实践

    Welcome to ZooKeeper! 2016-09-14 16:06:04,528 [myid:] - INFO [main-SendThread(master:2181):ClientCnx ...

  7. asp.net中Session过期设置方法

    在Asp.net应用中,很多人会遇到Session过期设置有冲突.其中,可以有四处设置Session的过期时间: 一.全局网站(即服务器)级 IIS-网站-属性-Asp.net-编辑配置-状态管理-会 ...

  8. 【Apache ZooKeeper】理解ZooKeeper中的ZNodes

    理解ZooKeeper中的ZNodes 翻译自:http://zookeeper.apache.org/doc/r3.1.2/zookeeperProgrammers.html ZooKeeper中的 ...

  9. Linux下启动tomcat报错,WARN org.apache.zookeeper.ClientCnxn - Session 0x0 for server null, unexpected error, closing socket connection and attempting reconnect java.net.ConnectException:

    tomcat启动完了之后,一直不停的打印这种错误信息,看表面上,应该是zk节点下的数据是空的,连接不上服务,所以一直在尝试连接,然后一直又连不上: 完整的错误信息: 407662 [usf-ZooKe ...

随机推荐

  1. 在代码里更新autolayout布局

    //遍历view约束(高,宽) NSArray* constrains = self.View.constraints; for (NSLayoutConstraint* constraint in ...

  2. 数组声明的几种方式以及length属性

    声明一: int[] arr=new int[10]; for(int i=0;i<arr.length;i++){ arr[i]=i; } 声明二: int[] arr2={1,2,3}; 声 ...

  3. iOS开发之邮件发送代码

    邮件发送功能是由MessageUI Framework提供的,这个框架是iPhone sdk中最简单的框.由一个类.一个视图控制器,一个protocol组成. 一.创建视图控制器: MFMailCom ...

  4. XmlDocument

    XmlDocument增删改查. using System; using System.Collections.Generic; using System.ComponentModel; using ...

  5. LN : leetcode 343 Integer Break

    lc 343 Integer Break 343 Integer Break Given a positive integer n, break it into the sum of at least ...

  6. [ BZOJ 2038 ] Hose

    \(\\\) Description 给出一个数列,多次询问,每次给出一个区间 \([l_i,r_i]\) ,问在区间中随意选两个位置不同的数,是同一个数的概率有多大. \(n,m\le 5\time ...

  7. U9249 【模板】BSGS

    题目描述 给定a,b,p,求最小的非负整数x 满足a^x≡b(mod p) 若无解 请输出“orz” 输入输出格式 输入格式: 三个整数,分别为a,b,p 输出格式: 满足条件的非负整数x 输入输出样 ...

  8. 移动端rem

    手机有很多尺寸的型号.使用rem来做为大小单位可以达到兼容的目的. 方法一:js测量手机尺寸,设置font-size:为手机屏幕width /10 + ‘px’.即10rem 为手机屏幕width. ...

  9. jQuery动画处理

    $(selector).hide(speed,callback);隐藏 $(selector).show(speed,callback);显示 $(selector).toggle(speed,cal ...

  10. OpenFlow_tutorial_1_Introduce

    tutorial出处:https://github.com/mininet/openflow-tutorial/wiki OpenFlow是用于远程控制交换机流表(forwarding tables) ...