Message Queue Plug-in Interface for Kernel Stability
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Message queue systems, such as RocketMQ, face challenges in meeting personalized demands without modifying kernel code, which can destabilize the system.
Innovation Solution
The method involves reserving interfaces before and after processing components in a message queue system, allowing for the development and deployment of plug-ins that implement specific functions without altering the kernel code, enabling customization and updates while maintaining system stability.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Adaptability or versatility
If kernel code is modified to meet personalized demands, then system adaptability is improved, but system stability deteriorates
Solution Approach 1:
The system is segmented into kernel code and plug-in modules. The kernel code remains unchanged and stable, while personalized functions are implemented in separate plug-in files that can be independently developed, deployed, and updated without affecting the core system stability.
Solution Approach 2:
A plug-in management mechanism acts as an intermediary between the kernel code and personalized requirements. The reserved interfaces serve as mediators that allow external plug-ins to interact with the kernel code without directly modifying it, thus maintaining system stability while enabling adaptability.
2Adaptability or versatility
If kernel code is modified to implement custom functions, then system versatility is improved, but system complexity increases
Solution Approach 1:
Custom functions are segmented into independent plug-in files rather than being integrated into the kernel code. Each plug-in is a self-contained module that can be developed, tested, and maintained separately, reducing the complexity of the overall system while maintaining versatility.
Solution Approach 2:
The plug-in architecture provides a universal framework that can accommodate multiple different custom functions through standardized interfaces. Instead of creating separate code paths for each custom function in the kernel, a single plug-in mechanism handles diverse requirements, simplifying the system structure.
3Adaptability or versatility
If reserved interfaces are added to processing components, then system flexibility is improved, but device complexity increases
Solution Approach 1:
Reserved interfaces are designed as universal standards that work across different processing components. The same interface pattern can be applied to multiple components (message storage, transaction processing, client processing), providing flexibility without requiring custom integration logic for each component, thus limiting the increase in complexity.
Data Source
AI summary
Embodiments of the present application provide a development method, a control method and a computing device. A node of a message queue system reserves an interface before and/or after a processing component that performs any processing operation is called, determines a plug-in file obtained from development of a plug-in based on a reserved interface, and deploys the plug-in file to a designated storage location in the node. The node detects a trigger event for any processing component. If an interface is reserved before the processing component is called, a first plug-in corresponding to the interface is called; the processing component is called according to an execution result of the first plug-in, to process the trigger event; and after an execution of the processing component is completed, if an interface is reserved after the processing component is called, a second plug-in corresponding to the interface is called.


