Load commit in batches for pipelines#index
Uses `list_commits_by_oid` on the CommitService, to request the needed commits for pipelines. These commits are needed to display the user that created the commit and the commit title. This includes fixes for tests failing that depended on the commit being `nil`. However, now these are batch loaded, this doesn't happen anymore and the commits are an instance of BatchLoader.
显示
- Gemfile 1 个添加, 1 个删除Gemfile
- Gemfile.lock 2 个添加, 2 个删除Gemfile.lock
- app/controllers/projects/pipelines_controller.rb 2 个添加, 0 个删除app/controllers/projects/pipelines_controller.rb
- app/models/ci/pipeline.rb 7 个添加, 6 个删除app/models/ci/pipeline.rb
- app/models/commit.rb 17 个添加, 3 个删除app/models/commit.rb
- app/models/repository.rb 12 个添加, 0 个删除app/models/repository.rb
- app/views/projects/pipelines/_info.html.haml 25 个添加, 25 个删除app/views/projects/pipelines/_info.html.haml
- app/workers/expire_pipeline_cache_worker.rb 1 个添加, 1 个删除app/workers/expire_pipeline_cache_worker.rb
- lib/gitlab/git/commit.rb 13 个添加, 0 个删除lib/gitlab/git/commit.rb
- lib/gitlab/gitaly_client/commit_service.rb 9 个添加, 0 个删除lib/gitlab/gitaly_client/commit_service.rb
- spec/controllers/projects/pipelines_controller_spec.rb 5 个添加, 8 个删除spec/controllers/projects/pipelines_controller_spec.rb
- spec/models/commit_spec.rb 39 个添加, 0 个删除spec/models/commit_spec.rb
- spec/models/repository_spec.rb 48 个添加, 0 个删除spec/models/repository_spec.rb
- spec/serializers/pipeline_serializer_spec.rb 3 个添加, 3 个删除spec/serializers/pipeline_serializer_spec.rb
加载中
想要评论请 注册 或 登录