ferblape / query_memcached

A replacement for ActiveRecord query_cache that a adds a Memcache layer for persistence of the query's cache
http://github.com/ferblape/query_memcached/tree
MIT License
65 stars 8 forks source link

issue with postgresql? #1

Open parasew opened 15 years ago

parasew commented 15 years ago

there seems to be an issue with postgresql; my project uses the postgresql gem and when trying to run your query_memcached, it drops an initializing error:

parasew:content-machine parasew$ script/server => Booting Mongrel => Rails 2.3.3 application starting on http://0.0.0.0:3000 /Library/Ruby/Gems/1.8/gems/activesupport-2.3.3/lib/active_support/core_ext/module/aliasing.rb:33:in alias_method': undefined methodexecute' for class ActiveRecord::ConnectionAdapters::MysqlAdapter' (NameError) from /Library/Ruby/Gems/1.8/gems/activesupport-2.3.3/lib/active_support/core_ext/module/aliasing.rb:33:inalias_method_chain' from /Users/parasew/Documents/GIT/content-machine/vendor/plugins/query_memcached/lib/query_memcached.rb:87 from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in gem_original_require' from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:inrequire' from /Library/Ruby/Gems/1.8/gems/activesupport-2.3.3/lib/active_support/dependencies.rb:156:in require' from /Library/Ruby/Gems/1.8/gems/activesupport-2.3.3/lib/active_support/dependencies.rb:521:innew_constants_in' from /Library/Ruby/Gems/1.8/gems/activesupport-2.3.3/lib/active_support/dependencies.rb:156:in require' from /Users/parasew/Documents/GIT/content-machine/vendor/plugins/query_memcached/init.rb:2:inevaluate_init_rb' ... 17 levels... from /Library/Ruby/Gems/1.8/gems/rails-2.3.3/lib/commands/server.rb:84 from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in gem_original_require' from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:inrequire' from script/server:3

parasew commented 15 years ago

update: when removing line 73-89 from query_memcached.rb (the class MysqlAdapter) it works. strage behaviour. maybe you have to explicitly overwrite mysql or postgresql.