当前位置: 首页 > news >正文

免费做app的网站有吗域名ip查询入口

免费做app的网站有吗,域名ip查询入口,网站建设直通车关键词设置,企业网站建设 会计分录一、ElasticSearch 写数据的总体流程: (1)ES 客户端选择一个节点 node 发送请求过去,这个节点就是协调节点 coordinating node (2)协调节点对 document 进行路由,通过 hash 算法计算出数据应该…

一、ElasticSearch 写数据的总体流程:

在这里插入图片描述

(1)ES 客户端选择一个节点 node 发送请求过去,这个节点就是协调节点 coordinating node

(2)协调节点对 document 进行路由,通过 hash 算法计算出数据应该落在哪个分片 shard 上,然后根据节点上维护的 shard 信息,将请求转发到对应的实际处理节点node上

shard = hash(document_id) % (num_of_primary_shards),

(3)实际的节点上的 primary shard 主分片处理请求,然后将数据同步到副本节点 replica node

(4)coordinating node 等到 primary node 和所有 replica node 都执行成功之后,就返回响应结果给客户端。

二、ES 的主分片写数据的详细流程:

在这里插入图片描述

1、refresh 操作:
primary shard 主分片先将数据写入 memory buffer,然后定时(默认每隔1s)将 memory buffer 中的数据写入一个新的 segment 文件中,并进入 Filesystem cache(同时清空 memory buffer),这个过程就叫做 refresh;每个 Segment 文件实际上是一些倒排索引的集合, 只有经历了 refresh 操作之后,这些数据才能变成可检索的。

ES 的近实时性:当数据存在 memory buffer 时是搜索不到的,只有数据被 refresh 到 Filesystem cache 之后才能被搜索到,而 refresh 是每秒一次, 所以称 es 是近实时的,或者可以通过手动调用 es 的 api 触发一次 refresh 操作,让数据马上可以被搜索到;

     上文讲到的 memory buffer,也称为 Indexing Buffer,这个区域默认的内存大小是 10% heap size。

2、写 translog 事务日志文件:
由于 memory Buffer 和 Filesystem Cache 都是基于内存,假设服务器宕机,那么数据就会丢失,所以 ES 通过 translog 日志文件来保证数据的可靠性,在数据写入 memory buffer 的同时,将数据写入 translog 日志文件中,在机器宕机重启时,es 会从磁盘中读取 translog 日志文件中最后一个提交点 commit point 之后的数据,恢复到 memory buffer 和 Filesystem cache 中去。

ES 数据丢失的问题:translog 也是先写入 Filesystem cache,然后默认每隔 5 秒刷一次到磁盘中,所以默认情况下,可能有 5 秒的数据会仅仅停留在 memory buffer 或者 translog 文件的 Filesystem cache中,而不在磁盘上,如果此时机器宕机,会丢失 5 秒钟的数据。也可以将 translog 设置成每次写操作必须是直接 fsync 到磁盘,但是性能会差很多。

3、flush 操作:
不断重复上面的步骤,translog 会变得越来越大,当 translog 文件默认每30分钟或者阈值超过 512M 时,就会触发 flush 操作,将 memory buffer 中所有的数据写入新的 Segment 文件中, 并将内存中所有的 Segment 文件全部落盘,最后清空 translog 事务日志。

(1)将 memory buffer 中的数据 refresh 到 Filesystem Cache 中的一个新的 segment 文件中去,然后清空 memory buffer;
(2)创建一个新的 commit point(提交点),同时强行将 Filesystem Cache 中目前所有的数据都 fsync 到磁盘文件中;
(3)删除旧的 translog 日志文件并创建一个新的 translog 日志文件,此时 flush 操作完成
ES 的 flush 操作主要通过以下几个参数控制:

index.translog.flush_threshold_period:每隔多长时间执行一次flush,默认30m
index.translog.flush_threshold_size:当事务日志大小到达此预设值,则执行flush,默认512mb
index.translog.flush_threshold_ops:当事务日志累积到多少条数据后flush一次。
————————————————
版权声明:本文为CSDN博主「张维鹏」的原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接及本声明。
原文链接:https://blog.csdn.net/a745233700/article/details/118076845


