]> source.dussan.org Git - sonarqube.git/commitdiff
SONAR-5329 - Moved some files over to sonar-core due to legacy
authorStephane Gamard <stephane.gamard@searchbox.com>
Mon, 2 Jun 2014 10:33:27 +0000 (12:33 +0200)
committerStephane Gamard <stephane.gamard@searchbox.com>
Wed, 4 Jun 2014 13:55:01 +0000 (15:55 +0200)
14 files changed:
sonar-core/src/main/java/org/sonar/core/log/Log.java [new file with mode: 0644]
sonar-core/src/main/java/org/sonar/core/log/LogDto.java [new file with mode: 0644]
sonar-core/src/main/java/org/sonar/core/log/db/LogKey.java [new file with mode: 0644]
sonar-core/src/main/java/org/sonar/core/log/db/LogMapper.java [new file with mode: 0644]
sonar-core/src/main/java/org/sonar/core/persistence/MyBatis.java
sonar-core/src/main/resources/org/sonar/core/log/db/LogMapper.xml [new file with mode: 0644]
sonar-server/src/main/java/org/sonar/server/log/Log.java [deleted file]
sonar-server/src/main/java/org/sonar/server/log/LogDto.java [deleted file]
sonar-server/src/main/java/org/sonar/server/log/db/LogDao.java
sonar-server/src/main/java/org/sonar/server/log/db/LogKey.java [deleted file]
sonar-server/src/main/java/org/sonar/server/log/db/LogMapper.java [deleted file]
sonar-server/src/main/java/org/sonar/server/log/index/LogIndex.java
sonar-server/src/main/java/org/sonar/server/log/index/LogNormalizer.java
sonar-server/src/main/java/org/sonar/server/rule/index/RuleDoc.java

