Merge branch 'huge-repo-improve' into 'master'
Better support for huge repositories This MR contains next improvements to GitLab: * You can see repo commits count even if it is > 100k commits * Prevent 500 for commit page for large repos * Add notice about huge push over http to unicorn config * File action in satellites uses default 30 seconds timeout instead of old 10 seconds one * Show spinner when loading data for network graph
This commit is contained in:
commit
9fd6c3d591
|
@ -26,6 +26,11 @@ v 7.0.0
|
|||
- UI improvements for mobile devices
|
||||
- Improve diff rendering performance
|
||||
- Drag-n-drop for issues and merge requests between states at milestone page
|
||||
- Fix '0 commits' message for huge repositories on project home page
|
||||
- Prevent 500 error page when visit commit page from large repo
|
||||
- Add notice about huge push over http to unicorn config
|
||||
- File action in satellites uses default 30 seconds timeout instead of old 10 seconds one
|
||||
- Overall performance improvements
|
||||
|
||||
v 6.9.2
|
||||
- Revert the commit that broke the LDAP user filter
|
||||
|
@ -790,4 +795,4 @@ v 0.8.0
|
|||
- stability
|
||||
- security fixes
|
||||
- increased test coverage
|
||||
- email notification
|
||||
- email notification
|
||||
|
|
2
Gemfile
2
Gemfile
|
@ -30,7 +30,7 @@ gem 'omniauth-github'
|
|||
|
||||
# Extracting information from a git repository
|
||||
# Provide access to Gitlab::Git library
|
||||
gem "gitlab_git", '~> 5.8'
|
||||
gem "gitlab_git", '~> 6.0'
|
||||
|
||||
# Ruby/Rack Git Smart-HTTP Server Handler
|
||||
gem 'gitlab-grack', '~> 2.0.0.pre', require: 'grack'
|
||||
|
|
|
@ -175,7 +175,7 @@ GEM
|
|||
mime-types (~> 1.19)
|
||||
gitlab_emoji (0.0.1.1)
|
||||
emoji (~> 1.0.1)
|
||||
gitlab_git (5.9.0)
|
||||
gitlab_git (6.0.0)
|
||||
activesupport (~> 4.0)
|
||||
charlock_holmes (~> 0.6)
|
||||
gitlab-grit (~> 2.6)
|
||||
|
@ -601,7 +601,7 @@ DEPENDENCIES
|
|||
gitlab-grack (~> 2.0.0.pre)
|
||||
gitlab-linguist (~> 3.0.0)
|
||||
gitlab_emoji (~> 0.0.1.1)
|
||||
gitlab_git (~> 5.8)
|
||||
gitlab_git (~> 6.0)
|
||||
gitlab_meta (= 6.0)
|
||||
gitlab_omniauth-ldap (= 1.0.4)
|
||||
gollum-lib (~> 3.0.0)
|
||||
|
|
|
@ -12,7 +12,12 @@ class Projects::CommitController < Projects::ApplicationController
|
|||
return git_not_found! unless @commit
|
||||
|
||||
@line_notes = project.notes.for_commit_id(commit.id).inline
|
||||
@branches = project.repository.branch_names_contains(commit.id)
|
||||
|
||||
@branches = begin
|
||||
project.repository.branch_names_contains(commit.id)
|
||||
rescue Grit::Git::GitTimeout
|
||||
[]
|
||||
end
|
||||
|
||||
begin
|
||||
@suppress_diff = true if commit.diff_suppress? && !params[:force_show_diff]
|
||||
|
|
|
@ -226,8 +226,11 @@ module ApplicationHelper
|
|||
GitHub::Markup.render(file_name, file_content).html_safe
|
||||
end
|
||||
|
||||
def spinner(text = nil)
|
||||
content_tag :div, class: 'loading hide' do
|
||||
def spinner(text = nil, visible = false)
|
||||
css_class = "loading"
|
||||
css_class << " hide" unless visible
|
||||
|
||||
content_tag :div, class: css_class do
|
||||
content_tag(:i, nil, class: 'icon-spinner icon-spin') + text
|
||||
end
|
||||
end
|
||||
|
|
|
@ -106,7 +106,7 @@ class Repository
|
|||
def commit_count
|
||||
Rails.cache.fetch(cache_key(:commit_count)) do
|
||||
begin
|
||||
raw_repository.raw.commit_count(self.root_ref)
|
||||
raw_repository.commit_count(self.root_ref)
|
||||
rescue
|
||||
0
|
||||
end
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
.tip
|
||||
You can move around the graph by using the arrow keys.
|
||||
.network-graph
|
||||
= spinner
|
||||
= spinner nil, true
|
||||
|
||||
:javascript
|
||||
new Network({
|
||||
|
|
|
@ -34,6 +34,20 @@ listen "/home/git/gitlab/tmp/sockets/gitlab.socket", :backlog => 64
|
|||
listen "127.0.0.1:8080", :tcp_nopush => true
|
||||
|
||||
# nuke workers after 30 seconds instead of 60 seconds (the default)
|
||||
#
|
||||
# NOTICE: git push over http depends on this value.
|
||||
# If you want be able to push huge amount of data to git repository over http
|
||||
# you will have to increase this value too.
|
||||
#
|
||||
# Example of output if you try to push 1GB repo to GitLab over http.
|
||||
# -> git push http://gitlab.... master
|
||||
#
|
||||
# error: RPC failed; result=18, HTTP code = 200
|
||||
# fatal: The remote end hung up unexpectedly
|
||||
# fatal: The remote end hung up unexpectedly
|
||||
#
|
||||
# For more information see http://stackoverflow.com/a/21682112/752049
|
||||
#
|
||||
timeout 30
|
||||
|
||||
# feel free to point this anywhere accessible on the filesystem
|
||||
|
|
|
@ -4,7 +4,7 @@ module Gitlab
|
|||
attr_accessor :file_path, :ref
|
||||
|
||||
def initialize(user, project, ref, file_path)
|
||||
super user, project, git_timeout: 10.seconds
|
||||
super user, project
|
||||
@file_path = file_path
|
||||
@ref = ref
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue