diff options
author | Simon Brandhof <simon.brandhof@sonarsource.com> | 2016-02-29 15:02:45 +0100 |
---|---|---|
committer | Simon Brandhof <simon.brandhof@sonarsource.com> | 2016-02-29 15:02:45 +0100 |
commit | 076bed2e34e4ddac3ff1a071432cf1c6d9ccbfe2 (patch) | |
tree | ef70389e87a6ea3912530107913033ec2d4383f5 /sonar-db | |
parent | 7e1bd1a88c7b36d2dd7a678423705d2efddb5d83 (diff) | |
download | sonarqube-076bed2e34e4ddac3ff1a071432cf1c6d9ccbfe2.tar.gz sonarqube-076bed2e34e4ddac3ff1a071432cf1c6d9ccbfe2.zip |
Fix quality flaws
Diffstat (limited to 'sonar-db')
3 files changed, 0 insertions, 20 deletions
diff --git a/sonar-db/src/main/java/org/sonar/db/DbSession.java b/sonar-db/src/main/java/org/sonar/db/DbSession.java index 845dc679c64..be3ec9a741f 100644 --- a/sonar-db/src/main/java/org/sonar/db/DbSession.java +++ b/sonar-db/src/main/java/org/sonar/db/DbSession.java @@ -31,10 +31,8 @@ import org.apache.ibatis.session.SqlSession; public class DbSession implements SqlSession { private SqlSession session; - private int actionCount; public DbSession(SqlSession session) { - this.actionCount = 0; this.session = session; } diff --git a/sonar-db/src/main/java/org/sonar/db/qualityprofile/ActiveRuleDto.java b/sonar-db/src/main/java/org/sonar/db/qualityprofile/ActiveRuleDto.java index 2b4613889bb..53d14c1957d 100644 --- a/sonar-db/src/main/java/org/sonar/db/qualityprofile/ActiveRuleDto.java +++ b/sonar-db/src/main/java/org/sonar/db/qualityprofile/ActiveRuleDto.java @@ -45,14 +45,10 @@ public class ActiveRuleDto { private long updatedAt; // These fields do not exists in db, it's only retrieve by joins - private Integer parentId; private String repository; private String ruleField; private String profileKey; - /** - * @deprecated for internal use, should be private - */ public ActiveRuleDto setKey(ActiveRuleKey key) { this.repository = key.ruleKey().repository(); this.ruleField = key.ruleKey().rule(); @@ -119,18 +115,6 @@ public class ActiveRuleDto { return this; } - @CheckForNull - @Deprecated - public Integer getParentId() { - return parentId; - } - - @Deprecated - public ActiveRuleDto setParentId(@Nullable Integer parentId) { - this.parentId = parentId; - return this; - } - public boolean isInherited() { return StringUtils.equals(INHERITED, inheritance); } diff --git a/sonar-db/src/main/resources/org/sonar/db/qualityprofile/ActiveRuleMapper.xml b/sonar-db/src/main/resources/org/sonar/db/qualityprofile/ActiveRuleMapper.xml index d8b0a1ab0ae..6951207cdc1 100644 --- a/sonar-db/src/main/resources/org/sonar/db/qualityprofile/ActiveRuleMapper.xml +++ b/sonar-db/src/main/resources/org/sonar/db/qualityprofile/ActiveRuleMapper.xml @@ -28,7 +28,6 @@ a.rule_id as ruleId, a.failure_level as severity, a.inheritance as inheritance, - active_rule_parent.id as parentId, a.created_at as "createdAt", a.updated_at as "updatedAt" </sql> @@ -37,7 +36,6 @@ <sql id="activeRuleJoin"> INNER JOIN rules_profiles qp ON qp.id=a.profile_id LEFT JOIN rules_profiles profile_parent ON profile_parent.kee=qp.parent_kee - LEFT JOIN active_rules active_rule_parent ON active_rule_parent.profile_id=profile_parent.id AND a.rule_id=active_rule_parent.rule_id </sql> <select id="selectAfterDate" parameterType="Date" resultType="ActiveRule" |