Sonar

Error when upgrading database from 1.5.1 to 1.9

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Won't Fix
  • Affects Version/s: 1.9
  • Fix Version/s: 1.9.1
  • Component/s: Database
  • Labels:
    None
  • Number of attachments :
    0

Description

Error logs :

StandardError (An error has occurred, all later migrations canceled:

RefactorResources is not missing constant Project060!):
    /gems/gems/activesupport-2.2.2/lib/active_support/dependencies.rb:419:in `load_missing_constant'
    /gems/gems/activesupport-2.2.2/lib/active_support/dependencies.rb:93:in `const_missing'
    /gems/gems/activesupport-2.2.2/lib/active_support/dependencies.rb:95:in `const_missing'
    /gems/gems/activerecord-2.2.2/lib/active_record/base.rb:2047:in `class_eval'
    /gems/gems/activerecord-2.2.2/lib/active_record/base.rb:2047:in `compute_type'
    /gems/gems/activesupport-2.2.2/lib/active_support/core_ext/kernel/reporting.rb:11:in `silence_warnings'
    /gems/gems/activerecord-2.2.2/lib/active_record/base.rb:2045:in `compute_type'
    /gems/gems/activerecord-2.2.2/lib/active_record/reflection.rb:151:in `klass'
    /gems/gems/activerecord-2.2.2/lib/active_record/associations/belongs_to_association.rb:44:in `find_target'
    /gems/gems/activerecord-2.2.2/lib/active_record/associations/association_proxy.rb:233:in `load_target'
    /gems/gems/activerecord-2.2.2/lib/active_record/associations/association_proxy.rb:112:in `reload'
    /gems/gems/activerecord-2.2.2/lib/active_record/associations.rb:1249:in `project'
    /config/../lib/../db/migrate//060_refactor_resources.rb:43:in `up'
    /config/../lib/../db/migrate//060_refactor_resources.rb:42:in `each'
    /config/../lib/../db/migrate//060_refactor_resources.rb:42:in `up'
    /gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:280:in `migrate'
    file:/lib/jruby-complete-1.2.0.jar!/benchmark.rb:293:in `measure'
    /gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:280:in `migrate'
    (__DELEGATION__):2:in `migrate'
    /gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:480:in `migrate'
    /gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:556:in `call'
    /gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:556:in `ddl_transaction'
    /gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:479:in `migrate'

Activity

Hide
philippe sigaud added a comment -

Sorry but I have the same issue and I'm trying to upgrade from 1.5.1 to 1.9.2.

StandardError in SetupController#setup_database
An error has occurred, all later migrations canceled:

Couldn't find RefactorResources::Project060 with ID=687
RAILS_ROOT: D:\Qualite/sonar-1.9.2/war/sonar-web/WEB-INF

