summaryrefslogtreecommitdiffstats
path: root/server
diff options
context:
space:
mode:
authorSimon Brandhof <simon.brandhof@sonarsource.com>2015-06-10 23:01:00 +0200
committerSimon Brandhof <simon.brandhof@sonarsource.com>2015-07-16 22:23:11 +0200
commitfdf6360e5cb94fa34fa82b18ce64ce61a27aec09 (patch)
treee370cc8ac1e22f692687a0eaa0c0595e0aac47f1 /server
parentd9a122f18dcd89c7dd02245d83fc13fa74fde962 (diff)
downloadsonarqube-fdf6360e5cb94fa34fa82b18ce64ce61a27aec09.tar.gz
sonarqube-fdf6360e5cb94fa34fa82b18ce64ce61a27aec09.zip
SONAR-6716 Compress migrations of table characteristics
Diffstat (limited to 'server')
-rw-r--r--server/sonar-web/src/main/webapp/WEB-INF/db/migrate/131_create_quality_models.rb2
-rw-r--r--server/sonar-web/src/main/webapp/WEB-INF/db/migrate/138_add_characteristic_description.rb30
-rw-r--r--server/sonar-web/src/main/webapp/WEB-INF/db/migrate/139_add_characteristic_enabled.rb30
3 files changed, 2 insertions, 60 deletions
diff --git a/server/sonar-web/src/main/webapp/WEB-INF/db/migrate/131_create_quality_models.rb b/server/sonar-web/src/main/webapp/WEB-INF/db/migrate/131_create_quality_models.rb
index e72b8e1f533..150325b272f 100644
--- a/server/sonar-web/src/main/webapp/WEB-INF/db/migrate/131_create_quality_models.rb
+++ b/server/sonar-web/src/main/webapp/WEB-INF/db/migrate/131_create_quality_models.rb
@@ -35,6 +35,8 @@ class CreateQualityModels < ActiveRecord::Migration
t.column 'rule_id', :integer, :null => true
t.column 'depth', :integer, :null => true
t.column 'characteristic_order', :integer, :null => true
+ t.column 'description', :string, :null => true, :limit => 4000
+ t.column 'enabled', :boolean, :null => true
end
create_table 'characteristic_edges', :id => false do |t|
diff --git a/server/sonar-web/src/main/webapp/WEB-INF/db/migrate/138_add_characteristic_description.rb b/server/sonar-web/src/main/webapp/WEB-INF/db/migrate/138_add_characteristic_description.rb
deleted file mode 100644
index 1618ca666ad..00000000000
--- a/server/sonar-web/src/main/webapp/WEB-INF/db/migrate/138_add_characteristic_description.rb
+++ /dev/null
@@ -1,30 +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.
-#
-
-#
-# Sonar 2.3
-#
-class AddCharacteristicDescription < ActiveRecord::Migration
-
- def self.up
- add_column 'characteristics', 'description', :string, :null => true, :limit => 4000
- end
-
-end
diff --git a/server/sonar-web/src/main/webapp/WEB-INF/db/migrate/139_add_characteristic_enabled.rb b/server/sonar-web/src/main/webapp/WEB-INF/db/migrate/139_add_characteristic_enabled.rb
deleted file mode 100644
index bff3b190455..00000000000
--- a/server/sonar-web/src/main/webapp/WEB-INF/db/migrate/139_add_characteristic_enabled.rb
+++ /dev/null
@@ -1,30 +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.
-#
-
-#
-# Sonar 2.3
-#
-class AddCharacteristicEnabled < ActiveRecord::Migration
-
- def self.up
- add_column 'characteristics', 'enabled', :boolean, :null => true
- end
-
-end