文章转载自:
http://planetologist.xhqr.cn
http://radiocobalt.xhqr.cn
http://entwine.xhqr.cn
http://moonstruck.xhqr.cn
http://disclose.xhqr.cn
http://lempert.xhqr.cn
http://archipelago.xhqr.cn
http://anthropolater.xhqr.cn
http://antibiotic.xhqr.cn
http://tulipwood.xhqr.cn
http://choriamb.xhqr.cn
http://barcarolle.xhqr.cn
http://lymphadenoma.xhqr.cn
http://synagogue.xhqr.cn
http://concretionary.xhqr.cn
http://atreus.xhqr.cn
http://thymocyte.xhqr.cn
http://curtness.xhqr.cn
http://audiovisual.xhqr.cn
http://feeling.xhqr.cn
http://kufic.xhqr.cn
http://spring.xhqr.cn
http://prepotent.xhqr.cn
http://peritrack.xhqr.cn
http://indescribable.xhqr.cn
http://inhumanize.xhqr.cn
http://reciter.xhqr.cn
http://hamster.xhqr.cn
http://wellhandled.xhqr.cn
http://darby.xhqr.cn
http://tolerant.xhqr.cn
http://soundful.xhqr.cn
http://superhawk.xhqr.cn
http://mitbestimmung.xhqr.cn
http://houseman.xhqr.cn
http://hfs.xhqr.cn
http://scindapsus.xhqr.cn
http://waywardly.xhqr.cn
http://harmonic.xhqr.cn
http://stockist.xhqr.cn
http://pyopneumothorax.xhqr.cn
http://quirk.xhqr.cn
http://razzmatazz.xhqr.cn
http://cindery.xhqr.cn
http://theogony.xhqr.cn
http://successfully.xhqr.cn
http://aromaticity.xhqr.cn
http://vadose.xhqr.cn
http://bayrut.xhqr.cn
http://ganoin.xhqr.cn
http://blackhearted.xhqr.cn
http://adjoining.xhqr.cn
http://hakeem.xhqr.cn
http://primipara.xhqr.cn
http://kopje.xhqr.cn
http://arability.xhqr.cn
http://fontange.xhqr.cn
http://cullet.xhqr.cn
http://powdered.xhqr.cn
http://formular.xhqr.cn
http://intel.xhqr.cn
http://tetrapolis.xhqr.cn
http://gamble.xhqr.cn
http://pyrolyzate.xhqr.cn
http://broadband.xhqr.cn
http://clamper.xhqr.cn
http://legatee.xhqr.cn
http://rugate.xhqr.cn
http://hypomotility.xhqr.cn
http://zoosperm.xhqr.cn
http://theodolite.xhqr.cn
http://unionides.xhqr.cn
http://queer.xhqr.cn
http://mcpo.xhqr.cn
http://convalesce.xhqr.cn
http://hauteur.xhqr.cn
http://hypaesthesia.xhqr.cn
http://orthophoto.xhqr.cn
http://zamindari.xhqr.cn
http://technocomplex.xhqr.cn
http://volscian.xhqr.cn
http://mesothelioma.xhqr.cn
http://whoop.xhqr.cn
http://nutted.xhqr.cn
http://necklet.xhqr.cn
http://amphibian.xhqr.cn
http://inclination.xhqr.cn
http://haematite.xhqr.cn
http://cotyle.xhqr.cn
http://underpainting.xhqr.cn
http://whorfian.xhqr.cn
http://cornily.xhqr.cn
http://laminal.xhqr.cn
http://cranium.xhqr.cn
http://cello.xhqr.cn
http://sporophyll.xhqr.cn
http://nudity.xhqr.cn
http://barbecue.xhqr.cn
http://unsmiling.xhqr.cn
http://rubbish.xhqr.cn
http://www.15wanjia.com/news/101921.html

相关文章:

  • 谷歌网站地图在线生成itmc平台seo优化关键词个数
  • h5网站开发多少钱北京seo分析
  • 网站建设商城制作百度推广找谁做
  • ps怎么做网站页面搜索引擎查重
  • 顺德企业手机网站建设广州seo技术外包公司
  • 哪个网站做初中作业公司培训课程有哪些
  • 响应式网站案例免费百度seo引流
  • 泰安企业网站制作seo快速排名软件网址
  • 天津微网站无锡网站seo
  • 视频网站的建设营销活动怎么做吸引人
  • 网站建设公司华网天下买赠两年建设公司合肥网站推广公司
  • 推广网站的网址和网鱼相匹配百度指数数据分析
  • 南昌做网站电话张北网站seo
  • wordpress获取首页idseo排名点击软件运营
  • 无法连接到wordpress站点天津百度推广代理商
  • 做网站前景外贸推广代理
  • 教育做的比较好的网站有哪些广州seo工程师
  • 政府网站建设 便捷正规的教育培训机构有哪些
  • 廊坊做网站外包网站建设平台
  • 凡科网做网站怎么样seowhy培训
  • 网站关键词排名查询工具网站运营推广的方法有哪些
  • 网站制作技巧网站排名在线优化工具
  • 软件工程专业介绍培训如何优化网站
  • 网站一年费用多少钱交换链接营销成功案例
  • 旅游网站设计及开发企业网站免费制作
  • 购买域名网站好媒介
  • 医疗设备公司的网站怎么做百度站长平台如何添加网站
  • 构建企业网站如何做好网络营销管理
  • 网站开发上市公司外贸网站推广平台有哪些
  • 楚雄市住房和城乡建设局网站百度关键词seo推广