Application Trace | Framework Trace | Full Trace
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/base.rb:1528:in `find_one'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/base.rb:1511:in `find_from_ids'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/base.rb:590:in `find'
D:\Qualite\sonar-1.9.2\war\sonar-web\WEB-INF/db/migrate//060_refactor_resources.rb:43:in `up'
D:\Qualite\sonar-1.9.2\war\sonar-web\WEB-INF/db/migrate//060_refactor_resources.rb:42:in `each'
D:\Qualite\sonar-1.9.2\war\sonar-web\WEB-INF/db/migrate//060_refactor_resources.rb:42:in `up'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:280:in `migrate'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:280:in `migrate'
(_DELEGATION_):2:in `migrate'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:480:in `migrate'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:556:in `call'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:556:in `ddl_transaction'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:479:in `migrate'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:466:in `each'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:466:in `migrate'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:394:in `up'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:377:in `migrate'
D:\Qualite\sonar-1.9.2\war\sonar-web\WEB-INF/lib/database_version.rb:63:in `setup'
app/controllers/setup_controller.rb:43:in `setup_database'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/base.rb:1253:in `perform_action'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/filters.rb:617:in `call_filters'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/filters.rb:610:in `perform_action_with_filters'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/benchmarking.rb:68:in `perform_action_with_benchmark'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/benchmarking.rb:68:in `perform_action_with_benchmark'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/rescue.rb:136:in `perform_action_with_rescue'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/caching/sql_cache.rb:13:in `perform_action_with_caching'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/connection_adapters/abstract/query_cache.rb:34:in `cache'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/query_cache.rb:8:in `cache'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/caching/sql_cache.rb:12:in `perform_action_with_caching'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/base.rb:524:in `process'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/filters.rb:606:in `process_with_filters'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/session_management.rb:134:in `process_with_session_management_support'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/base.rb:392:in `process'
:1
file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-complete-1.2.0.jar!/benchmark.rb:293:in `measure'
file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-complete-1.2.0.jar!/benchmark.rb:293:in `measure'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:183:in `handle_request'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:110:in `dispatch_unlocked'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:120:in `dispatch'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:132:in `dispatch_cgi'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:39:in `dispatch'
file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-rack-0.9.4.jar!/rack/adapter/rails_cgi.rb:24:in `call'
file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-rack-0.9.4.jar!/rack/adapter/rails.rb:35:in `serve_rails'
file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-rack-0.9.4.jar!/rack/adapter/rails.rb:40:in `call'
file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-rack-0.9.4.jar!/jruby/rack/rails.rb:144:in `call'
file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-rack-0.9.4.jar!/rack/handler/servlet.rb:17:in `call'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/base.rb:1528:in `find_one'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/base.rb:1511:in `find_from_ids'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/base.rb:590:in `find'
D:\Qualite\sonar-1.9.2\war\sonar-web\WEB-INF/db/migrate//060_refactor_resources.rb:43:in `up'
D:\Qualite\sonar-1.9.2\war\sonar-web\WEB-INF/db/migrate//060_refactor_resources.rb:42:in `each'
D:\Qualite\sonar-1.9.2\war\sonar-web\WEB-INF/db/migrate//060_refactor_resources.rb:42:in `up'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:280:in `migrate'
file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-complete-1.2.0.jar!/benchmark.rb:293:in `measure'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:280:in `migrate'
(_DELEGATION_):2:in `migrate'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:480:in `migrate'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:556:in `call'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:556:in `ddl_transaction'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:479:in `migrate'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:466:in `each'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:466:in `migrate'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:394:in `up'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:377:in `migrate'
D:\Qualite\sonar-1.9.2\war\sonar-web\WEB-INF/lib/database_version.rb:63:in `setup'
app/controllers/setup_controller.rb:43:in `setup_database'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/base.rb:1253:in `perform_action'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/filters.rb:617:in `call_filters'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/filters.rb:610:in `perform_action_with_filters'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/benchmarking.rb:68:in `perform_action_with_benchmark'
file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-complete-1.2.0.jar!/benchmark.rb:293:in `measure'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/benchmarking.rb:68:in `perform_action_with_benchmark'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/rescue.rb:136:in `perform_action_with_rescue'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/caching/sql_cache.rb:13:in `perform_action_with_caching'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/connection_adapters/abstract/query_cache.rb:34:in `cache'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/query_cache.rb:8:in `cache'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/caching/sql_cache.rb:12:in `perform_action_with_caching'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/base.rb:524:in `process'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/filters.rb:606:in `process_with_filters'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/session_management.rb:134:in `process_with_session_management_support'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/base.rb:392:in `process'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:183:in `handle_request'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:110:in `dispatch_unlocked'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:120:in `dispatch'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:132:in `dispatch_cgi'
D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:39:in `dispatch'
file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-rack-0.9.4.jar!/rack/adapter/rails_cgi.rb:24:in `call'
file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-rack-0.9.4.jar!/rack/adapter/rails.rb:35:in `serve_rails'
file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-rack-0.9.4.jar!/rack/adapter/rails.rb:40:in `call'
file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-rack-0.9.4.jar!/jruby/rack/rails.rb:144:in `call'
file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-rack-0.9.4.jar!/rack/handler/servlet.rb:17:in `call'
:1
Request
Parameters:

None

Show session dump


flash: !map:ActionController::Flash::FlashHash {}

Response
Headers:

