@@ -697,12 +697,26 @@ func (s *Storage) UpdateRuleCategoryRels(rule *Rule) error {
697697 return err
698698}
699699
700+ // TODO : 避免直接用规则名称映射
700701var ruleNameToPerformanceCostId = map [string ] /*ruleId*/ string /*auditPerformanceLevelCategorieID*/ {
702+ // old rule: MySQL
701703 rule .DMLCheckSelectRows : plocale .RuleTagPerformanceCostHigh .ID ,
702704 rule .DMLCheckAffectedRows : plocale .RuleTagPerformanceCostHigh .ID ,
703705 rule .ConfigOptimizeIndexEnabled : plocale .RuleTagPerformanceCostHigh .ID ,
704706 rule .DDLCheckIndexOption : plocale .RuleTagPerformanceCostHigh .ID ,
705707 rule .DDLCheckCompositeIndexDistinction : plocale .RuleTagPerformanceCostHigh .ID ,
708+
709+ // new rule: Oracle
710+ "Oracle_011" : plocale .RuleTagPerformanceCostHigh .ID ,
711+ "Oracle_012" : plocale .RuleTagPerformanceCostHigh .ID ,
712+ "Oracle_017" : plocale .RuleTagPerformanceCostHigh .ID ,
713+ "Oracle_019" : plocale .RuleTagPerformanceCostHigh .ID ,
714+ "Oracle_044" : plocale .RuleTagPerformanceCostHigh .ID ,
715+ "Oracle_046" : plocale .RuleTagPerformanceCostHigh .ID ,
716+ "Oracle_050" : plocale .RuleTagPerformanceCostHigh .ID ,
717+ "Oracle_077" : plocale .RuleTagPerformanceCostHigh .ID ,
718+ "Oracle_078" : plocale .RuleTagPerformanceCostHigh .ID ,
719+ "Oracle_080" : plocale .RuleTagPerformanceCostHigh .ID ,
706720}
707721
708722func (s * Storage ) GetDefaultRuleTemplateName (dbType string ) string {
0 commit comments