6.查看sonar库中有哪些表是使用的MyISAM engine(注:这里TABLE_SCHEMA中的‘sonar’为安装sonar建库时数据库的名称,需改成自身建库时的名称)
SELECT TABLE_NAME, ENGINE FROM information_schema.TABLES WHERE TABLE_SCHEMA = 'sonar';
+---------------------------+--------+
| TABLE_NAME | ENGINE |
+---------------------------+--------+
| action_plans | MyISAM |
| active_dashboards | MyISAM |
| active_rule_changes | MyISAM |
| active_rule_param_changes | MyISAM |
| active_rule_parameters | MyISAM |
| active_rules | MyISAM |
| activities | MyISAM |
| authors | MyISAM |
| characteristics | MyISAM |
| dashboards | MyISAM |
| dependencies | MyISAM |
| duplications_index | MyISAM |
| events | MyISAM |
| graphs | MyISAM |
| group_roles | MyISAM |
| groups | MyISAM |
| groups_users | MyISAM |
| issue_changes | MyISAM |
| issue_filter_favourites | MyISAM |
| issue_filters | MyISAM |
| issues | MyISAM |
| loaded_templates | MyISAM |
| manual_measures | MyISAM |
| measure_filter_favourites | MyISAM |
| measure_filters | MyISAM |
| metrics | MyISAM |
| notifications | MyISAM |
| perm_templates_groups | MyISAM |
| perm_templates_users | MyISAM |
| permission_templates | MyISAM |
| project_links | MyISAM |
| project_measures | MyISAM |
| projects | MyISAM |
| properties | MyISAM |
| quality_gate_conditions | MyISAM |
| quality_gates | MyISAM |
| resource_index | MyISAM |
| rules | MyISAM |
| rules_parameters | MyISAM |
| rules_profiles | MyISAM |
| schema_migrations | MyISAM |
| semaphores | MyISAM |
| snapshot_data | MyISAM |
| snapshot_sources | MyISAM |
| snapshots | MyISAM |
| user_roles | MyISAM |
| users | MyISAM |
| widget_properties | MyISAM |
| widgets | MyISAM |
+---------------------------+--------+
49 rows in set (0.01 sec)
ALTER TABLE sonar.widget_properties ENGINE=INNODB; ALTER TABLE sonar.widgets ENGINE=INNODB; ALTER TABLE sonar.user_roles ENGINE=INNODB; ALTER TABLE sonar.users ENGINE=INNODB; ALTER TABLE sonar.snapshot_sources ENGINE=INNODB; ALTER TABLE sonar.snapshot_data ENGINE=INNODB; ALTER TABLE sonar.snapshots ENGINE=INNODB; ALTER TABLE sonar.semaphores ENGINE=INNODB; ALTER TABLE sonar.schema_migrations ENGINE=INNODB; ALTER TABLE sonar.rules_profiles ENGINE=INNODB; ALTER TABLE sonar.rules_parameters ENGINE=INNODB; ALTER TABLE sonar.rules ENGINE=INNODB; ALTER TABLE sonar.resource_index ENGINE=INNODB; ALTER TABLE sonar.quality_gate_conditions ENGINE=INNODB; ALTER TABLE sonar.quality_gates ENGINE=INNODB; ALTER TABLE sonar.properties ENGINE=INNODB; ALTER TABLE sonar.project_measures ENGINE=INNODB; ALTER TABLE sonar.project_links ENGINE=INNODB; ALTER TABLE sonar.projects ENGINE=INNODB; ALTER TABLE sonar.perm_templates_users ENGINE=INNODB; ALTER TABLE sonar.perm_templates_groups ENGINE=INNODB; ALTER TABLE sonar.permission_templates ENGINE=INNODB; ALTER TABLE sonar.notifications ENGINE=INNODB; ALTER TABLE sonar.metrics ENGINE=INNODB; ALTER TABLE sonar.measure_filter_favourites ENGINE=INNODB; ALTER TABLE sonar.measure_filters ENGINE=INNODB; ALTER TABLE sonar.manual_measures ENGINE=INNODB; ALTER TABLE sonar.loaded_templates ENGINE=INNODB; ALTER TABLE sonar.issue_filter_favourites ENGINE=INNODB; ALTER TABLE sonar.issue_filters ENGINE=INNODB; ALTER TABLE sonar.issue_changes ENGINE=INNODB; ALTER TABLE sonar.issues ENGINE=INNODB; ALTER TABLE sonar.group_roles ENGINE=INNODB; ALTER TABLE sonar.groups_users ENGINE=INNODB; ALTER TABLE sonar.groups ENGINE=INNODB; ALTER TABLE sonar.graphs ENGINE=INNODB; ALTER TABLE sonar.events ENGINE=INNODB; ALTER TABLE sonar.duplications_index ENGINE=INNODB; ALTER TABLE sonar.dependencies ENGINE=INNODB; ALTER TABLE sonar.dashboards ENGINE=INNODB; ALTER TABLE sonar.characteristics ENGINE=INNODB; ALTER TABLE sonar.authors ENGINE=INNODB; ALTER TABLE sonar.activities ENGINE=INNODB; ALTER TABLE sonar.active_rule_param_changes ENGINE=INNODB; ALTER TABLE sonar.active_rule_parameters ENGINE=INNODB; ALTER TABLE sonar.active_rule_changes ENGINE=INNODB; ALTER TABLE sonar.active_rules ENGINE=INNODB; ALTER TABLE sonar.active_dashboards ENGINE=INNODB; ALTER TABLE sonar.action_plans ENGINE=INNODB;
三、服务端分析项目时或Eclipse本地分析时报
Caused by: org.sonar.api.utils.SonarException: The plugin findbugs is not supported with Java 1.6.0_**
由于最新版本的findbugs插件需要JDK1.7及以上的支持,因此需要安装JDK1.7以上
对于Eclipse,若不想改变系统的JAVA环境,而只改变Eclipse中的JAVA环境,则可在eclipse.ini文件中增加
-vm
%JAVA1.7_HOME%/bin/javaw.exe