]> source.dussan.org Git - sonarqube.git/commitdiff
SONAR-2706 add Review#getRuleKey() and getRuleRepository() and remove methods that...
authorSimon Brandhof <simon.brandhof@gmail.com>
Fri, 25 May 2012 13:50:43 +0000 (15:50 +0200)
committerSimon Brandhof <simon.brandhof@gmail.com>
Fri, 25 May 2012 13:50:43 +0000 (15:50 +0200)
19 files changed:
sonar-core/src/main/java/org/sonar/core/review/workflow/ReviewDatabaseStore.java
sonar-core/src/main/java/org/sonar/core/review/workflow/ReviewStore.java
sonar-core/src/main/java/org/sonar/core/review/workflow/WorkflowEngine.java
sonar-core/src/main/java/org/sonar/core/review/workflow/condition/HasReviewPropertyCondition.java
sonar-core/src/main/java/org/sonar/core/review/workflow/function/TransitionFunction.java [deleted file]
sonar-core/src/main/java/org/sonar/core/review/workflow/review/Comment.java
sonar-core/src/main/java/org/sonar/core/review/workflow/review/DefaultReview.java
sonar-core/src/main/java/org/sonar/core/review/workflow/review/ImmutableReview.java
sonar-core/src/main/java/org/sonar/core/review/workflow/review/MutableReview.java
sonar-core/src/main/java/org/sonar/core/review/workflow/review/Review.java
sonar-core/src/test/java/org/sonar/core/review/workflow/ReviewDatabaseStoreTest.java
sonar-core/src/test/java/org/sonar/core/review/workflow/WorkflowEngineTest.java
sonar-core/src/test/java/org/sonar/core/review/workflow/WorkflowTest.java
sonar-core/src/test/java/org/sonar/core/review/workflow/condition/ResolutionConditionTest.java
sonar-core/src/test/java/org/sonar/core/review/workflow/condition/StatusConditionTest.java
sonar-core/src/test/resources/org/sonar/core/review/workflow/ReviewDatabaseStoreTest/store-result.xml
sonar-core/src/test/resources/org/sonar/core/review/workflow/ReviewDatabaseStoreTest/store.xml
sonar-server/src/main/java/org/sonar/server/ui/JRubyFacade.java
sonar-server/src/main/webapp/WEB-INF/app/models/rule_failure.rb

index a9a3646ff8cfe1f45fb1931ee20a64599b0475a1..b48ea94bf5f2fd13991cde25ff476369ea5210c0 100644 (file)
@@ -34,6 +34,7 @@ import org.sonar.core.review.ReviewCommentMapper;
 import org.sonar.core.review.ReviewDto;
 import org.sonar.core.review.ReviewMapper;
 import org.sonar.core.review.workflow.review.Comment;
+import org.sonar.core.review.workflow.review.DefaultReview;
 import org.sonar.core.review.workflow.review.MutableReview;
 
 import java.util.Date;
@@ -48,12 +49,12 @@ public class ReviewDatabaseStore implements ReviewStore, ServerComponent {
     this.mybatis = mb;
   }
 