diff --git a/sonar-core/src/main/java/org/sonar/core/log/Log.java b/sonar-core/src/main/java/org/sonar/core/log/Log.java
new file mode 100644 (file)
index 0000000..ab8d26e
--- /dev/null
@@ -0,0 +1,26 @@
+/*
+ * SonarQube, open source software quality management tool.
+ * Copyright (C) 2008-2014 SonarSource
+ * mailto:contact AT sonarsource DOT com
+ *
+ * SonarQube 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.
+ *
+ * SonarQube 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 this program; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+ */
+package org.sonar.core.log;
+
+/**
+ * @since 4.4
+ */
+public interface Log {
+}
diff --git a/sonar-core/src/main/java/org/sonar/core/log/LogDto.java b/sonar-core/src/main/java/org/sonar/core/log/LogDto.java
new file mode 100644 (file)
index 0000000..0f35cff
--- /dev/null
@@ -0,0 +1,136 @@
+/*
+ * SonarQube, open source software quality management tool.
+ * Copyright (C) 2008-2014 SonarSource
+ * mailto:contact AT sonarsource DOT com
+ *
+ * SonarQube 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.
+ *
+ * SonarQube 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 this program; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+ */
+package org.sonar.core.log;
+
+import org.apache.commons.io.output.ByteArrayOutputStream;
+import org.sonar.core.persistence.Dto;
+import org.sonar.core.log.db.LogKey;
+
+import java.io.ByteArrayInputStream;
+import java.io.ObjectInputStream;
+import java.io.ObjectOutputStream;
+import java.util.Date;
+import java.util.Map;
+
+/**
+ * @since 4.4
+ */
+public class LogDto extends Dto<LogKey> {
+
+  public static enum Type {
+    CHANGE, LOG
+  }
+
+  public static enum Status {
+    OK, FAIL
+  }
+
+  private Date time;
+  private Type type;
+  private Status status;
+  private Long executionTime;
+  private String author;
+  private String data;
+
+  private LogDto(Date time, Type type) {
+    this.time = time;
+    this.type = type;
+  }
+
+  @Override
+  public LogKey getKey() {
+    return LogKey.of(time, type, author);
+  }
+
+  public Date getTime() {
+    return time;
+  }
+
+  public LogDto setTime(Date time) {
+    this.time = time;
+    return this;
+  }
+
+  public Type getType() {
+    return type;
+  }
+
+  public LogDto setType(Type type) {
+    this.type = type;
+    return this;
+  }
+
+  public Status getStatus() {
+    return status;
+  }
+
+  public LogDto setStatus(Status status) {
+    this.status = status;
+    return this;
+  }
+
+  public Long getExecutionTime() {
+    return executionTime;
+  }
+
+  public LogDto setExecutionTime(Long executionTime) {
+    this.executionTime = executionTime;
+    return this;
+  }
+
+  public String getAuthor() {
+    return author;
+  }
+
+  public LogDto setAuthor(String author) {
+    this.author = author;
+    return this;
+  }
+
+  public Map getPayload() {
+    try {
+      byte[] bytes = this.data.getBytes();
+      ObjectInputStream ois = new ObjectInputStream(
+        new ByteArrayInputStream(bytes));
+      Map payload = (Map) ois.readObject();
+      ois.close();
+      return payload;
+    } catch (Exception e) {
+      throw new IllegalStateException("Could not read payload from DB.", e);
+    }
+  }
+
+  public LogDto setPayload(Map payload) {
+    try {
+      ByteArrayOutputStream baos = new ByteArrayOutputStream();
+      ObjectOutputStream oos = new ObjectOutputStream(baos);
+      oos.writeObject(payload);
+      oos.close();
+      this.data = new String(baos.toByteArray());
+    } catch (Exception e) {
+      throw new IllegalStateException("Could not write payload from DB.", e);
+    }
+    return this;
+  }
+
+  public LogDto changeLog() {
+    return new LogDto(new Date(), Type.CHANGE);
+  }
+}
diff --git a/sonar-core/src/main/java/org/sonar/core/log/db/LogKey.java b/sonar-core/src/main/java/org/sonar/core/log/db/LogKey.java
new file mode 100644 (file)
index 0000000..48c06e4
--- /dev/null
@@ -0,0 +1,87 @@
+/*
+ * SonarQube, open source software quality management tool.
+ * Copyright (C) 2008-2014 SonarSource
+ * mailto:contact AT sonarsource DOT com
+ *
+ * SonarQube 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.
+ *
+ * SonarQube 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 this program; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+ */
+package org.sonar.core.log.db;
+
+import com.google.common.base.Preconditions;
+import org.sonar.core.log.LogDto;
+
+import java.io.Serializable;
+import java.util.Date;
+
+/**
+ * @since 4.4
+ */
+public class LogKey implements Serializable {
+
+  private Date time;
+  private LogDto.Type type;
+  private String author;
+
+  public LogKey(Date time, LogDto.Type type, String author) {
+    this.time = time;
+    this.type = type;
+    this.author = author;
+  }
+
+  /**
+   * Create a key. Parameters are NOT null.
+   */
+  public static LogKey of(Date time, LogDto.Type type, String author) {
+    Preconditions.checkArgument(time != null, "Time must be set");
+    Preconditions.checkArgument(type != null, "Type must be set");
+    Preconditions.checkArgument(author != null, "Author must be set");
+    return new LogKey(time, type, author);
+  }
+
+  /**
+   * Create a key from a string representation (see {@link #toString()}. An {@link IllegalArgumentException} is raised
+   * if the format is not valid.
+   */
+  public static LogKey parse(String s) {
+    String[] split = s.split(":");
+    Preconditions.checkArgument(split.length == 3, "Invalid log key: " + s);
+    return LogKey.of(new Date(Long.getLong(split[0])),
+      LogDto.Type.valueOf(split[1]), split[2]);
+  }
+
+  public Date getTime() {
+    return time;
+  }
+
+  public void setTime(Date time) {
+    this.time = time;
+  }
+
+  public LogDto.Type getType() {
+    return type;
+  }
+
+  public void setType(LogDto.Type type) {
+    this.type = type;
+  }
+
+  public String getAuthor() {
+    return author;
+  }
+
+  public void setAuthor(String author) {
+    this.author = author;
+  }
+}
diff --git a/sonar-core/src/main/java/org/sonar/core/log/db/LogMapper.java b/sonar-core/src/main/java/org/sonar/core/log/db/LogMapper.java
new file mode 100644 (file)
index 0000000..da013ba
--- /dev/null
@@ -0,0 +1,31 @@
+/*
+ * SonarQube, open source software quality management tool.
+ * Copyright (C) 2008-2014 SonarSource
+ * mailto:contact AT sonarsource DOT com
+ *
+ * SonarQube 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.
+ *
+ * SonarQube 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 this program; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+ */
+package org.sonar.core.log.db;
+
+import org.sonar.core.log.LogDto;
+
+/**
+ * @since 4.4
+ */
+public interface LogMapper {
+
+  void insert(LogDto rule);
+
+}
index 6be80b0078fc2251328e3776658977edcd7175ef..928f38b3d1b5efca37ab6b6eda5d9306cf3382e3 100644 (file)
@@ -68,6 +68,8 @@ import org.sonar.core.issue.db.IssueFilterFavouriteMapper;
 import org.sonar.core.issue.db.IssueFilterMapper;
 import org.sonar.core.issue.db.IssueMapper;
 import org.sonar.core.issue.db.IssueStatsMapper;
