Repository navigation
RIPâ82 Implement Timer message, transaction message, and index based on RocksDB
- Current State: Shipped
- Authors: zk-drizzle ,zhouli11
- Shepherds: linhill
- Mailing List Discussion: dev@rocketmq.apache.org
- Pull Request: #PR_NUMBER
- Released: <released_version>
What do we need to do
- Will we add a new module?
No
- Will we add new APIs?
Yes.
- Will we add new feature?
Yes.
Are there any problems of our current project?
At present, the implementation of timer message, transaction message and Index based on the file version is complex. RocksDB's KV storage model is introduced to optimize the implementation of the above three modules, which can simplify the business logic, improve the maintainability of the code, and improve the stability of the system.
Chinese version:
çŽĺĺşäşćäťśççĺŽćśćśćŻăäşĺĄćśćŻăIndexçĺŽç°ä¸ç䝣ç éťčžĺŽç°čžä¸şĺ¤ćďźéčżĺźĺ ĽçRocksDBçKVĺĺ¨ć¨Ąĺç¨ćĽäźĺĺŽç°ä¸čż°çä¸ä¸Şć¨Ąĺďźĺ¨ä¸ĺŽç¨ĺşŚä¸çŽĺä¸ĺĄéťčžďźćĺ䝣ç ĺŻçť´ć¤ć§ďźćĺçłťçťç¨łĺŽć§ă
The code logic implementation of timer message, transaction message and Index was simplified, the code maintainability was improved, and the system stability was improved.
Chinese version:
çŽĺĺŽćśćśćŻăäşĺĄćśćŻăIndexç䝣ç éťčžĺŽç°ďźćĺ䝣ç ĺŻçť´ć¤ć§ďźćĺçłťçťç¨łĺŽć§ă
- What problem is this proposal designed to solve?
The KV storage structure model of RocksDB is used to optimize and implement the timer message, transaction message and Index moduleă
Chinese version:
ĺŠç¨RocksDBçKVĺĺ¨çťć樥ĺďźĺŻšĺŽćśćśćŻăäşĺĄćśćŻăIndex樥ĺçčżčĄäźĺä¸ĺŽç°ă
- To what degree should we solve the problem?
The KV storage structure of RocksDB is used to realize the original functions and add some new features
Chinese version:
ĺŠç¨RocksDBçKVĺĺ¨çťćčžĺĽ˝çĺŽç°ĺćĺč˝ĺšść°ĺ˘é¨ĺçšć§ă
- What problem is this proposal NOT designed to solve?
Nothing specific.
- Are there any limits of this proposal?
Nothing specific.
Add 3 new feature, the main content is implement of timer message ătransaction messageăIndex based on rocksdb.
1.Relying on the efficient characteristics of key-value storage, a timelix-driven mechanism is constructed to tile the timer message index, which reduces the repeated calculation and storage overhead in the process of message rolling.
2.The traditional dual queue matching model was replaced by the key-value read-write model, which accurately matched the transaction state, reduced the complexity of state checking, and made the code logic more concise and maintainability improved.
3.Based on the key-value model, it naturally adapts to the reading and writing of index data, retains the original function, and adds the pagination query ability, which further simplifies the implementation logic and enhances the maintainability.
Chinese version:
1.äžćéŽĺźĺĺ¨çéŤćçšć§ďźćĺťşćśé´č˝´éŠąĺ¨ćşĺśďźĺšłéşĺŽćśćśćŻç´˘ĺźďźĺĺ°ćśćŻćťĺ¨čżç¨ä¸çéĺ¤čŽĄçŽä¸ĺĺ¨ĺźéă
2.éčżéŽĺźčŻťĺ樥ĺĺäťŁäź çťĺéĺĺšé 樥ĺďźç˛žĺĺšé äşĺĄçśćďźéä˝çśććŁćĽçĺ¤ć庌ďźäťŁç éťčžć´çŽć´ä¸ĺŻçť´ć¤ć§ćĺă
3.ĺşäşéŽĺźć¨Ąĺ夊çśéé ç´˘ĺźć°ćŽčŻťĺďźäżçĺćĺč˝çĺćść°ĺ˘ĺ饾ćĽčŻ˘č˝ĺďźčżä¸ćĽçŽĺĺŽç°éťčžĺšśĺ˘ĺźşĺŻçť´ć¤ć§ă
- Method signature changes
Nothing specific.
- Method behavior changes
Nothing specific.
- CLI command changes
Nothing specific.
- Log format or content changes Nothing specific.
- Are backward and forward compatibility taken into consideration?
Fully compatible
- Are there deprecated APIs?
Nothing specific.
- How do we do migration?
Nothing specific.
We will implement the proposed changes by 1 phases.
- How does alternatives solve the issue you proposed?
Nothing specific.
- Pros and Cons of alternatives
Nothing specific.
Copyright Š 2016~2022 The Apache Software Foundation.
- Home
- RocketMQ Improvement Proposal
- User Guide
- Community