微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

尝试使用activerecord-jdbcmysql-adapter时出现“块外收益”

如何解决尝试使用activerecord-jdbcmysql-adapter时出现“块外收益”

| 当我将应用程序部署到glassfish作为战争时,会发生这种情况:
    [#|2011-06-24T17:11:40.903-0500|INFO|glassfish3.1|javax.enterprise.system.container.web.com.sun.enterprise.web|_ThreadID=135;_ThreadName=Thread-1;|PWC1412: WebModule[null] ServletContext.log():/!\\ FAILSAFE /!\\  Fri Jun 24 17:11:40 -0500 2011
  Status: 500 Internal Server Error
  yield called out of block
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/activerecord-jdbc-adapter-1.1.2/lib/arjdbc/jdbc/connection.rb:91:in `tap\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/activerecord-jdbc-adapter-1.1.2/lib/arjdbc/jdbc/connection.rb:91:in `initialize\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/activerecord-jdbc-adapter-1.1.2/lib/arjdbc/jdbc/adapter.rb:31:in `new\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/activerecord-jdbc-adapter-1.1.2/lib/arjdbc/jdbc/adapter.rb:31:in `initialize\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/activerecord-jdbc-adapter-1.1.2/lib/arjdbc/MysqL/adapter.rb:396:in `initialize\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/activerecord-jdbc-adapter-1.1.2/lib/arjdbc/jdbc/connection_methods.rb:6:in `new\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/activerecord-jdbc-adapter-1.1.2/lib/arjdbc/jdbc/connection_methods.rb:6:in `jdbc_connection\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/activerecord-jdbc-adapter-1.1.2/lib/arjdbc/MysqL/connection_methods.rb:18:in `MysqL_connection\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/activerecord-2.3.8/lib/active_record/connection_adapters/abstract/connection_pool.rb:223:in `new_connection\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/activerecord-2.3.8/lib/active_record/connection_adapters/abstract/connection_pool.rb:245:in `checkout_new_connection\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/activerecord-2.3.8/lib/active_record/connection_adapters/abstract/connection_pool.rb:188:in `checkout\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/activerecord-2.3.8/lib/active_record/connection_adapters/abstract/connection_pool.rb:184:in `loop\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/activerecord-2.3.8/lib/active_record/connection_adapters/abstract/connection_pool.rb:184:in `checkout\'
    classpath:/meta-inf/jruby.home/lib/ruby/1.8/monitor.rb:191:in `mon_synchronize\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/activerecord-2.3.8/lib/active_record/connection_adapters/abstract/connection_pool.rb:183:in `checkout\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/activerecord-2.3.8/lib/active_record/connection_adapters/abstract/connection_pool.rb:98:in `connection\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/activerecord-2.3.8/lib/active_record/connection_adapters/abstract/connection_pool.rb:326:in `retrieve_connection\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/activerecord-2.3.8/lib/active_record/connection_adapters/abstract/connection_specification.rb:123:in `retrieve_connection\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/activerecord-2.3.8/lib/active_record/connection_adapters/abstract/connection_specification.rb:115:in `connection\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/activerecord-2.3.8/lib/active_record/query_cache.rb:9:in `cache\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/activerecord-2.3.8/lib/active_record/query_cache.rb:28:in `call\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/activerecord-2.3.8/lib/active_record/connection_adapters/abstract/connection_pool.rb:361:in `call\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/actionpack-2.3.8/lib/action_controller/string_coercion.rb:25:in `call\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/rack-1.1.0/lib/rack/head.rb:9:in `call\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/rack-1.1.0/lib/rack/methodoverride.rb:24:in `call\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/actionpack-2.3.8/lib/action_controller/params_parser.rb:15:in `call\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/actionpack-2.3.8/lib/action_controller/session/cookie_store.rb:99:in `call\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/actionpack-2.3.8/lib/action_controller/failsafe.rb:26:in `call\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/rack-1.1.0/lib/rack/lock.rb:11:in `call\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/actionpack-2.3.8/lib/action_controller/dispatcher.rb:114:in `call\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/actionpack-2.3.8/lib/action_controller/reloader.rb:34:in `run\'
    /home/glassfish/glassfish/domains/domain1/applications/trainer-web/WEB-INF/gems/gems/actionpack-2.3.8/lib/action_controller/dispatcher.rb:108:in `call\'
    classpath:/rack/adapter/rails.rb:36:in `serve_rails\'
    classpath:/rack/adapter/rails.rb:41:in `call\'
    classpath:/jruby/rack/rails.rb:180:in `call\'
    classpath:/rack/handler/servlet.rb:19:in `call\'
    <script>:2
|#]
它在我的本地计算机上的webrick下工作得很好,但是当我尝试将其推广到Qa服务器时,会出现这种情况。想法?     

解决方法

        由于出现意外的Object.tap方法行为而导致的错误,我创建了一个错误报告。     

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。