Redmine Mylyn Connector Plugin (/redmine/mylyn/queries error 500)
Added by Romeo R about 11 years ago
Hi All!
Environment:
Redmine version 2.4.0.stable
Ruby version 1.9.3-p231 (2012-05-25) [i386-mingw32]
Rails version 3.2.15
Environment production
Database adapter Mysql2
SCM:
Subversion 1.7.9
Git 1.8.3
Filesystem
Redmine plugins:
redmine_mylyn_connector 2.8.2.stable
Also using Eclipse Mylyn Redmine 0.3.7.201203072118
In Eclipse:
1. Create Remote Task Repository - OK;
2. Sync Queries - Error 500..
Redmine Apache logs
192.168.0.224 - - [27/Nov/2013:16:41:54 +0300] "GET /redmine/mylyn/version HTTP/1.1" 200 289 192.168.0.224 - - [27/Nov/2013:16:42:04 +0300] "GET /redmine/mylyn/customfields HTTP/1.1" 200 1044 192.168.0.224 - - [27/Nov/2013:16:42:05 +0300] "GET /redmine/mylyn/trackers HTTP/1.1" 200 1977 192.168.0.224 - - [27/Nov/2013:16:42:05 +0300] "GET /redmine/mylyn/queries HTTP/1.1" 500 674 192.168.0.224 - - [27/Nov/2013:16:42:08 +0300] "GET /redmine/mylyn/customfields HTTP/1.1" 200 1044 192.168.0.224 - - [27/Nov/2013:16:42:08 +0300] "GET /redmine/mylyn/trackers HTTP/1.1" 200 1977 192.168.0.224 - - [27/Nov/2013:16:42:08 +0300] "GET /redmine/mylyn/queries HTTP/1.1" 500 674
So there's no url /redmine/mylyn/queries
How fix it?
Replies (3)
RE: Redmine Mylyn Connector Plugin (/redmine/mylyn/queries error 500) - Added by Anonymous about 11 years ago
Im not 100% sure if this fix is correct but it seems with 2.4.0 the "is_public" field in die queries table has been replaced with the "visibility" field.
i fixed the redmin_mylyn_connector on my redmine by changeing following lines:
File: redmine/plugins/redmine_mylyn_connector/app/controllers/mylyn_connector/queries_controller.rb
Line: 15
Old:
:conditions => ["(#{Query.table_name}.is_public = ? OR #{Query.table_name}.user_id = ?) AND (project_id IS NULL OR " << Project.visible_condition(User.current) << ")", true, User.current.id],
New:
:conditions => ["(#{Query.table_name}.visibility = ? OR #{Query.table_name}.user_id = ?) AND (project_id IS NULL OR " << Project.visible_condition(User.current) << ")", 2, User.current.id],
everything works as aspected then.
so the is_public will be replaced with visibility and the true will be replace with a 2
see source:trunk/app/models/query.rb
cause im not 100% sure if the repository of redmine_mylyn_connector is still maintained i wont provied a patch.
RE: Redmine Mylyn Connector Plugin (/redmine/mylyn/queries error 500) - Added by Romeo R about 11 years ago
Thanks, solved
RE: Redmine Mylyn Connector Plugin (/redmine/mylyn/queries error 500) - Added by Seungyoon Lee about 10 years ago
Helpful! Thanks!