New Merge Request causes 500 error: MySQL server has gone away
Created by: nightcoding
Hi there,
after upgrading to the latest version, wie experience issues with new merge requests. If a merge requests has a lot of diffs / changes, a 500 internal server error occurs with the message the mysql server has gone away. Last time this occurs was as we added the bootstrap-sass files to one of our projects.
Detailed log messages:
Started POST "/pim/app/merge_requests" for 123.456.789.1 at 2015-02-24 14:48:41 +0100
Processing by Projects::MergeRequestsController#create as HTML
Parameters: {"utf8"=>"✓", "authenticity_token"=>"XXX", "merge_request"=>{"title"=>"355 compass", "description"=>"* Compass in grunt integriert\r\n* Bootstrap files wieder entfernt", "assignee_id"=>"2", "source_project_id"=>"29", "source_branch"=>"355-compass", "target_project_id"=>"29", "target_branch"=>"master"}, "project_id"=>"pim/app"}
Mysql2::Error: MySQL server has gone away: UPDATE `merge_request_diffs` SET `st_commits` = 'VERY VERY LONG STRING'
Mysql2::Error: closed MySQL connection: ROLLBACK
Completed 500 Internal Server Error in 905ms
ActiveRecord::StatementInvalid (Mysql2::Error: closed MySQL connection: ROLLBACK):
app/services/merge_requests/create_service.rb:10:in `execute'
app/controllers/projects/merge_requests_controller.rb:78:in `create'
Started POST "/pim/app/merge_requests" for 123.456.789.1 at 2015-02-24 15:05:41 +0100
Processing by Projects::MergeRequestsController#create as HTML
Parameters: {"utf8"=>"✓", "authenticity_token"=>"XXX", "merge_request"=>{"title"=>"355 compass", "description"=>"* Compass in grunt integriert\r\n* Bootstrap files wieder entfernt", "assignee_id"=>"2", "source_project_id"=>"29", "source_branch"=>"355-compass", "target_project_id"=>"29", "target_branch"=>"master"}, "project_id"=>"pim/app"}
Mysql2::Error: MySQL server has gone away: UPDATE `merge_request_diffs` SET `st_commits` = 'VERY VERY LONG STRING'
Mysql2::Error: closed MySQL connection: ROLLBACK
Completed 500 Internal Server Error in 700ms
ActiveRecord::StatementInvalid (Mysql2::Error: closed MySQL connection: ROLLBACK):
app/services/merge_requests/create_service.rb:10:in `execute'
app/controllers/projects/merge_requests_controller.rb:78:in `create'
GitLab Version: 7.7.2 OS: CentOS VM MySQL Server: 5.5.23
I did rerun the migrations and restarted the application, did not helped. MergeRequests with minor changes are no problem. Only MR with big changes are causing this error!
Any suggestions?
Thanks a lot.
Martin