A database-based semantic distributed lock implementation method and system

CN121958406BActive Publication Date: 2026-06-09HIGHGO SOFTWARE
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
HIGHGO SOFTWARE
Filing Date
2026-04-01
Publication Date
2026-06-09

AI Technical Summary

Technical Problem

Existing distributed lock solutions cannot provide the PostgreSQL ecosystem with enterprise-level distributed lock capabilities such as semantic naming, automatic timeout release mechanism, automatic recycling, and lock mode conversion without introducing third-party middleware. This results in high system architecture complexity, high resource consumption, low concurrency performance, and high risk of deadlock.

Method used

Create a lock metadata table in the PostgreSQL database, encapsulate the kernel lock request and release functions into C function interfaces, build a lock mode conversion interface, and configure a timeout timer to implement the mapping of semantic lock names to kernel unique identifiers, supporting multi-granularity lock mode conversion and automatic reclamation of lock resources.

Benefits of technology

It reduces system architecture complexity and resource consumption, improves system stability and observability, eliminates deadlock risk, and ensures strong consistency of distributed transactions and business logic continuity in high-concurrency scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121958406B_ABST
    Figure CN121958406B_ABST
Patent Text Reader

Abstract

The application discloses a kind of based on database's semantic distributed lock implementation method and system, belong to database kernel extension technical field, for solving the technical problem that current distributed lock scheme cannot provide more comprehensive efficient distributed lock processing capacity for PostgreSQL ecosystem under the premise of not introducing third party middleware.The method comprises the following steps: creating lock metadata table in PostgreSQL database;Develop C extension module, and encapsulate request lock function and release lock function in PostgreSQL kernel as C function interface;According to lock metadata table, construct the parameters of request lock function and release lock function;Build lock mode conversion interface, and configure lock mode conversion rule in lock mode conversion interface, to realize the conversion of original lock mode and new lock mode;For the request lock interface and lock mode conversion interface of PostgreSQL database, configure timeout timer, and set the maximum waiting time of timeout timer.
Need to check novelty before this filing date? Find Prior Art

Citation Information

Patent Citations

  • Method for realizing safety distributed lock through Redis

    CN115562857A

  • Distributed lock processing method, device and system, storage medium and program product

    CN120723490A