A Scalable Brokerless Messaging Strategy Using a Sidecar Security Container Stack
A brokerless Pub/Sub messaging network using a service mesh and sidecar proxies with mTLS encryption addresses latency and scalability issues in cloud architectures, enabling efficient, secure communication between distributed applications.
Patent Information
- Application Number
- JP2023548301
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Priority Date
- 2021-02-12
- Filing Date
- 2022-02-03
- Publication Date
- 2024-10-08
- Estimated Expiration
- 2042-02-03
AI Technical Summary
Existing cloud-based publish/subscribe (Pub/Sub) messaging networks suffer from significant latency due to the use of intermediate message brokers and lack support for secure, scalable, brokerless communication protocols, particularly in serverless and microservices architectures.
A scalable brokerless Pub/Sub messaging network utilizing a service mesh with a control plane and sidecar security container stack, employing mutual Transport Layer Security (mTLS) encryption and dynamic DNS resolution to facilitate secure, low-latency communication between service nodes, enabling vertical scaling and load balancing without message brokers.
The solution provides low-latency, scalable, and secure Pub/Sub messaging without brokers, supporting dynamic service scaling and load balancing, ensuring secure communication and efficient message delivery across distributed applications.
Smart Images

Figure 0007563865000001 
Figure 0007563865000002 
Figure 0007563865000003
Abstract
Description
[Technical field]
[0001] The present disclosure relates to asynchronous inter-service communication networks, and in particular to publish / subscribe messaging services.
[0002] CROSS-REFERENCE TO RELATED APPLICATIONS This application claims the benefit of priority to U.S. Patent Application No. 17 / 174,848, filed February 12, 2021, which is incorporated by reference in its entirety. [Background technology]
[0003] Publish / subscribe messaging (commonly referred to as "Pub / Sub" messaging) is a form of asynchronous inter-service communication used in serverless and microservices architectures. In a Pub / Sub messaging network, services that generate events are decoupled from services that process events. "Publisher applications" create and send messages to "topics," while "subscriber applications" create "subscriptions" to one or more topics. Subscriber applications thus receive messages sent to the topics to which they subscribe. In other words, any message published to a topic is received by all subscribers to that topic. Summary of the Invention
[0004] According to a non-limiting embodiment, a scalable brokerless messaging network includes a service mesh that implements a plurality of service nodes that signal each other to exchange a plurality of messages. A control plane is configured to signal the plurality of service nodes, register application services associated with particular service nodes included in the service mesh, and provide certificates necessary for encrypted inter-service communication. The plurality of service nodes define a messaging middleware layer that establishes a number of point-to-point connections between each service in the network via Transmission Control Protocol (TCP) sockets.
[0005] According to another non-limiting embodiment, a method for exchanging data in a scalable brokerless messaging network includes establishing signaling communication between a service mesh including a plurality of service nodes for exchanging a plurality of messages, and establishing signaling communication between a control plane and the plurality of service nodes. The method further includes registering an application service associated with a particular service node included in the service mesh and the control plane. The method further includes defining a messaging middleware layer over the plurality of service nodes to establish a plurality of point-to-point connections between each service node in the service mesh via Transmission Control Protocol (TCP) sockets.
[0006] According to yet another non-limiting embodiment, a messaging middleware layer included in a scalable brokerless messaging network includes a first application process included in a first service node, configured to operate according to the messaging middleware layer and to exchange data with at least one second application process included in at least one second service node, and the messaging middleware layer dynamically manages a Transmission Control Protocol (TCP) socket connection established between the first service node and the second service node.
[0007] Additional features and advantages are realized through the techniques of the present disclosure. Other embodiments and aspects are described in detail herein and are considered a part of the claimed disclosure. For a better understanding of the present disclosure, together with its advantages and features, reference is made to the description and drawings.
[0008] For a more complete understanding of the present disclosure, reference is now made to the accompanying drawings and the following brief description of the drawings in conjunction with the detailed description, in which like reference numerals represent like parts. [Brief description of the drawings]
[0009] [Figure 1A] FIG. 1 is a block diagram of a scalable brokerless messaging network according to a non-limiting embodiment. [Figure 1B] FIG. 1 is a block diagram of a scalable brokerless messaging network according to a non-limiting embodiment. [Figure 2A] FIG. 2 is a block diagram of a scalable brokerless messaging network according to another non-limiting embodiment. [Figure 2B] FIG. 2 is a block diagram of a scalable brokerless messaging network according to another non-limiting embodiment. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0010] In modern cloud architectures, applications are decoupled into smaller independent components (sometimes called distributed applications) that are easier to develop, deploy, and maintain. Pub / Sub messaging can provide instant event notification for these distributed applications. Many known cloud-based networks that support Pub / Sub systems employ an intermediate message "broker" to which one or more subscribers register their subscriptions. The broker performs a store-and-forward function to filter published messages and route messages from publishers to subscribers that have subscriptions to a particular publisher. However, the operations performed by the broker add significant latency to end-to-end message delivery. In addition, traditional cloud architectures typically do not support protocols that can facilitate traditional "brokerless" Pub / Sub messaging networks. For example, a common solution to facilitate brokerless Pub / Sub messaging involves the adoption of a User Datagram Protocol (UDP) multicast scheme. However, the UDP multicast scheme is not supported by many cloud-based architectures and cloud service providers because it is often blocked by the cloud network layer and there is no standard way to secure communication between publishers and subscribers.
[0011] Various non-limiting embodiments described herein provide a scalable brokerless Pub / Sub messaging network. In one or more non-limiting embodiments, the scalable brokerless Pub / Sub messaging network can dynamically scale across the service mesh based on the load realized by the service mesh, and is secure by default through the use of a control plane such as "Istio", e.g., providing a "zero trust" architecture and mutual Transport Layer Security (mTLS) encryption between each service node included in the messaging network. A service mesh can achieve scalability using a messaging middleware layer that can support a topology that can dynamically increase the number of instances of a service (e.g., the number of service pods). For example, a service mesh can monitor load and dynamically add service pods to provide relief to a particular service node. Scalability can also be achieved through the ability of the messaging middleware layer to support "vertical scaling" to address increasing demand, and communication between a dynamic number of services in the network.
[0012] In one or more non-limiting embodiments, a scalable brokerless pub / sub messaging network employs a "sidecar" security container stack, also referred to as a "sidecar proxy," that cooperates with service nodes in the control plane to discover each other, establish encrypted communications, and load balance using dynamic Domain Name System (DNS) resolution and network address translation to dynamically route traffic between services. Services in the control plane dynamically track and distribute load among multiple instances of a service (e.g., service pods), and upon ingress, the sidecar proxy uses network address translation to translate a destination IP address to the IP address of the destination container in the service pod.
[0013] In one or more embodiments, the scalable brokerless Pub / Sub messaging network includes a messaging middleware layer designed to work natively with a service mesh to provide low-latency, scalable Pub / Sub messaging without the use of message brokers. The messaging middleware utilizes Transmission Control Protocol (TCP) sockets, which can be encrypted using mutual TLS (mTLS) by the sidecar proxy 112 to secure data exchanges between services included in the scalable brokerless Pub / Sub messaging network 100.
[0014] 1, a scalable brokerless messaging network 100 is shown according to a non-limiting embodiment. The scalable brokerless messaging network 100 uses a control plane 102 and a service mesh that includes multiple service nodes 104, 106, 108, 110 (collectively referred to as 104-110). Although four service nodes 104-110 are shown, more or fewer service nodes may be implemented without departing from the scope of the present disclosure.
[0015] The control plane 102 signals to a sidecar proxy 112 of each of the service nodes 104-110 via a control plane service interface 103 (depicted by signal arrow 103) included in the service mesh. The sidecar proxy is configured to protect the Pub / Sub messaging exchanged between the service nodes 104-110 by providing security and management operations, including, but not limited to, service discovery, load balancing, message routing, configuration management, authentication and authorization, and data / message encryption. In one or more non-limiting embodiments, the control plane 102 can manage the service mesh using services such as those provided by "Istio" to provide security concepts such as a "zero trust" architecture and mutual TLS (mTLS).
[0016] Service nodes 104-110 are configured to exchange data with one another. Each service node 104-110 includes one or more instances of a service, referred to as a "service pod." For example, service node 104 includes service pods 105a, 105b, . . . , 105n (collectively referred to as 105a-105n), service node 106 includes service pod 107a, service node 108 includes service pod 109a, and service node 110 includes service pod 111a. In one or more non-limiting embodiments, a service node included in a service mesh can function as a control service node. For example, service node 110 can function as a control service node 110.
[0017] Each of the service nodes 104-110 includes a sidecar proxy 112 configured to establish encrypted data exchanges with each other. The encrypted data exchanged between the services includes an encrypted control messaging connection 150 and an encrypted data connection 152. The encrypted control messaging connection 150 exchanges "critical information" such as, for example, time synchronization messages and notifications of top-level operational changes that warrant behavioral changes. The encrypted data connection 152 (i.e., a data Pub / Sub channel) exchanges general publish / subscribe data, i.e., publish data generated by an application and received by one or more subscribers.
[0018] Each service may include a control socket ("ctrl socket") 116 and a data socket 118. The ctrl socket 116 and the data socket 118 are independent or separate from one another. In one or more non-limiting embodiments, each sidecar proxy 112 may exchange data with the control plane 102 via the control plane service interface 103. Upon initialization, the services in the control plane 102 provide configuration data to each sidecar proxy 112 of the service nodes 104-110. This configuration data may include, but is not limited to, security credentials used for encrypted communications within the deployment, role-based access control (RBAC) rules, and information about other services in the deployment. The configuration data is used for both discovery and authorization so that a particular application service 114-125 may register itself with each service node 104-110 included in the service mesh. In one or more non-limiting embodiments, each service node 104-110 generates a TCP list that includes each TCP socket connection between each application service 114-125. Thus, the application services 114-125 establish a messaging middleware layer that delivers messages from the publisher service nodes to one or more subscriber service nodes based on the TCP connections contained in the TCP list. Once this initialization process is complete, the service nodes 104-110 are able to securely communicate with each other in the service mesh.
[0019] Sidecar proxy 112, in coordination with control plane 102, performs load balancing by dynamically tracking and distributing traffic within the service mesh based on messaging policies. This dynamic routing uses dynamic DNS resolution to deliver messages to designated instances of vertically scaled services, as shown in service node 104. For example, messages published by service nodes 106-110 are delivered to respective scaled instances of pods 105a, 105n, ..., 105n in service node 104 according to load balancing rules.
[0020] The service nodes 104-110 establish a messaging middleware layer that facilitates a brokerless Pub / Sub messaging pattern that utilizes their respective sidecar proxies 112 and a service mesh to facilitate secure communications. In one or more non-limiting embodiments, the service nodes 104-110 establish a messaging middleware layer that facilitates brokerless Pub / Sub messaging in a cloud computing environment. However, it should be understood that the middleware layer is not limited to a cloud computing environment. For example, the messaging middleware may be used in an embedded system without departing from the scope of the present disclosure. As described herein, the service node 110 may function as a control service node 110, while the remaining service nodes 104-108 may function as worker service nodes 104-108. The control service node 110 is responsible for providing critical information that must be received by each service node 104-110 in the mesh, including scaled instances of a single service (e.g., service 104). Examples of critical information include time synchronization messages and notifications of top-level operational changes that warrant changes in behavior. When a control service node 110 is used within a service mesh, all worker service nodes 104-108 must establish a connection to the control service node 110 via their respective ctrl sockets 116 in order to receive important information described herein.
[0021] The worker service nodes 104-108 are also interconnected (e.g., in a one-to-many or many-to-many relationship) via data sockets 118 to establish a data plane. In one or more non-limiting embodiments, the data plane uses a multi-publisher / multi-subscriber relationship to facilitate a Pub / Sub messaging scheme. This is implemented using the TCP protocol such that each service node has multiple point-to-point connections to other service nodes in the network. Thus, for a deployment with "N" service nodes, each service node establishes N-1 TCP connections. The messaging middleware delivers all outgoing messages on the encrypted data connection 152 to each of these connections. Filtering of message subscriptions is done at the receiving side of the middleware. If a service receives a message that it is not subscribed to, it may be dropped.
[0022] In one or more non-limiting embodiments, the control service node 110 uses a single publisher to multiple subscriber relationship for its messaging scheme. Thus, if high availability is a design goal, and the control service is stateless or its state is externalized using a caching service, the control service node 110 can be configured to provide redundancy through the use of a circuit breaker routing pattern within the service mesh.
[0023] When a message is sent from a particular application process 114, 117, 119, 121, 123, and 125 (i.e., a host application process), the message is sent with a destination service address and a destination port. The corresponding host sidecar proxy 112 intercepts this traffic and queries the control plane for the specific IP address information of the destination service. The control plane 102 uses its routing and load balancing rules to provide the host sidecar proxy 112 with the specific IP address of the destination sidecar proxy 112. In one or more non-limiting embodiments, the control plane 102 scales instances of service pods to aggregate each service node 104-110. For example, the control plane 102 can automatically increase the number of service pods in a particular service node 104-110 based on the load and available resources (e.g., CPU processing, RAM usage, etc.) in the scalable brokerless messaging network 100.
[0024] The host sidecar proxy 112 encrypts outgoing data (e.g., published messages) using the public key of the destination sidecar proxy 112 and sends it. The destination sidecar proxy 112 included in the destination service node receives the incoming data (e.g., incoming messages), decrypts it using its private key, and delivers the decrypted data / message to the destination application processes 114, 117, 119, 121, 123, and 125 included in the service pod.
[0025] 2, there is shown a scalable brokerless messaging network 200 according to another non-limiting embodiment. Scalable brokerless messaging network 200 includes multiple service nodes 104, 106, 108 and one or more service forwarder pods 202a and 202b. Service node 104 includes service pods 105a-105n, service node 106 includes service pods 107a and 107b, and service node 108 includes service pod 109a.
[0026] Service forwarder pods 202a and 202b facilitate the ability to aggregate and forward messages 154 between multiple scaled instances of multiple service pods in a mesh network. Although two service forwarder pods 202a and 202b are shown, more or fewer service forwarder pods may be used without departing from the scope of this disclosure.
[0027] The service forwarder pods 202a and 202b are configured to aggregate messages 154 to corresponding service nodes 104 or 106 and distribute messages among service pods on egress by querying the control plane for specific IP address information of the sidecar proxy of the destination service pod. The control plane provides IP addresses to the service pods 105a-105n or 107a-107b according to load balancing rules. The service forwarder pods 202a and 202b can resolve unbalanced connections. For example, the service forwarder pods 202a and 202b can resolve unbalanced connections that occur when multiple vertically scaled service pods communicate within the same publish and subscribe network with unbalanced many-to-many connections as each instance of the service pod grows. For example, unbalanced connections can occur when one service pod on a first service node does not have a corresponding connection to a service pod on a second service node. Thus, application services 114 from a scaled service node (e.g., service node 104) may not be able to receive messages published by other application services in other service nodes 106-110. As a result, if service pods 105a-105n do not have direct connections to their respective subscriber destinations, imbalanced connections may occur because individual point-to-point connections with all destination subscriber service nodes 107a-107b are not established. Forwarder pods 202a and 202b can solve the aforementioned problem and route messages in a manner that maintains the balance of the service mesh.
[0028] Corresponding structures, materials, acts, and equivalents of all means or step-plus-function elements within the scope of the following claims are intended to include any structure, material, or act for performing a function in combination with other specifically claimed claim elements. The description of the present disclosure has been presented for purposes of illustration and description, but is not intended to be exhaustive or limited to the embodiments in the form disclosed. Many modifications and variations will be apparent to those skilled in the art without departing from the scope and spirit of the present disclosure. The selection and description of the embodiments has been made in order to best explain the principles and practical application of the present disclosure, and to enable others skilled in the art to understand the present disclosure to various embodiments with various modifications suitable for the particular use intended.
[0029] While preferred embodiments to the present disclosure have been described, it should be understood that those skilled in the art, both now and in the future, may make various improvements and enhancements that fall within the scope of the following claims, which should be construed to maintain the appropriate protection for the present disclosure as first described.
Claims
1. 1. A scalable brokerless messaging network, comprising: a service mesh including a plurality of service nodes in signal communication with each other to exchange a plurality of messages; a control plane configured to signal the plurality of service nodes and to register application services associated with particular service nodes included in the service mesh; Including, the plurality of service nodes defines a messaging middleware layer that establishes several point-to-point connections between each service in the network via Transmission Control Protocol (TCP) sockets; A scalable brokerless messaging network.
2. each of the service nodes includes a sidecar proxy; the sidecar proxy encrypts an outgoing message generated by a host application process with a public key of a destination service node of the plurality of service nodes; decrypting the received message using the private key and delivering the decrypted received message to a destination application process; It is configured as follows:
10. The scalable brokerless messaging network of claim 1.
3. At least one of the service nodes of the plurality of service nodes operates as a control service node; and The remaining service nodes included in the plurality of service nodes function as worker service nodes.
3. The scalable brokerless messaging network of claim 2.
4. each instance of the worker service node is scaled to an established respective scaled instance of the worker service; 4. The scalable brokerless messaging network of claim 3.
5. the control service node is configured to distribute the messages to each of the individual scaled instances of the worker service nodes according to at least one routing rule defined by a service plane.
5. The scalable brokerless messaging network of claim 4.
6. the at least one routing rule provides a "zero trust" architecture and mutual Transport Layer Security (mTLS) encryption between each service node of the plurality of service nodes.
3. The scalable brokerless messaging network of claim 2.
7. at least one service forwarder pod in signal communication with the plurality of service nodes; the at least one service forwarder pod is configured to aggregate the messages to corresponding service nodes and distribute the messages according to load balancing rules defined by the control plane; 10. The scalable brokerless messaging network of claim 1.
8. the messaging middleware layer is implemented in a cloud computing environment; 10. The scalable brokerless messaging network of claim 1.
9. 1. A method for exchanging data in a scalable brokerless messaging network, comprising: Establishing signal communication between a service mesh including a plurality of service nodes to exchange a plurality of messages; establishing signaling communication between a control plane and the plurality of service nodes; Registering particular service nodes in the service mesh and application services associated with the control plane; defining a messaging middleware layer over the plurality of service nodes to establish a plurality of point-to-point connections between each service node in the service mesh via Transmission Control Protocol (TCP) sockets; A method comprising:
10. The method further comprises: encrypting, via a sidecar proxy included in at least one of the service nodes, an outgoing message generated by a host application process with a public key of a destination service node of the plurality of service nodes; decrypting an incoming message using a private key via the sidecar proxy included in at least one of the service nodes and delivering the decrypted incoming message to a destination application process; 10. The method of claim 9, comprising:
11. The method further comprises: establishing a first data connection between the application process and the sidecar proxy via the TCP socket included in each of the service nodes; establishing a second data connection between the application process and the sidecar proxy via a data socket, the second data connection being independent from the first data connection; The method of claim 10, comprising:
12. The method further comprises: operating at least one of the service nodes of the plurality of service nodes as a control service node; operating the remaining service nodes of the plurality of service nodes as worker service nodes; The method of claim 11 , comprising:
13. each instance of the worker service node is scaled to an established respective scaled instance of the worker service; The method of claim 12.
14. The method further comprises: Distributing the message to each of the individual scaled instances of the worker service nodes via the control service node according to at least one routing rule defined by a service plane; The method of claim 13, comprising:
15. The at least one routing rule provides a “zero trust” architecture and mutual Transport Layer Security (mTLS) encryption between each service node of the plurality of service nodes. The method of claim 10.
16. The method further comprises: establishing signal communication between at least one service forwarder pod and the plurality of service nodes; aggregating the plurality of messages to a corresponding service node via the at least one service forwarder pod; distributing the plurality of messages according to load balancing rules defined by the control plane; 10. The method of claim 9, comprising:
17. the messaging middleware layer is implemented in a cloud computing environment; 10. The method of claim 9.
18. A messaging middleware layer in a scalable brokerless messaging network, the messaging middleware layer comprising: a first application process included in a first service node and configured to operate according to said messaging middleware layer, the first application process being configured to exchange data with at least one second application process included in at least one second service node; the messaging middleware layer dynamically manages a Transmission Control Protocol (TCP) socket connection established between the first service node and the second service node; Messaging middleware layer.
19. the first application process detects a published message and delivers the message to the at least one second service node based on the TCP socket connection; The messaging middleware layer of claim 18.
20. the at least one second application process includes a plurality of second application processes, each second application process having a TCP socket connection with the first application process; the first service node generates a TCP list including each TCP socket connection corresponding to the second application processes, and delivers the message based on the TCP list; The messaging middleware layer of claim 19.
Citation Information
Patent Citations
Method for guaranteeing atomic properties of message processing, and device for the same
JP2002063146A
High-load business process scalability
JP2012230667A
Distributed Customer Premises Equipment
JP2019533340A
Application delivery agents on virtual desktop instances
US20160132214A1
Distributed customer premises equipment
US20170111274A1