Unknown macro: {"Cache-Control"=>"no-cache", "cookie"=>[], "Content-Type"=>""}
Show
philippe sigaud added a comment - Sorry but I have the same issue and I'm trying to upgrade from 1.5.1 to 1.9.2.
StandardError in SetupController#setup_database An error has occurred, all later migrations canceled: Couldn't find RefactorResources::Project060 with ID=687 RAILS_ROOT: D:\Qualite/sonar-1.9.2/war/sonar-web/WEB-INF Application Trace | Framework Trace | Full Trace D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/base.rb:1528:in `find_one' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/base.rb:1511:in `find_from_ids' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/base.rb:590:in `find' D:\Qualite\sonar-1.9.2\war\sonar-web\WEB-INF/db/migrate//060_refactor_resources.rb:43:in `up' D:\Qualite\sonar-1.9.2\war\sonar-web\WEB-INF/db/migrate//060_refactor_resources.rb:42:in `each' D:\Qualite\sonar-1.9.2\war\sonar-web\WEB-INF/db/migrate//060_refactor_resources.rb:42:in `up' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:280:in `migrate' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:280:in `migrate' (_DELEGATION_):2:in `migrate' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:480:in `migrate' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:556:in `call' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:556:in `ddl_transaction' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:479:in `migrate' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:466:in `each' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:466:in `migrate' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:394:in `up' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:377:in `migrate' D:\Qualite\sonar-1.9.2\war\sonar-web\WEB-INF/lib/database_version.rb:63:in `setup' app/controllers/setup_controller.rb:43:in `setup_database' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/base.rb:1253:in `perform_action' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/filters.rb:617:in `call_filters' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/filters.rb:610:in `perform_action_with_filters' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/benchmarking.rb:68:in `perform_action_with_benchmark' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/benchmarking.rb:68:in `perform_action_with_benchmark' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/rescue.rb:136:in `perform_action_with_rescue' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/caching/sql_cache.rb:13:in `perform_action_with_caching' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/connection_adapters/abstract/query_cache.rb:34:in `cache' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/query_cache.rb:8:in `cache' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/caching/sql_cache.rb:12:in `perform_action_with_caching' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/base.rb:524:in `process' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/filters.rb:606:in `process_with_filters' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/session_management.rb:134:in `process_with_session_management_support' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/base.rb:392:in `process' :1 file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-complete-1.2.0.jar!/benchmark.rb:293:in `measure' file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-complete-1.2.0.jar!/benchmark.rb:293:in `measure' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:183:in `handle_request' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:110:in `dispatch_unlocked' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:120:in `dispatch' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:132:in `dispatch_cgi' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:39:in `dispatch' file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-rack-0.9.4.jar!/rack/adapter/rails_cgi.rb:24:in `call' file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-rack-0.9.4.jar!/rack/adapter/rails.rb:35:in `serve_rails' file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-rack-0.9.4.jar!/rack/adapter/rails.rb:40:in `call' file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-rack-0.9.4.jar!/jruby/rack/rails.rb:144:in `call' file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-rack-0.9.4.jar!/rack/handler/servlet.rb:17:in `call' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/base.rb:1528:in `find_one' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/base.rb:1511:in `find_from_ids' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/base.rb:590:in `find' D:\Qualite\sonar-1.9.2\war\sonar-web\WEB-INF/db/migrate//060_refactor_resources.rb:43:in `up' D:\Qualite\sonar-1.9.2\war\sonar-web\WEB-INF/db/migrate//060_refactor_resources.rb:42:in `each' D:\Qualite\sonar-1.9.2\war\sonar-web\WEB-INF/db/migrate//060_refactor_resources.rb:42:in `up' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:280:in `migrate' file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-complete-1.2.0.jar!/benchmark.rb:293:in `measure' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:280:in `migrate' (_DELEGATION_):2:in `migrate' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:480:in `migrate' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:556:in `call' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:556:in `ddl_transaction' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:479:in `migrate' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:466:in `each' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:466:in `migrate' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:394:in `up' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/migration.rb:377:in `migrate' D:\Qualite\sonar-1.9.2\war\sonar-web\WEB-INF/lib/database_version.rb:63:in `setup' app/controllers/setup_controller.rb:43:in `setup_database' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/base.rb:1253:in `perform_action' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/filters.rb:617:in `call_filters' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/filters.rb:610:in `perform_action_with_filters' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/benchmarking.rb:68:in `perform_action_with_benchmark' file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-complete-1.2.0.jar!/benchmark.rb:293:in `measure' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/benchmarking.rb:68:in `perform_action_with_benchmark' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/rescue.rb:136:in `perform_action_with_rescue' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/caching/sql_cache.rb:13:in `perform_action_with_caching' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/connection_adapters/abstract/query_cache.rb:34:in `cache' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/activerecord-2.2.2/lib/active_record/query_cache.rb:8:in `cache' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/caching/sql_cache.rb:12:in `perform_action_with_caching' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/base.rb:524:in `process' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/filters.rb:606:in `process_with_filters' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/session_management.rb:134:in `process_with_session_management_support' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/base.rb:392:in `process' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:183:in `handle_request' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:110:in `dispatch_unlocked' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:120:in `dispatch' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:132:in `dispatch_cgi' D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/gems/gems/actionpack-2.2.2/lib/action_controller/dispatcher.rb:39:in `dispatch' file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-rack-0.9.4.jar!/rack/adapter/rails_cgi.rb:24:in `call' file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-rack-0.9.4.jar!/rack/adapter/rails.rb:35:in `serve_rails' file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-rack-0.9.4.jar!/rack/adapter/rails.rb:40:in `call' file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-rack-0.9.4.jar!/jruby/rack/rails.rb:144:in `call' file:/D:/Qualite/sonar-1.9.2/war/sonar-web/WEB-INF/lib/jruby-rack-0.9.4.jar!/rack/handler/servlet.rb:17:in `call' :1 Request Parameters: None Show session dump — flash: !map:ActionController::Flash::FlashHash {} Response Headers:
Unknown macro: {"Cache-Control"=>"no-cache", "cookie"=>[], "Content-Type"=>""}
Hide
philippe sigaud added a comment -