+import org.sonar.core.log.LogDto;
+import org.sonar.core.log.db.LogMapper;
 import org.sonar.core.measure.db.MeasureDto;
 import org.sonar.core.measure.db.MeasureFilterDto;
 import org.sonar.core.measure.db.MeasureFilterMapper;
@@ -199,6 +201,7 @@ public class MyBatis implements BatchComponent, ServerComponent {
     loadAlias(conf, "QualityProfile", QualityProfileDto.class);
     loadAlias(conf, "ActiveRule", ActiveRuleDto.class);
     loadAlias(conf, "ActiveRuleParam", ActiveRuleParamDto.class);
+    loadAlias(conf, "Log", LogDto.class);
 
     // AuthorizationMapper has to be loaded before IssueMapper because this last one used it
     loadMapper(conf, "org.sonar.core.user.AuthorizationMapper");
@@ -206,7 +209,7 @@ public class MyBatis implements BatchComponent, ServerComponent {
     loadMapper(conf, ResourceMapper.class);
 
     loadMapper(conf, "org.sonar.core.permission.PermissionMapper");
-    Class<?>[] mappers = {ActiveDashboardMapper.class, AuthorMapper.class, DashboardMapper.class,
+    Class<?>[] mappers = {LogMapper.class, ActiveDashboardMapper.class, AuthorMapper.class, DashboardMapper.class,
       DependencyMapper.class, DuplicationMapper.class, GraphDtoMapper.class,
       IssueMapper.class, IssueStatsMapper.class, IssueChangeMapper.class, IssueFilterMapper.class, IssueFilterFavouriteMapper.class,
       LoadedTemplateMapper.class, MeasureFilterMapper.class, PermissionTemplateMapper.class, PropertiesMapper.class, PurgeMapper.class,
diff --git a/sonar-core/src/main/resources/org/sonar/core/log/db/LogMapper.xml b/sonar-core/src/main/resources/org/sonar/core/log/db/LogMapper.xml
new file mode 100644 (file)
index 0000000..0619606
--- /dev/null
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+
+<mapper namespace="org.sonar.core.log.LogMapper">
+    <insert id="insert" parameterType="Log" useGeneratedKeys="false">
+        insert into logs
+        (time_field,type_field,status_field,execution_time_field,author_field,data_field)
+        values (#{time}, #{type}, #{status}, #{executionTime}, #{author}, #{data})
+    </insert>
+</mapper>
+
diff --git a/sonar-server/src/main/java/org/sonar/server/log/Log.java b/sonar-server/src/main/java/org/sonar/server/log/Log.java
deleted file mode 100644 (file)
index dcbb991..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * SonarQube, open source software quality management tool.
- * Copyright (C) 2008-2014 SonarSource
- * mailto:contact AT sonarsource DOT com
- *
- * SonarQube 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.
- *
- * SonarQube 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 this program; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
- */
-package org.sonar.server.log;
-
-/**
- * @since 4.4
- */
-public interface Log {
-}
diff --git a/sonar-server/src/main/java/org/sonar/server/log/LogDto.java b/sonar-server/src/main/java/org/sonar/server/log/LogDto.java
deleted file mode 100644 (file)
index 8a41cd9..0000000
+++ /dev/null
@@ -1,137 +0,0 @@
-/*
- * SonarQube, open source software quality management tool.
- * Copyright (C) 2008-2014 SonarSource
- * mailto:contact AT sonarsource DOT com
- *
- * SonarQube 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.
- *
- * SonarQube 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 this program; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
- */
-package org.sonar.server.log;
-
-import org.apache.commons.io.output.ByteArrayOutputStream;
-import org.sonar.core.persistence.Dto;
-import org.sonar.server.log.db.LogKey;
-import org.yaml.snakeyaml.external.biz.base64Coder.Base64Coder;
-
-import java.io.ByteArrayInputStream;
-import java.io.ObjectInputStream;
-import java.io.ObjectOutputStream;
-import java.util.Date;
-import java.util.Map;
-
-/**
- * @since 4.4
- */
-public class LogDto extends Dto<LogKey> {
-
-  public static enum Type {
-    CHANGE, LOG
-  }
-
-  public static enum Status {
-    OK, FAIL
-  }
-
-  private Date time;
-  private Type type;
-  private Status status;
-  private Long executionTime;
-  private String author;
-  private String data;
-
-  private LogDto(Date time, Type type) {
-    this.time = time;
-    this.type = type;
-  }
-
-  @Override
-  public LogKey getKey() {
-    return LogKey.of(time, type, author);
-  }
-
-  public Date getTime() {
-    return time;
-  }
-
-  public LogDto setTime(Date time) {
-    this.time = time;
-    return this;
-  }
-
-  public Type getType() {
-    return type;
-  }
-
-  public LogDto setType(Type type) {
-    this.type = type;
-    return this;
-  }
-
-  public Status getStatus() {
-    return status;
-  }
-
-  public LogDto setStatus(Status status) {
-    this.status = status;
-    return this;
-  }
-
-  public Long getExecutionTime() {
-    return executionTime;
-  }
-
-  public LogDto setExecutionTime(Long executionTime) {
-    this.executionTime = executionTime;
-    return this;
-  }
-
-  public String getAuthor() {
-    return author;
-  }
-
-  public LogDto setAuthor(String author) {
-    this.author = author;
-    return this;
-  }
-
-  public Map getPayload() {
-    try {
-      byte[] bytes = Base64Coder.decode(this.data);
-      ObjectInputStream ois = new ObjectInputStream(
-        new ByteArrayInputStream(bytes));
-      Map payload = (Map) ois.readObject();
-      ois.close();
-      return payload;
-    } catch (Exception e) {
-      throw new IllegalStateException("Could not read payload from DB.", e);
-    }
-  }
-
-  public LogDto setPayload(Map payload) {
-    try {
-      ByteArrayOutputStream baos = new ByteArrayOutputStream();
-      ObjectOutputStream oos = new ObjectOutputStream(baos);
-      oos.writeObject(payload);
-      oos.close();
-      this.data = new String(Base64Coder.encode(baos.toByteArray()));
-    } catch (Exception e) {
-      throw new IllegalStateException("Could not write payload from DB.", e);
-    }
-    return this;
-  }
-
-  public LogDto changeLog() {
-    return new LogDto(new Date(), Type.CHANGE);
-  }
-}
index fe5c11b1133fe42465ab878e1ac8a009c2ecd180..30ac85436ab65f9f1574c6488297b312ba38b01f 100644 (file)
@@ -21,9 +21,11 @@ package org.sonar.server.log.db;
 
 import com.google.common.annotations.VisibleForTesting;
 import org.sonar.api.utils.System2;
+import org.sonar.core.log.LogDto;
+import org.sonar.core.log.db.LogKey;
+import org.sonar.core.log.db.LogMapper;
 import org.sonar.core.persistence.DbSession;
 import org.sonar.server.db.BaseDao;
-import org.sonar.server.log.LogDto;
 import org.sonar.server.search.IndexDefinition;
 
 /**
diff --git a/sonar-server/src/main/java/org/sonar/server/log/db/LogKey.java b/sonar-server/src/main/java/org/sonar/server/log/db/LogKey.java
deleted file mode 100644 (file)
index ef1aa49..0000000
+++ /dev/null
@@ -1,87 +0,0 @@
-/*
- * SonarQube, open source software quality management tool.
- * Copyright (C) 2008-2014 SonarSource
- * mailto:contact AT sonarsource DOT com
- *
- * SonarQube 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.
- *
- * SonarQube 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 this program; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
- */
-package org.sonar.server.log.db;
-
-import com.google.common.base.Preconditions;
-import org.sonar.server.log.LogDto;
-
-import java.io.Serializable;
-import java.util.Date;
-
-/**
- * @since 4.4
- */
-public class LogKey implements Serializable {
-
-  private Date time;
-  private LogDto.Type type;
-  private String author;
-
-  public LogKey(Date time, LogDto.Type type, String author) {
-    this.time = time;
-    this.type = type;
-    this.author = author;
-  }
-
-  /**
-   * Create a key. Parameters are NOT null.
-   */
-  public static LogKey of(Date time, LogDto.Type type, String author) {
-    Preconditions.checkArgument(time != null, "Time must be set");
-    Preconditions.checkArgument(type != null, "Type must be set");
-    Preconditions.checkArgument(author != null, "Author must be set");
-    return new LogKey(time, type, author);
-  }
-
-  /**
-   * Create a key from a string representation (see {@link #toString()}. An {@link IllegalArgumentException} is raised
-   * if the format is not valid.
-   */
-  public static LogKey parse(String s) {
-    String[] split = s.split(":");
-    Preconditions.checkArgument(split.length == 3, "Invalid log key: " + s);
-    return LogKey.of(new Date(Long.getLong(split[0])),
-      LogDto.Type.valueOf(split[1]), split[2]);
-  }
-
-  public Date getTime() {
-    return time;
-  }
-
-  public void setTime(Date time) {
-    this.time = time;
-  }
-
-  public LogDto.Type getType() {
-    return type;
-  }
-
-  public void setType(LogDto.Type type) {
-    this.type = type;
-  }
-
-  public String getAuthor() {
-    return author;
-  }
-
-  public void setAuthor(String author) {
-    this.author = author;
-  }
-}
diff --git a/sonar-server/src/main/java/org/sonar/server/log/db/LogMapper.java b/sonar-server/src/main/java/org/sonar/server/log/db/LogMapper.java
deleted file mode 100644 (file)
index 08325d0..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * SonarQube, open source software quality management tool.
- * Copyright (C) 2008-2014 SonarSource
- * mailto:contact AT sonarsource DOT com
- *
- * SonarQube 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.
- *
- * SonarQube 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 this program; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
- */
-package org.sonar.server.log.db;
-
-/**
- * @since 4.4
- */
-public interface LogMapper {
-
-}
index e7ec47d3a280ad21b2888deae693afcbb57944a8..aa5db40a221a8276b2790501ba3b7b898905601a 100644 (file)
@@ -21,9 +21,9 @@ package org.sonar.server.log.index;
 
 import org.elasticsearch.common.settings.Settings;
 import org.sonar.core.cluster.WorkQueue;
-import org.sonar.server.log.Log;
-import org.sonar.server.log.LogDto;
-import org.sonar.server.log.db.LogKey;
+import org.sonar.core.log.Log;
+import org.sonar.core.log.LogDto;
+import org.sonar.core.log.db.LogKey;
 import org.sonar.server.search.BaseIndex;
 import org.sonar.server.search.ESNode;
 import org.sonar.server.search.IndexDefinition;
index 2183cc860320c663052adb8e1065d77bd6e4e6cf..b0282ae6a14c94aa6d00d99ac71b00d7488f6b0b 100644 (file)
@@ -21,8 +21,8 @@ package org.sonar.server.log.index;
 
 import org.elasticsearch.action.update.UpdateRequest;
 import org.sonar.server.db.DbClient;
-import org.sonar.server.log.LogDto;
-import org.sonar.server.log.db.LogKey;
+import org.sonar.core.log.LogDto;
+import org.sonar.core.log.db.LogKey;
 import org.sonar.server.search.BaseNormalizer;
 import org.sonar.server.search.IndexDefinition;
 
index 3e78c33bc3abd7e4c0b8de9977d56144791679b8..e95b4e3031391b74a54988d7f5284456560e091e 100644 (file)
@@ -29,6 +29,7 @@ import org.sonar.server.rule.RuleParam;
 import org.sonar.server.search.BaseDoc;
 import org.sonar.server.search.IndexUtils;
 
+import javax.annotation.Nullable;
 import java.util.ArrayList;
 import java.util.Collections;
 import java.util.Date;