一种基于空间文本信息流的分布式的发布订阅算法
2021-07-11周泽宁
周泽宁



摘 要:发布订阅系统是进行发布的事件和订阅消息之间的匹配系统。首先需要对订阅消息进行聚类操作,按照聚类结果,找到事件所属类别,随后在类别中,找寻和事件匹配的订阅。本文提出了一个即时的发布订阅的算法,统筹空间信息和事件属性信息,不仅可以即时地处理事件和订阅的匹配操作,也可以在分布式环境上即时地进行订阅的更新和类别的更新。并且可以在没有先验知识的情况下即时地进行聚类操作和匹配操作。设计一个分布式的系统,将发布订阅算法部署其上,并且提出了在分布式系统上该算法的负载均衡策略。随后通过自建集群,使用真实的数据,实验验证本文提出的发布订阅算法。
关键词: 发布订阅系统;分布式系统;聚类算法
文章编号: 2095-2163(2021)01-0046-06 中图分类号:TP391.1 文献标志码:A
【Abstract】The publish and subscribe system is a matching system between published events and subscribed messages. First, it is necessary to perform a clustering operation on the subscription messages, find the category to which the event belongs according to the clustering result, and then find the subscription that matches the event in the category. This paper proposes an instant publish and subscribe algorithm, which coordinates the spatial information and event attribute information. It can not only handle the matching operation of events and subscriptions in real time, but also update subscriptions and categories in a distributed environment. In addition, clustering and matching operations can be performed immediately without prior knowledge. A distributed system is designed, the publish-subscribe algorithm is deployed on it, and the load balancing strategy of the algorithm is put forward on the distributed system. Therefore through the self-built cluster, using real data, the publish and subscribe algorithm proposed in this article is verified in the experiments.
【Key words】publish and subscribe system; distributed system; clustering algorithm
0 引 言
發布订阅系统主要目的是方便事件发布者和事件订阅者在网上进行信息交换这一过程,事件的订阅者持续关注某一特定区域内的特定事件,事件的发布者将事件发生的空间位置和事件发布到网上,随后这些事件和事件订阅者的订阅信息进行匹配并将符合要求的事件推送给订阅者。
中央服务器上基于空间属性信息的发布订阅算法[1-8],使用树状结构按照空间索引订阅数据,以加速空间属性事件和空间属性订阅的比较。许多分布式系统[9-12]使用现有的空间索引将数据划分到不同的服务器,这些系统是基于静态数据的一次性查询。……