Would you like me to send my database ?

Show
philippe sigaud added a comment - Would you like me to send my database ?
Hide
philippe sigaud added a comment -

Here is what happened on the server :

wrapper | Launching a JVM...
jvm 1 | WrapperManager: Initializing...
jvm 1 | Sonar listens http://0.0.0.0:9000/
jvm 1 | == CreateAlertsTable: migrating ====================================
==========
jvm 1 | – create_table(:alerts)
jvm 1 | -> 0.0620s
jvm 1 | -> 0 rows
jvm 1 | – add_column(:project_measures, :alert_status, :string, {:limit=>5,
:null=>true})
jvm 1 | -> 115.1680s
jvm 1 | -> 1766809 rows
jvm 1 | == CreateAlertsTable: migrated (115.2300s) =========================
==========
jvm 1 |
jvm 1 | == CreateProfilesPerProject: migrating =============================
==========
jvm 1 | – add_column(:projects, :profile_id, :integer, {:null=>true})
jvm 1 | -> 2.4220s
jvm 1 | -> 39344 rows
jvm 1 | – rename_column(:rules_profiles, :active, :default_profile)
jvm 1 | -> 0.0780s
jvm 1 | -> 0 rows
jvm 1 | == CreateProfilesPerProject: migrated (2.5000s) ====================
==========
jvm 1 |
jvm 1 | == RemoveMetricsComparable: migrating ==============================
==========
jvm 1 | – remove_column(:metrics, :comparable)
jvm 1 | -> 0.1560s
jvm 1 | == RemoveMetricsComparable: migrated (0.1710s) =====================
==========
jvm 1 |
jvm 1 | == EnsureMeasureSnapshotColumnNull: migrating ======================
==========
jvm 1 | – change_column(:project_measures, :snapshot_id, :integer, {:null=>t
rue})
jvm 1 | -> 0.0630s
jvm 1 | -> 0 rows
jvm 1 | == EnsureMeasureSnapshotColumnNull: migrated (0.0630s) =============
==========
jvm 1 |
jvm 1 | == AddSnapshotsPath: migrating =====================================
==========
jvm 1 | – add_column(:snapshots, :path, :string, {:null=>true, :limit=>96})
jvm 1 | -> 3.4690s
jvm 1 | -> 30672 rows
jvm 1 | – add_column(:snapshots, :depth, :integer, {:null=>true})
jvm 1 | -> 3.4840s
jvm 1 | -> 30672 rows
jvm 1 | == AddSnapshotsPath: migrated (6.9680s) ============================
==========
jvm 1 |
jvm 1 | == AddPropertiesResource: migrating ================================
==========
jvm 1 | – drop_table("properties")
jvm 1 | -> 0.0150s
jvm 1 | -> 0 rows
jvm 1 | – create_table("properties")
jvm 1 | -> 0.0470s
jvm 1 | -> 0 rows
jvm 1 | – add_index(:properties, :prop_key, {:name=>"properties_key"})
jvm 1 | -> 0.1090s
jvm 1 | -> 0 rows
jvm 1 | == AddPropertiesResource: migrated (0.5780s) =======================
==========
jvm 1 |
jvm 1 | == RefactorResources: migrating ====================================
==========
jvm 1 | – add_column(:projects, :language, :string, {:null=>true, :limit=>5}
)
jvm 1 | -> 2.7500s
jvm 1 | -> 39344 rows
jvm 1 | == RefactorResources: migrating ====================================
==========
jvm 1 | – add_column(:projects, :language, :string, {:null=>true, :limit=>5}
)
jvm 1 | == RefactorResources: migrating ====================================
==========
jvm 1 | – add_column(:projects, :language, :string, {:null=>true, :limit=>5}
)
jvm 1 | -> 2.1250s
jvm 1 | -> 39344 rows

