套马的汉子你威武雄壮是什么歌| 女人手指粗短是什么命| 自然卷的头发适合什么发型| 人这一生什么最重要| 搭档是什么意思| 岁月匆匆像一阵风是什么歌| 黑松露是什么| 现在什么时辰| 小孩肚子疼拉肚子吃什么药| 清洁度111是什么意思| 淋巴结有什么症状| 妈宝男什么意思| 区教育局局长是什么级别| 读书心得是什么意思| 八四年属什么生肖| vs的意思是什么| 强直性脊柱炎有什么症状| swisse是什么药| 印度尼西亚是什么人种| 零零年属什么| 农历六月初七是什么星座| 宽宽的什么| 什么动物牙齿最多| 什么食物含蛋白高| 六味地黄丸的功效是什么| 家财万贯是什么动物| 五金是什么| 全身是宝的动物是什么生肖| 60年属鼠是什么命| 俺是什么意思| 高铁为什么会晚点| 正常的精液是什么样的| 梦见一个人代表什么| 鼻子两侧挤出来的白色东西是什么| 睡眠障碍应该挂什么科室| 矫枉过正什么意思| 疲劳是什么意思| 什么肠小道成语| 口酸吃什么药| 摩卡是什么意思| 93鸡和94狗生什么宝宝| 巴旦木是什么| 肚脐眼为什么会有臭味| 清新是什么意思| 矿物油是什么| 念力是什么意思| 什么时候敷面膜是最佳时间| 庆生是什么意思| 心肌酶是什么意思| 世界杯是什么时候| 新疆为什么天黑的晚| 九月十号什么星座| 羊经后半边读什么| 黄帝是一个什么样的人| 胃不好吃什么好| 什么是生僻字| 代谢不好吃什么药| 高压150低压100吃什么药| 肺静脉流的是什么血| bp在医学上是什么意思| 狮子的天敌是什么动物| 百香果是什么季节的水果| 四五行属什么| 秘诀是什么意思| 猪冲蛇开什么生肖| 神什么什么神| 大年初一是什么生肖| 泡果酒用什么酒好| 什么是绿色食品| pco是什么意思| 肝风内动是什么意思| 不想吃饭没胃口是什么原因| 5.29是什么星座| 一什么之| 什么药治便秘最好最快| 1972年出生属什么生肖| 角色扮演是什么意思| 为什么总打嗝| 腊猪脚炖什么好吃| 离婚都需要什么| 舌尖疼是什么原因| 蚊子代表什么生肖| 小叶增生是什么原因导致的| 眼珠子发黄是什么原因| 广角是什么| 更年期是什么意思| 肌酐低有什么危害| 梦到孩子被蛇咬是什么意思| who是什么组织| 踏雪寻梅是什么意思| 吃什么补血效果最好| 人类的祖先是什么生肖| 办健康证要带什么证件| 腿部青筋明显是什么原因| 六月二十五号是什么星座| 小翅膀车标是什么车| 阿q精神是什么意思| 女人吃桃子有什么好处和坏处| 灰指甲挂号挂什么科| 降三高喝什么茶最好| 蓝五行属什么| 3.17是什么星座| ray是什么意思| 不免是什么意思| 胆囊肿是什么病严重吗| 崇敬是什么意思| 遭罪什么意思| bi是什么意思| 五味子不适合什么人喝| 风象星座是什么意思| 补肾益精是什么意思| 恐龙为什么会灭绝| 籽字五行属什么| 什么叫集体户口| 阴壁有许多颗粒是什么原因| 产后42天复查挂什么科| 洁身自爱是什么意思| 6点是什么时辰| 六三年属什么生肖| 红肠是什么| 单亲家庭是什么意思| 紧凑是什么意思| 齁不住是什么意思| 底线是什么意思| 纸老虎是什么意思| 双肺结节是什么病| 脸上脱皮是什么原因| 副军级是什么级别| 魂穿是什么意思| 辟谷是什么意思| 吃什么能化解肾结石| 属兔什么命| 低压高是什么原因| mar是什么意思| 总是爱出汗是什么原因| 灰指甲用什么药好| 晕菜是什么意思| 股骨头坏死有什么症状| 肌酐偏低是什么原因| 耐药菌感染什么意思| 口腔疱疹用什么药| 伏羲和女娲是什么关系| 小猫的尾巴有什么作用| 喉咙里老是有痰是什么原因| 马为什么不怕蛇毒| 过生日送什么礼物好| 下巴长闭口是什么原因| 龙涎是什么| 皮脂腺囊肿吃什么消炎药| 什么是道| 孕晚期血糖高对胎儿有什么影响| 新生儿dha什么时候开始吃| 比是什么| 克罗恩病有什么症状| 妙赞是什么意思| 用一什么就什么造句| 激光点痣后需要注意什么| 痈是什么意思| 马加其念什么| 石榴代表什么生肖| 腰椎间盘突出适合什么运动| 空巢老人什么意思| p图是什么意思| 蒲公英什么时候播种| 龙代表什么象征意义| 最高检检察长什么级别| 荷叶有什么功效| 三头六臂开过什么生肖| 鲜红的什么| 糖尿病的根源是什么| 补是什么偏旁| 嘴巴很臭是什么原因引起的| 兰花长什么样| 红颜薄命的意思是什么| 松茸是什么东西| 玉兰花什么季节开| 头疼是为什么| 朝秦暮楚是什么意思| 春天有什么动物| 水洗棉是什么| 消化不良的症状吃什么药| 四个一是什么| 微白蛋白高是什么情况| 孩子干咳吃什么药效果好| 望梅止渴是什么故事| 脚麻是什么病的前兆| 12.28是什么星座| 网球肘吃什么药| 不自觉是什么意思| 七月份什么星座| 牛肉炒什么| 热结旁流是什么意思| 四个金读什么| 李世民是什么生肖| 梦到女朋友出轨是什么意思| 潮吹是什么感觉| 叔叔的女儿叫什么| 12月21日什么星座| 蜱虫咬了什么症状| 灵芝有什么好处| 小县城适合做什么生意| 膨鱼鳃用什么搭配煲汤| 菩萨是什么意思| 十年什么婚| 存是什么生肖| 法令纹上的痣代表什么| 胃病不能吃什么| 附骨疽是什么病| 余事勿取什么意思| 肾囊肿有什么危害| bgm网络语什么意思| 狗狗拉血是什么原因| 蚊子喜欢什么气味| 孕妇建档是什么意思| 发痧吃什么药可以断根| 富二代是什么意思| 覅是什么意思| 荆州有什么大学| 血糖高能吃什么菜| 龙涎香是什么东西| 四大美女指什么生肖| 卖什么小吃简单挣钱| 男人时间短吃什么药好| 19属什么| 冬瓜不能和什么一起吃| 气血不足什么引起的| 灰指甲医院挂什么科| 处女座与什么星座最配| 浮躁的意思是什么| 昆仑雪菊有什么作用| 什么叫疝气| 宫颈炎是什么病| hpv病毒是什么| 甲醛超标有什么危害| 性生活是什么意思| 兔配什么生肖最好| 什么叫外阴白斑| 白细胞偏高是什么意思| 梦见摘杏子是什么意思| 视线模糊是什么原因| 狗狗吐是什么原因| aug是什么意思| 软文什么意思| 低聚异麦芽糖是什么| 头晕恶心什么原因| 气血不足吃什么食物最好| 青稞是什么| 1月8号是什么星座| 推什么出什么| 心梗吃什么药效果好| 身体动不动就出汗是什么原因| 及笄是什么意思| 孕妇梦见棺材是什么征兆| 麦粒肿涂什么药膏| 经过的意思是什么| 发烧能吃什么食物| 吃力不讨好是什么意思| 二月七号是什么星座| 为什么感觉| 梦见死人了是什么意思| 咳嗽有黄痰吃什么药| ACG是什么牌子| 什么人一年只工作一天脑筋急转弯| 血管炎是什么症状| 百度Jump to content

