Shared Memory Communication Driver for Database Latency
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Conventional database systems face performance and scalability issues due to TCP/IP contention and latency in two-tier deployments, especially on Non-Uniform Memory Access (NUMA) architectures, where multiple clients and database server instances share memory segments, leading to increased overhead and memory access latencies.
Innovation Solution
An Enhanced Shared Memory Based Communication Driver (ESMBCD) is introduced, which creates individual shared memory segments for each database server instance and dynamically allocates them as needed, using pre-configured communication endpoints like TCP/IP ports or IPC mechanisms, allowing clients and servers to communicate efficiently without relying solely on shared memory segments for all interactions.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Quantity of substance
If a single shared memory segment is used for multiple database server instances, then memory sharing is achieved, but memory access latency increases on NUMA architectures
Solution Approach 1:
The patent divides the single shared memory segment into multiple separate shared memory segments, with each database server instance having its own dedicated shared memory segment. This segmentation eliminates cross-NUMA-node memory access by allowing each instance to allocate memory locally on its NUMA node, thereby reducing memory access latency while maintaining memory sharing capabilities within each instance's segment.
Solution Approach 2:
The patent implements local quality by ensuring that each database server instance accesses memory that is locally allocated on its own NUMA node. This creates a localized memory access pattern where each instance has preferential access to its local memory resources, improving memory access speed and reducing latency compared to accessing remote memory on other NUMA nodes.
2Adaptability or versatility
If TCP/IP protocol is used for communication between clients and database server instances, then communication flexibility is achieved, but overhead and contention increase
Solution Approach 1:
The patent introduces shared memory segments as an intermediary communication mechanism between clients and database server instances. Instead of direct TCP/IP communication, clients and instances use the shared memory segment as a mediator for data exchange. This intermediary approach eliminates TCP/IP protocol overhead and contention while maintaining communication flexibility through the standardized shared memory interface.
3Reliability
If separate TCP/IP ports are used for every database server instance, then TCP/IP contention is reduced, but system complexity and resource consumption increase
Solution Approach 1:
The patent extracts the communication mechanism from TCP/IP protocol and implements it using shared memory segments. By taking out the communication function from the network protocol layer and placing it in the memory layer, the system eliminates the need for separate TCP/IP ports for each instance, thereby reducing system complexity and resource consumption while maintaining the benefit of reduced contention through isolated communication channels.
4Productivity
If IPC mechanism is used for communication with every database server instance, then TCP/IP overhead is reduced, but scalability and performance are insufficient
Solution Approach 1:
The patent implements a dynamic communication mechanism using shared memory segments that can adapt to different communication scenarios. The shared memory segments are dynamically allocated and configured based on the specific needs of each database server instance, allowing the system to scale efficiently. This dynamic approach provides both the communication efficiency of IPC mechanisms and the scalability needed for growing systems, overcoming the limitations of conventional IPC implementations.
Data Source
AI summary
Enhanced shared memory based communication driver for improved performance and scalability is described. An example method includes creating a shared memory segment for a database server instance. The database server instance and a client reside on a same computing device. A first database connection is established to the database server instance using a pre-configured communication end point. An identifier of the shared memory segment for the database server instance is sent to the database server instance and the database server instance listens to subsequent connection requests generated on the shared memory segment. Moreover, a second database connection to the database server instance is established using the shared memory segment as a communication end point. Upon a successful connection of the second database connection, the first database connection is closed.