Show
philippe sigaud added a comment - Here is what happened on the server :
wrapper | Launching a JVM... jvm 1 | WrapperManager: Initializing... jvm 1 | Sonar listens http://0.0.0.0:9000/ jvm 1 | == CreateAlertsTable: migrating ==================================== ========== jvm 1 | – create_table(:alerts) jvm 1 | -> 0.0620s jvm 1 | -> 0 rows jvm 1 | – add_column(:project_measures, :alert_status, :string, {:limit=>5, :null=>true}) jvm 1 | -> 115.1680s jvm 1 | -> 1766809 rows jvm 1 | == CreateAlertsTable: migrated (115.2300s) ========================= ========== jvm 1 | jvm 1 | == CreateProfilesPerProject: migrating ============================= ========== jvm 1 | – add_column(:projects, :profile_id, :integer, {:null=>true}) jvm 1 | -> 2.4220s jvm 1 | -> 39344 rows jvm 1 | – rename_column(:rules_profiles, :active, :default_profile) jvm 1 | -> 0.0780s jvm 1 | -> 0 rows jvm 1 | == CreateProfilesPerProject: migrated (2.5000s) ==================== ========== jvm 1 | jvm 1 | == RemoveMetricsComparable: migrating ============================== ========== jvm 1 | – remove_column(:metrics, :comparable) jvm 1 | -> 0.1560s jvm 1 | == RemoveMetricsComparable: migrated (0.1710s) ===================== ========== jvm 1 | jvm 1 | == EnsureMeasureSnapshotColumnNull: migrating ====================== ========== jvm 1 | – change_column(:project_measures, :snapshot_id, :integer, {:null=>t rue}) jvm 1 | -> 0.0630s jvm 1 | -> 0 rows jvm 1 | == EnsureMeasureSnapshotColumnNull: migrated (0.0630s) ============= ========== jvm 1 | jvm 1 | == AddSnapshotsPath: migrating ===================================== ========== jvm 1 | – add_column(:snapshots, :path, :string, {:null=>true, :limit=>96}) jvm 1 | -> 3.4690s jvm 1 | -> 30672 rows jvm 1 | – add_column(:snapshots, :depth, :integer, {:null=>true}) jvm 1 | -> 3.4840s jvm 1 | -> 30672 rows jvm 1 | == AddSnapshotsPath: migrated (6.9680s) ============================ ========== jvm 1 | jvm 1 | == AddPropertiesResource: migrating ================================ ========== jvm 1 | – drop_table("properties") jvm 1 | -> 0.0150s jvm 1 | -> 0 rows jvm 1 | – create_table("properties") jvm 1 | -> 0.0470s jvm 1 | -> 0 rows jvm 1 | – add_index(:properties, :prop_key, {:name=>"properties_key"}) jvm 1 | -> 0.1090s jvm 1 | -> 0 rows jvm 1 | == AddPropertiesResource: migrated (0.5780s) ======================= ========== jvm 1 | jvm 1 | == RefactorResources: migrating ==================================== ========== jvm 1 | – add_column(:projects, :language, :string, {:null=>true, :limit=>5} ) jvm 1 | -> 2.7500s jvm 1 | -> 39344 rows jvm 1 | == RefactorResources: migrating ==================================== ========== jvm 1 | – add_column(:projects, :language, :string, {:null=>true, :limit=>5} ) jvm 1 | == RefactorResources: migrating ==================================== ========== jvm 1 | – add_column(:projects, :language, :string, {:null=>true, :limit=>5} ) jvm 1 | -> 2.1250s jvm 1 | -> 39344 rows
Hide
Freddy Mallet added a comment -