丰县--江苏频道--人民网

From Wikipedia, the free encyclopedia
百度 我国军机特别是战斗机经过这么多年努力,已经逐步地跃到了世界第二梯队,甚至是靠前的位置,这是被世界所逐步认可的。

In software architecture, the publish–subscribe pattern (pub/sub) is a messaging pattern in which message senders, called publishers, categorize messages into classes (or topics), and send them without needing to know which components will receive them. Message recipients, called subscribers, express interest in one or more classes and only receive messages in those classes, without needing to know the identity of the publishers.

This pattern decouples the components that produce messages from those that consume them, and supports asynchronous, many-to-many communication. The publish–subscribe model is commonly contrasted with message queue-based and point-to-point messaging models, where producers send messages directly to consumers.

Publish–subscribe is a sibling of the message queue paradigm, and is typically a component of larger message-oriented middleware systems. Many modern messaging frameworks and protocols, such as the Java Message Service (JMS), Apache Kafka, and MQTT, support both the pub/sub and queue-based models.

This pattern provides greater network scalability and supports more dynamic topologies, but can make it harder to modify the publisher’s logic or the structure of the published data. Compared to synchronous patterns like RPC and point-to-point messaging, publish–subscribe provides the highest level of decoupling among architectural components. However, it can also lead to semantic or format coupling between publishers and subscribers, which may cause systems to become entangled or brittle over time.[1]