-  public void store(MutableReview review) {
+  public void store(DefaultReview review) {
     store(review, new Date());
   }
 
   @VisibleForTesting
-  void store(MutableReview review, Date now) {
+  void store(DefaultReview review, Date now) {
     if (review.getReviewId() == null) {
       LOG.error("Review has no id. Violation id is: " + review.getViolationId());
       return;
@@ -66,7 +67,6 @@ public class ReviewDatabaseStore implements ReviewStore, ServerComponent {
       ReviewDto dto = mapper.findById(review.getReviewId());
       dto.setResolution(review.getResolution());
       dto.setStatus(review.getStatus());
-      dto.setAssigneeId(review.getAssigneeId());
       dto.setData(KeyValueFormat.format(review.getProperties()));
       dto.setUpdatedAt(now);
       mapper.update(dto);
index 708d78249d364b2f6aef2212474f486b131804ef..22a298e1ed1fcc9b307095168458996682126ada 100644 (file)
 package org.sonar.core.review.workflow;
 
 import org.sonar.api.config.Settings;
+import org.sonar.core.review.workflow.review.DefaultReview;
 import org.sonar.core.review.workflow.review.MutableReview;
 
 import java.util.List;
 
 public interface ReviewStore {
-  void store(MutableReview review);
+  void store(DefaultReview review);
 
   void completeProjectSettings(Long projectId, Settings settings, List<String> propertyKeys);
 }
index 08261723eedf1c8e5018f510b7b2608778a78132..22e821cf5080a7da66b048d1901ec82d68f11eca 100644 (file)
@@ -56,7 +56,7 @@ public class WorkflowEngine implements ServerComponent {
   /**
    * @return non-null list of screens per review#violationId
    */
-  public ListMultimap<Long, Screen> listAvailableScreens(Review[] reviews, DefaultWorkflowContext context, boolean verifyConditions) {
+  public ListMultimap<Long, Screen> listAvailableScreens(DefaultReview[] reviews, DefaultWorkflowContext context, boolean verifyConditions) {
     ListMultimap<Long, Screen> result = ArrayListMultimap.create();
 
     completeProjectSettings(context);
@@ -64,7 +64,7 @@ public class WorkflowEngine implements ServerComponent {
     for (Map.Entry<String, Screen> entry : workflow.getScreensByCommand().entrySet()) {
       String commandKey = entry.getKey();
       if (!verifyConditions || verifyConditionsQuietly(null, context, workflow.getContextConditions(commandKey))) {
-        for (Review review : reviews) {
+        for (DefaultReview review : reviews) {
           if (!verifyConditions || verifyConditionsQuietly(review, context, workflow.getReviewConditions(commandKey))) {
             result.put(review.getViolationId(), entry.getValue());
           }
@@ -94,7 +94,7 @@ public class WorkflowEngine implements ServerComponent {
     return workflow.getScreen(commandKey);
   }
 
-  public void execute(String commandKey, MutableReview review, DefaultWorkflowContext context, Map<String, String> parameters) {
+  public void execute(String commandKey, DefaultReview review, DefaultWorkflowContext context, Map<String, String> parameters) {
     Preconditions.checkArgument(!Strings.isNullOrEmpty(commandKey), "Missing command");
     Preconditions.checkArgument(workflow.hasCommand(commandKey), "Unknown command: " + commandKey);
 
index f1870634adae12805354b3a88a947b3982be50de..a9922a98b9daa4818674ca70fcf9bb56b9bef5e7 100644 (file)
@@ -25,6 +25,8 @@ import com.google.common.base.Strings;
 import org.sonar.core.review.workflow.review.Review;
 import org.sonar.core.review.workflow.review.WorkflowContext;
 
+import javax.annotation.Nullable;
+
 /**
  * @since 3.1
  */
@@ -44,7 +46,7 @@ public final class HasReviewPropertyCondition extends Condition {
   }
 
   @Override
-  public boolean doVerify(Review review, WorkflowContext context) {
-    return !Strings.isNullOrEmpty(review.getProperties().get(propertyKey));
+  public boolean doVerify(@Nullable Review review, WorkflowContext context) {
+    return review != null && !Strings.isNullOrEmpty(review.getProperties().get(propertyKey));
   }
 }
diff --git a/sonar-core/src/main/java/org/sonar/core/review/workflow/function/TransitionFunction.java b/sonar-core/src/main/java/org/sonar/core/review/workflow/function/TransitionFunction.java
deleted file mode 100644 (file)
index 2c09374..0000000
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * Sonar, open source software quality management tool.
- * Copyright (C) 2008-2012 SonarSource
- * mailto:contact AT sonarsource DOT com
- *
- * Sonar is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 3 of the License, or (at your option) any later version.
- *
- * Sonar is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with Sonar; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02
- */
-package org.sonar.core.review.workflow.function;
-
-import com.google.common.base.Preconditions;
-import com.google.common.base.Strings;
-import org.sonar.core.review.workflow.review.MutableReview;
-import org.sonar.core.review.workflow.review.Review;
-import org.sonar.core.review.workflow.review.WorkflowContext;
-
-import javax.annotation.Nullable;
-import java.util.Map;
-
-public final class TransitionFunction extends Function {
-
-  private final String targetStatus;
-  private final String targetResolution;
-
-  public TransitionFunction(String targetStatus, @Nullable String targetResolution) {
-    Preconditions.checkArgument(!Strings.isNullOrEmpty(targetStatus), "Empty target status");
-    this.targetStatus = targetStatus;
-    this.targetResolution = targetResolution;
-  }
-
-  @Override
-  public void doExecute(MutableReview review, Review initialReview, WorkflowContext context, Map<String, String> parameters) {
-    review.setStatus(targetStatus);
-    review.setResolution(targetResolution);
-  }
-}
index a3a332eb5a5775c55e8e14a73fa219e91d03ae3e..250e761593fa046c8f154dd5c5d6c9d5eacacfc3 100644 (file)
@@ -22,7 +22,7 @@ package org.sonar.core.review.workflow.review;
 import org.apache.commons.lang.builder.ReflectionToStringBuilder;
 import org.apache.commons.lang.builder.ToStringStyle;
 
-public class Comment implements Cloneable {
+public final class Comment implements Cloneable {
   private String markdownText;
   private Long userId;
 
index 55adaa16a148acc0955de4ebf878bfda85967828..51a52790000a7ffd2d4cc6b3650df3ea4fd6024e 100644 (file)
@@ -37,8 +37,8 @@ public final class DefaultReview implements MutableReview {
 
   private Long violationId;
   private Long reviewId;
-  private Long ruleId;
-  private Long assigneeId;
+  private String ruleRepositoryKey;
+  private String ruleKey;
   private Long line;
   private boolean switchedOff = false;
   private boolean manual = false;
@@ -67,12 +67,21 @@ public final class DefaultReview implements MutableReview {
     return this;
   }
 
-  public Long getRuleId() {
-    return ruleId;
+  public String getRuleRepositoryKey() {
+    return ruleRepositoryKey;
   }
 
-  public DefaultReview setRuleId(Long ruleId) {
-    this.ruleId = ruleId;
+  public DefaultReview setRuleRepositoryKey(String s) {
+    this.ruleRepositoryKey = s;
+    return this;
+  }
+
+  public String getRuleKey() {
+    return ruleKey;
+  }
+
+  public DefaultReview setRuleKey(String s) {
+    this.ruleKey = s;
     return this;
   }
 
@@ -112,15 +121,6 @@ public final class DefaultReview implements MutableReview {
     return this;
   }
 
-  public Long getAssigneeId() {
-    return assigneeId;
-  }
-
-  public DefaultReview setAssigneeId(Long l) {
-    this.assigneeId = l;
-    return this;
-  }
-
   public String getStatus() {
     return status;
   }
@@ -202,14 +202,14 @@ public final class DefaultReview implements MutableReview {
    */
   public ImmutableReview cloneImmutable() {
     ImmutableReview clone = new ImmutableReview();
-    clone.setAssigneeId(assigneeId);
     clone.setLine(line);
     clone.setManual(manual);
     clone.setMessage(message);
     clone.setProperties(ImmutableMap.copyOf(getProperties()));
     clone.setResolution(resolution);
     clone.setReviewId(reviewId);
-    clone.setRuleId(ruleId);
+    clone.setRuleKey(ruleKey);
+    clone.setRuleRepositoryKey(ruleRepositoryKey);
     clone.setSeverity(severity);
     clone.setStatus(status);
     clone.setSwitchedOff(switchedOff);
index 94a6941e87ad5733fae7267c384577080f80fa19..1f3b7e9e0224f3446720079acf9fb81349fba3d3 100644 (file)
@@ -25,7 +25,8 @@ public class ImmutableReview implements Review {
   private Long violationId;
   private Long reviewId;
   private Long ruleId;
-  private Long assigneeId;
+  private String ruleRepositoryKey;
+  private String ruleKey;
   private Long line;
   private boolean switchedOff = false;
   private boolean manual = false;
@@ -59,12 +60,20 @@ public class ImmutableReview implements Review {
     this.ruleId = ruleId;
   }
 
-  public Long getAssigneeId() {
-    return assigneeId;
+  public String getRuleRepositoryKey() {
+    return ruleRepositoryKey;
   }
 
-  void setAssigneeId(Long assigneeId) {
-    this.assigneeId = assigneeId;
+  void setRuleRepositoryKey(String ruleRepositoryKey) {
+    this.ruleRepositoryKey = ruleRepositoryKey;
+  }
+
+  public String getRuleKey() {
+    return ruleKey;
+  }
+
+  void setRuleKey(String ruleKey) {
+    this.ruleKey = ruleKey;
   }
 
   public Long getLine() {
index 420583b0cef13a9fe0e439d30761f06b63405871..286254dcdb8fe5d247eaac9fcdbf85e751058e69 100644 (file)
@@ -24,8 +24,6 @@ import java.util.List;
 
 public interface MutableReview extends Review {
 
-  MutableReview setAssigneeId(Long assigneeId);
-
   MutableReview setStatus(String s);
 
   MutableReview setResolution(@Nullable String resolution);
index f40b88d80f15fba12496c959443d363964ce4978..95c8e28080a48c2597b561e47c7c40152b002358 100644 (file)
@@ -23,13 +23,9 @@ import java.util.Map;
 
 public interface Review {
 
-  Long getViolationId();
+  String getRuleRepositoryKey();
 
-  Long getReviewId();
-
-  Long getRuleId();
-
-  Long getAssigneeId();
+  String getRuleKey();
 
   boolean isSwitchedOff();
 
index d1e548c43f28ada8143d2f01332709b1154bb22c..99eae6f733057a014d5da911c0ba74e0078d92a4 100644 (file)
@@ -34,8 +34,7 @@ public class ReviewDatabaseStoreTest extends DaoTestCase {
   public void store() {
     setupData("store");
     ReviewDatabaseStore store = new ReviewDatabaseStore(getMyBatis());
-    MutableReview review = new DefaultReview().setReviewId(1234L);
-    review.setAssigneeId(33L);
+    DefaultReview review = new DefaultReview().setReviewId(1234L);
     review.setStatus("CLOSED");
     review.setResolution("RESOLVED");
     review.setProperty("who", "me");
index 6e8c1950f255854c0181090e0a1f6394306c0cf5..29f86a9b1be7e22834bce66472efe3741962e3ae 100644 (file)
@@ -86,7 +86,7 @@ public class WorkflowEngineTest {
   public void listAvailableScreensForReviews_empty() {
     WorkflowEngine engine = new WorkflowEngine(new Workflow(), mock(ReviewStore.class), new Settings());
     ListMultimap<Long, Screen> screens = engine.listAvailableScreens(
-        new Review[]{new DefaultReview().setViolationId(1000L), new DefaultReview().setViolationId(2000L)},
+        new DefaultReview[]{new DefaultReview().setViolationId(1000L), new DefaultReview().setViolationId(2000L)},
         new DefaultWorkflowContext(), true);
     assertThat(screens.size()).isEqualTo(0);
   }
@@ -100,7 +100,7 @@ public class WorkflowEngineTest {
     workflow.setScreen("resolve", screen);
     WorkflowEngine engine = new WorkflowEngine(workflow, mock(ReviewStore.class), new Settings());
     ListMultimap<Long, Screen> screens = engine.listAvailableScreens(
-        new Review[]{new DefaultReview().setViolationId(1000L), new DefaultReview().setViolationId(2000L)},
+        new DefaultReview[]{new DefaultReview().setViolationId(1000L), new DefaultReview().setViolationId(2000L)},
         new DefaultWorkflowContext(), true);
     assertThat(screens.size()).isEqualTo(2);
     assertThat(screens.get(1000L)).containsExactly(screen);
@@ -117,7 +117,7 @@ public class WorkflowEngineTest {
     WorkflowEngine engine = new WorkflowEngine(workflow, store, new Settings());
 
     engine.listAvailableScreens(
-        new Review[]{new DefaultReview().setViolationId(1000L), new DefaultReview().setViolationId(2000L)},
+        new DefaultReview[]{new DefaultReview().setViolationId(1000L), new DefaultReview().setViolationId(2000L)},
         new DefaultWorkflowContext().setProjectId(300L),
         true);
 
@@ -137,7 +137,7 @@ public class WorkflowEngineTest {
     settings.setProperty("foo", "bar");
     WorkflowEngine engine = new WorkflowEngine(workflow, store, settings);
 
-    MutableReview review = new DefaultReview().setViolationId(1000L);
+    DefaultReview review = new DefaultReview().setViolationId(1000L);
     Map<String, String> parameters = Maps.newHashMap();
     DefaultWorkflowContext context = new DefaultWorkflowContext().setProjectId(300L);
 
@@ -162,7 +162,7 @@ public class WorkflowEngineTest {
     Settings settings = new Settings();// missing property 'foo'
     WorkflowEngine engine = new WorkflowEngine(workflow, store, settings);
 
-    MutableReview review = new DefaultReview().setViolationId(1000L);
+    DefaultReview review = new DefaultReview().setViolationId(1000L);
     Map<String, String> parameters = Maps.newHashMap();
     DefaultWorkflowContext context = new DefaultWorkflowContext().setProjectId(300L);
 
index e4e7dc402059b732bfdf01db64a666a5912a3632..00502cd6148fee73c2b98e5bd6493dbe442bd4dc 100644 (file)
@@ -26,7 +26,8 @@ import org.junit.rules.ExpectedException;
 import org.sonar.core.review.workflow.condition.Condition;
 import org.sonar.core.review.workflow.condition.HasProjectPropertyCondition;
 import org.sonar.core.review.workflow.condition.StatusCondition;
-import org.sonar.core.review.workflow.function.TransitionFunction;
+import org.sonar.core.review.workflow.function.CommentFunction;
+import org.sonar.core.review.workflow.function.Function;
 import org.sonar.core.review.workflow.screen.CommentScreen;
 
 import static org.fest.assertions.Assertions.assertThat;
@@ -127,7 +128,7 @@ public class WorkflowTest {
     Workflow workflow = new Workflow();
     workflow.addCommand("resolve");
 
-    TransitionFunction function = new TransitionFunction("OPEN", "resolved");
+    Function function = new CommentFunction();
     workflow.addFunction("resolve", function);
 
     assertThat(workflow.getFunctions("resolve")).containsExactly(function);
@@ -145,7 +146,7 @@ public class WorkflowTest {
     thrown.expectMessage("Unknown command: resolve");
 
     Workflow workflow = new Workflow();
-    workflow.addFunction("resolve", new TransitionFunction("OPEN", "resolved"));
+    workflow.addFunction("resolve", new CommentFunction());
   }
 
   @Test
index 0967df59d78298986594f37ab841f2a3bd73af2e..caa79784e3c1c5d6a610e9ca01126ddf2be0d6bc 100644 (file)
@@ -19,7 +19,9 @@
  */
 package org.sonar.core.review.workflow.condition;
 
+import org.junit.Rule;
 import org.junit.Test;
+import org.junit.rules.ExpectedException;
 import org.sonar.core.review.workflow.review.DefaultReview;
 import org.sonar.core.review.workflow.review.DefaultWorkflowContext;
 import org.sonar.core.review.workflow.review.Review;
@@ -27,6 +29,16 @@ import org.sonar.core.review.workflow.review.Review;
 import static org.fest.assertions.Assertions.assertThat;
 
 public class ResolutionConditionTest {
+
+  @Rule
+  public ExpectedException thrown = ExpectedException.none();
+
+  @Test
+  public void failIfNoResolution() {
+    thrown.expect(IllegalArgumentException.class);
+    new ResolutionCondition();
+  }
+
   @Test
   public void getResolutions() {
     ResolutionCondition condition = new ResolutionCondition("", "RESOLVED");
index 80e2023f9676a8dcce933b861085ddffc81858d9..46c2a2c5ed54dcf71e33e996d2ed23e61598a517 100644 (file)
@@ -19,7 +19,9 @@
  */
 package org.sonar.core.review.workflow.condition;
 
+import org.junit.Rule;
 import org.junit.Test;
+import org.junit.rules.ExpectedException;
 import org.sonar.core.review.workflow.review.DefaultReview;
 import org.sonar.core.review.workflow.review.DefaultWorkflowContext;
 import org.sonar.core.review.workflow.review.Review;
@@ -27,6 +29,17 @@ import org.sonar.core.review.workflow.review.Review;
 import static org.fest.assertions.Assertions.assertThat;
 
 public class StatusConditionTest {
+
+  @Rule
+  public ExpectedException thrown = ExpectedException.none();
+
+  @Test
+  public void failIfNoStatus() {
+    thrown.expect(IllegalArgumentException.class);
+    new StatusCondition();
+  }
+
+
   @Test
   public void getStatuses() {
     StatusCondition condition = new StatusCondition("OPEN", "CLOSED");
index 6b344b546ae5273084562f589af9b926ed440f97..a389f7ff88c898a268c8d308dfa894fe144b6bae 100644 (file)
@@ -9,6 +9,7 @@
     resource_line="200"
     severity="BLOCKER"
     user_id="300"
+    assignee_id="33"
     resource_id="400"
     rule_id="500"
     manual_violation="[true]"
@@ -17,7 +18,6 @@
     updated_at="2012-05-18"
     status="CLOSED"
     resolution="RESOLVED"
-    assignee_id="33"
     data="who=me;why=because"
     />
 
index edc3d7f31affd254c284714f1d80493eb417356c..8de7eda9f7c366ac53494514412c3a3037facf48 100644 (file)
@@ -9,6 +9,7 @@
     resource_line="200"
     severity="BLOCKER"
     user_id="300"
+    assignee_id="33"
     resource_id="400"
     rule_id="500"
     manual_violation="[true]"
@@ -17,7 +18,6 @@
     updated_at="[null]"
     status="OPEN"
     resolution="[null]"
-    assignee_id="[null]"
     data="[null]"
    />
 
index b51f00db2077a1b254f03d1d622cbf758d94192b..d5c066d557674c90f7cd16656a67f7c440c93a8b 100644 (file)
@@ -44,6 +44,7 @@ import org.sonar.core.persistence.DatabaseMigrator;
 import org.sonar.core.purge.PurgeDao;
 import org.sonar.core.resource.ResourceIndexerDao;
 import org.sonar.core.review.workflow.WorkflowEngine;
+import org.sonar.core.review.workflow.review.DefaultReview;
 import org.sonar.core.review.workflow.review.DefaultWorkflowContext;
 import org.sonar.core.review.workflow.review.MutableReview;
 import org.sonar.core.review.workflow.review.Review;
@@ -478,7 +479,7 @@ public final class JRubyFacade {
     return getContainer().getComponentByType(WorkflowEngine.class).listAvailableScreens(review, context, true);
   }
 
-  public ListMultimap<Long, Screen> listAvailableReviewsScreens(Review[] reviews, DefaultWorkflowContext context) {
+  public ListMultimap<Long, Screen> listAvailableReviewsScreens(DefaultReview[] reviews, DefaultWorkflowContext context) {
     return getContainer().getComponentByType(WorkflowEngine.class).listAvailableScreens(reviews, context, true);
   }
 
@@ -486,7 +487,7 @@ public final class JRubyFacade {
     return getContainer().getComponentByType(WorkflowEngine.class).getScreen(commandKey);
   }
 
-  public void executeReviewCommand(String commandKey, MutableReview review, DefaultWorkflowContext context, Map<String, String> parameters) {
+  public void executeReviewCommand(String commandKey, DefaultReview review, DefaultWorkflowContext context, Map<String, String> parameters) {
     getContainer().getComponentByType(WorkflowEngine.class).execute(commandKey, review, context, parameters);
   }
 }
index 421c2e6ef9bdb7175498bdde25d47144fe9eac60..5121cd144c12171e8fb77d6eb05bd01ed62b3b10 100644 (file)
@@ -278,7 +278,8 @@ class RuleFailure < ActiveRecord::Base
     java_review=Java::OrgSonarCoreReviewWorkflowReview::DefaultReview.new
     java_review.setViolationId(violation.id)
     java_review.setSeverity(violation.severity.to_s)
-    java_review.setRuleId(violation.rule_id)
+    java_review.setRuleKey(violation.rule.plugin_rule_key)
+    java_review.setRuleRepositoryKey(violation.rule.repository_key)
     java_review.setSwitchedOff(violation.switched_off||false)
     java_review.setMessage(violation.message)
     java_review.setLine(violation.line)
@@ -288,7 +289,6 @@ class RuleFailure < ActiveRecord::Base
       java_review.setReviewId(review.id)
       java_review.setStatus(review.status)
       java_review.setResolution(review.resolution)
-      java_review.setAssigneeId(review.assignee_id)
       java_review.setManual(review.manual_violation)
       java_review.setPropertiesAsString(review.data)
     else