private static final String[] INSPECTION_TABLES = {
"action_plans", "authors", "dependencies", "duplications_index", "events", "graphs", "issues", "issue_changes", "manual_measures",
"notifications", "project_links", "project_measures", "projects", "resource_index",
- "semaphores", "snapshot_sources", "snapshots", "snapshot_data", "file_sources"
+ "semaphores", "snapshots", "snapshot_data", "file_sources"
};
private static final String[] RESOURCE_RELATED_TABLES = {
"group_roles", "user_roles", "properties"
--- /dev/null
+#
+# 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.
+#
+
+#
+# SonarQube 5.0
+# SONAR-5589
+#
+class DropSnapshotSources < ActiveRecord::Migration
+
+ def self.up
+ remove_index :snapshot_sources, :name => 'snap_sources_snapshot_id'
+ drop_table :snapshot_sources
+ end
+
+end
*/
public class DatabaseVersion implements BatchComponent, ServerComponent {
- public static final int LAST_VERSION = 716;
+ public static final int LAST_VERSION = 717;
/**
* List of all the tables.
* This list is hardcoded because we didn't succeed in using java.sql.DatabaseMetaData#getTables() in the same way
"semaphores",
"schema_migrations",
"snapshots",
- "snapshot_sources",
"snapshot_data",
"users",
"user_roles",
INSERT INTO SCHEMA_MIGRATIONS(VERSION) VALUES ('714');
INSERT INTO SCHEMA_MIGRATIONS(VERSION) VALUES ('715');
INSERT INTO SCHEMA_MIGRATIONS(VERSION) VALUES ('716');
+INSERT INTO SCHEMA_MIGRATIONS(VERSION) VALUES ('717');
INSERT INTO USERS(ID, LOGIN, NAME, EMAIL, CRYPTED_PASSWORD, SALT, CREATED_AT, UPDATED_AT, REMEMBER_TOKEN, REMEMBER_TOKEN_EXPIRES_AT) VALUES (1, 'admin', 'Administrator', '', 'a373a0e667abb2604c1fd571eb4ad47fe8cc0878', '48bc4b0d93179b5103fd3885ea9119498e9d161b', '2011-09-26 22:27:48.0', '2011-09-26 22:27:48.0', null, null);
ALTER TABLE USERS ALTER COLUMN ID RESTART WITH 2;
"MEASURE_DATA" BINARY(167772150)
);
-CREATE TABLE "SNAPSHOT_SOURCES" (
- "ID" INTEGER NOT NULL GENERATED BY DEFAULT AS IDENTITY (START WITH 1, INCREMENT BY 1),
- "SNAPSHOT_ID" INTEGER NOT NULL,
- "UPDATED_AT" TIMESTAMP,
- "DATA" CLOB(2147483647)
-);
-
CREATE TABLE "PROJECTS" (
"ID" INTEGER NOT NULL GENERATED BY DEFAULT AS IDENTITY (START WITH 1, INCREMENT BY 1),
"KEE" VARCHAR(400),
CREATE INDEX "DUPLICATIONS_INDEX_PSID" ON "DUPLICATIONS_INDEX" ("PROJECT_SNAPSHOT_ID");
-CREATE INDEX "SNAP_SOURCES_SNAPSHOT_ID" ON "SNAPSHOT_SOURCES" ("SNAPSHOT_ID");
-
CREATE INDEX "INDEX_GROUPS_USERS_ON_GROUP_ID" ON "GROUPS_USERS" ("GROUP_ID");
CREATE INDEX "INDEX_GROUPS_USERS_ON_USER_ID" ON "GROUPS_USERS" ("USER_ID");