Message filtering

[edit]

In publish–subscribe systems, subscribers typically receive only a subset of messages. The process of selecting relevant messages is called filtering, and it can be implemented in several ways:

  • Topic-based filtering: Messages are published to named topics or channels. Subscribers register to receive messages on specific topics, and receive all messages published to them.
  • Content-based filtering: Subscribers define constraints based on message attributes or content. Messages are delivered only if they match the subscriber's criteria.
  • Hybrid systems: Some implementations combine topic- and content-based filtering. Messages are categorized by topic, and subscribers apply content-based filters to messages within those topics.

Topologies

[edit]

In most pub/sub systems, publishers and subscribers communicate through a central intermediary such as a message broker or event bus. The broker receives messages from publishers and forwards them to the appropriate subscribers, optionally performing store and forward, priority queuing, or other routing logic.[citation needed]

Subscriber registration can occur at different times:

  • Build time: Subscribers are hardcoded to handle specific messages or events (e.g., GUI event handlers).
  • Initialization time: Subscriptions are defined in XML configuration files or metadata.
  • Runtime: Subscriptions can be added or removed dynamically (e.g., database triggers, RSS readers).

Some pub/sub systems use brokerless architectures, in which publishers and subscribers discover each other and exchange messages directly. For example, the Data Distribution Service (DDS) middleware uses IP multicast and metadata sharing to establish communication paths. Brokerless systems require construction of overlay networks, often using Small-World topologies to enable efficient routing.[citation needed]

It was shown by Jon Kleinberg that efficient decentralized routing requires Navigable Small-World topologies, which are employed in federated or peer-to-peer pub/sub systems.[2] Locality-aware pub/sub networks use low-latency links to reduce message propagation time.[3]

History

[edit]

One of the earliest publicly described pub/sub systems was the "news" subsystem of the Isis Toolkit, presented at the 1987 ACM Symposium on Operating Systems Principles (SOSP '87).[4]

Although the publish–subscribe pattern is now typically distinguished from the observer pattern due to its emphasis on decoupling and distributed communication, early usage in literature and systems sometimes used the terms interchangeably, especially in the context of in-process event handling or GUI frameworks.[5] As distributed systems became more common, the publish–subscribe model evolved to emphasize asynchronous messaging and broker-mediated communication, setting it apart from the more tightly coupled observer pattern.

Advantages

[edit]

Loose coupling

[edit]

Publishers are loosely coupled to subscribers, and need not even know of their existence. With the topic being the focus, publishers and subscribers are allowed to remain ignorant of system topology. Each can continue to operate as per normal independently of the other. In the traditional tightly coupled client–server paradigm, the client cannot post messages to the server while the server process is not running, nor can the server receive messages unless the client is running. Many pub/sub systems decouple not only the locations of the publishers and subscribers but also decouple them temporally. A common strategy used by middleware analysts with such pub/sub systems is to take down a publisher to allow the subscriber to work through the backlog (a form of bandwidth throttling).

Scalability

[edit]

Pub/sub provides the opportunity for better scalability than traditional client-server, through parallel operation, message caching, tree-based or network-based routing, etc. However, in certain types of tightly coupled, high-volume enterprise environments, as systems scale up to become data centers with thousands of servers sharing the pub/sub infrastructure, current vendor systems often lose this benefit; scalability for pub/sub products under high load in these contexts is a research challenge.

Outside of the enterprise environment, on the other hand, the pub/sub paradigm has proven its scalability to volumes far beyond those of a single data center, providing Internet-wide distributed messaging through web syndication protocols such as RSS and Atom. These syndication protocols accept higher latency and lack of delivery guarantees in exchange for the ability for even a low-end web server to syndicate messages to (potentially) millions of separate subscriber nodes.

Message delivery issues

[edit]

Redundant subscribers in a pub/sub system can help assure message delivery with minimal additional complexity. For example, a factory may utilize a pub/sub system where equipment can publish problems or failures to a subscriber that displays and logs those problems. If the logger fails (crashes), equipment problem publishers won't necessarily receive notice of the logger failure, and error messages will not be displayed or recorded by any equipment on the pub/sub system. In a client/server system, when an error logger fails, the system will receive an indication of the error logger (server) failure. However, the client/server system will have to deal with that failure by having redundant logging servers online, or by dynamically spawning fallback logging servers. This adds complexity to the client and server designs, as well as to the client/server architecture as a whole. In a pub/sub system, redundant logging subscribers that are exact duplicates of the existing logger can be added to the system to increase logging reliability without any impact to any other equipment on the system. The feature of assured error message logging can also be added incrementally, subsequent to implementing the basic functionality of equipment problem message logging.

Disadvantages

[edit]

The most serious problems with pub/sub systems are a side-effect of their main advantage: the decoupling of publisher from subscriber.

Message delivery issues

[edit]

A pub/sub system must be designed carefully to be able to provide stronger system properties that a particular application might require, such as assured delivery.

  • The broker in a pub/sub system may be designed to deliver messages for a specified time, but then stop attempting delivery, whether or not it has received confirmation of successful receipt of the message by all subscribers. A pub/sub system designed in this way cannot guarantee delivery of messages to any applications that might require such assured delivery. Tighter coupling of the designs of such a publisher and subscriber pair must be enforced outside of the pub/sub architecture to accomplish such assured delivery (e.g. by requiring the subscriber to publish receipt messages).
  • A publisher in a pub/sub system may assume that a subscriber is listening, when in fact it is not.

The pub/sub pattern scales well for small networks with a small number of publisher and subscriber nodes and low message volume. However, as the number of nodes and messages grows, the likelihood of instabilities increases, limiting the maximum scalability of a pub/sub network. Example throughput instabilities at large scales include:

  • Load surges—periods when subscriber requests saturate network throughput followed by periods of low message volume (underutilized network bandwidth)
  • Slowdowns—as more and more applications use the system (even if they are communicating on separate pub/sub channels) the message volume flow to an individual subscriber will slow

For pub/sub systems that use brokers (servers), the argument for a broker to send messages to a subscriber is in-band, and can be subject to security problems. Brokers might be fooled into sending notifications to the wrong client, amplifying denial of service requests against the client. Brokers themselves could be overloaded as they allocate resources to track created subscriptions.

Even with systems that do not rely on brokers, a subscriber might be able to receive data that it is not authorized to receive. An unauthorized publisher may be able to introduce incorrect or damaging messages into the pub/sub system. This is especially true with systems that broadcast or multicast their messages. Encryption (e.g. Transport Layer Security (SSL/TLS)) can prevent unauthorized access, but cannot prevent damaging messages from being introduced by authorized publishers. Architectures other than pub/sub, such as client/server systems, are also vulnerable to authorized message senders that behave maliciously.

See also

[edit]

References

[edit]
  1. ^ Hohpe, Gregor (2003). Enterprise Integration Patterns: Designing, Building, and Deploying Messaging Solutions. Addison-Wesley Professional. ISBN 978-0321200686.
  2. ^ a b Chen, Chen; Tock, Yoav; Girdzijauskas, Sarunas (2018). "BeaConvey". Proceedings of the 12th ACM International Conference on Distributed and Event-based Systems. Hamilton, New Zealand: ACM Press. pp. 64–75. doi:10.1145/3210284.3210287. ISBN 9781450357821. S2CID 43929719.
  3. ^ Rahimian, Fatemeh; Le Nguyen Huu, Thinh; Girdzijauskas, Sarunas (2012), G?schka, Karl Michael; Haridi, Seif (eds.), "Locality-Awareness in a Peer-to-Peer Publish/Subscribe Network", Distributed Applications and Interoperable Systems, vol. 7272, Springer Berlin Heidelberg, pp. 45–58, doi:10.1007/978-3-642-30823-9_4, ISBN 9783642308222
  4. ^ Birman, K.; Joseph, T. (1987). "Exploiting virtual synchrony in distributed systems". Proceedings of the Eleventh ACM Symposium on Operating Systems Principles - SOSP '87. pp. 123–138. doi:10.1145/41457.37515. ISBN 089791242X. S2CID 7739589.
  5. ^ The Windows Programming Experience, Charles Petzold, November 10, 1992, PC Magazine (Google Books)


木耳菜不能和什么一起吃 尿酸高多吃什么食物好 头晕吃什么药效果好 肝低密度灶是什么意思 咳嗽吐黄痰是什么原因
land rover是什么车 什么是狂躁症 肾积液是什么原因造成的 肠系膜淋巴结肿大吃什么药 dha不能和什么一起吃
晕车是什么原因 什么是破伤风 河粉是什么材料做的 推迟月经用什么药 口臭吃什么药效果最好
骨加客读什么 头发不干就睡觉有什么危害 三八是什么意思 生蚝是什么东西 与虎谋皮什么意思
脾虚挂什么科hcv8jop5ns2r.cn 甲钴胺有什么副作用hcv8jop3ns5r.cn 下巴脖子长痘痘是什么原因hcv9jop4ns7r.cn 过期牛奶有什么用途hcv8jop8ns1r.cn 脚趾头麻木是什么原因clwhiglsz.com
pdw偏低是什么意思hcv8jop5ns5r.cn wb是什么意思hcv8jop9ns6r.cn 润物细无声是什么意思hcv9jop6ns7r.cn 什么是地中海贫血imcecn.com 老虎菜为什么叫老虎菜inbungee.com
虎与什么生肖相合hcv9jop4ns8r.cn 枧水是什么520myf.com 隔天是什么意思hcv9jop2ns2r.cn 广州有什么特产必带hcv9jop2ns2r.cn 孩子张嘴睡觉是什么原因hcv8jop9ns5r.cn
早上5点多是什么时辰hcv8jop0ns4r.cn 气虚用什么泡水喝好hcv7jop9ns4r.cn 黑猫进家门预示着什么hcv9jop6ns2r.cn 吃什么排湿气效果好zhiyanzhang.com 黄豆什么时候播种hcv8jop2ns9r.cn
百度