Hello Philippe, have you added some manual metrics to your project ? We suspect those manual metrics to be the root cause of this issue.

Show
Freddy Mallet added a comment - Hello Philippe, have you added some manual metrics to your project ? We suspect those manual metrics to be the root cause of this issue.
Hide
philippe sigaud added a comment -

None yet. I plan to later but for now I haven't.
I did add a personal event however.

Show
philippe sigaud added a comment - None yet. I plan to later but for now I haven't. I did add a personal event however.
Hide
Freddy Mallet added a comment -

Hello philippe, looks like you have a snapshot which is no more associated to a project in the Sonar DB. Have you deleted any rows in the projects table ?

Could you attach to this ticket, the result of the following sql request :

SELECT * FROM snapshots s where not exists (select * from projects p where p.id = project_id )

Thanks
Freddy

Show
Freddy Mallet added a comment - Hello philippe, looks like you have a snapshot which is no more associated to a project in the Sonar DB. Have you deleted any rows in the projects table ? Could you attach to this ticket, the result of the following sql request :
SELECT * FROM snapshots s where not exists (select * from projects p where p.id = project_id )
Thanks Freddy
Hide
philippe sigaud added a comment -

I did find a lot of records. I have no idea how they came to be like this.

I tried deleting them but then I got an other error. Something about an unknown column 'depth' in 'field list'.

Freddy I'll send you my database directly. I'm confident you'll make it talk. I must say I have no problem with Sonar 1.5.1 so this is a bit strange.

Thanks in advance for your help. I really look forward to using sonar 1.9.2.

Show
philippe sigaud added a comment - I did find a lot of records. I have no idea how they came to be like this. I tried deleting them but then I got an other error. Something about an unknown column 'depth' in 'field list'. Freddy I'll send you my database directly. I'm confident you'll make it talk. I must say I have no problem with Sonar 1.5.1 so this is a bit strange. Thanks in advance for your help. I really look forward to using sonar 1.9.2.
Hide
philippe sigaud added a comment -

Any idea on what's causing this ?

Show
philippe sigaud added a comment - Any idea on what's causing this ?
Hide
philippe sigaud added a comment -

Ok I still don't know what stopped me from upgrading from 1.5.1 to 1.9.2 directly.

I did manage however to upgrade by doing it step by step from 1.5.1 -> 1.6 -> 1.7 -> 1.8 -> 1.9.2

I recommend people to do the same since it worked for me.

Show
philippe sigaud added a comment - Ok I still don't know what stopped me from upgrading from 1.5.1 to 1.9.2 directly. I did manage however to upgrade by doing it step by step from 1.5.1 -> 1.6 -> 1.7 -> 1.8 -> 1.9.2 I recommend people to do the same since it worked for me.
Hide
Freddy Mallet added a comment -

Thank you Philippe for this feedback.

Show
Freddy Mallet added a comment - Thank you Philippe for this feedback.

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: