Details
-
Type:
Improvement
-
Status: Closed
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: None
-
Fix Version/s: 9.5
-
Component/s: Database, ElasticSearch, Plugin API, Rules
-
Labels:None
-
Edition:Community
-
Production Notes:None
Description
WHAT
SonarQube will be changed to support multiple description sections for a rule.
HOW
SonarQube
Database
- introduce new table rule_desc_sections, with columns UUID, RULE_UUID, KEY, FORMAT, DESCRIPTION
- introduce migration to move existing rules to new DB structure
- drop existing column description on rules table
Backend
- SonarQube should depend upon the newest version of sonar-plugin-api introduced by
PLUGINAPI-6 - When starting up - SonarQube should consume new API when possible to fill DB
- if old rule or rule not using (yet) the new API -> fallback to old Rule::htmlDescription
- Store information on the new DB structure
- Update ES indexing with all information (section concatenation)
- Adapt ExportRuleDto to handle new structure
- Merge sections when read from the web-API (preserve current behavior)
- Drop updated_at and created_at column for rule_metadata. rule <-> rule_metadata has a 1-1 cardinality, the updated_at are always the same. And rule_metadata.created_at is not used and is confusing in the code.
- Change on mybatis to better support the collections. The main guideline for usage of collections is explained here
Attachments
Issue Links
- is depended upon by
-
SONAR-16303 Display well-structured rule description on issues page
-
- Closed
-
- is related to
-
SONAR-16393 merge rule and rule_metadata tables
-
- Closed
-