Commit graph

12 commits

Author SHA1 Message Date
Sean McGivern
db90882665 Only cache MR diffs for one week
This may lead to some being evicted and having to be cached again, but many MRs
get closed or updated in that time anyway.
2018-03-15 11:49:53 +00:00
Sean McGivern
6cd7f679d0 Only cache highlight results for latest MR diffs
Previously, we kept them all in the cache. We don't need the highlight results
for older diffs - if someone does view that (which is rare), we can do the
highlighting on the fly.
2018-03-15 11:49:53 +00:00
Oswaldo Ferreira
ea81c27612 Submit a single batch blob RPC to Gitaly per HTTP request when viewing diffs 2018-03-09 12:36:46 -03:00
Douwe Maan
ffbbd4112e Move diffable? method from Repository to Diff::File 2017-06-08 09:32:57 -05:00
Douwe Maan
7c479d88a9 Pass fallback_diff_refs to Diff::File instead of using view helpers 2017-05-23 15:37:05 -05:00
Sean McGivern
a0979c05fd Show correct size when MR diff overflows
The problem is that we often go via a diff object constructed from the diffs
stored in the DB. Those diffs, by definition, don't overflow, so we don't have
access to the 'correct' `real_size` - that is stored on the MR diff object
iself.
2017-04-25 16:54:10 +01:00
Sean McGivern
1e5e56c698 Fix MR with files hidden by .gitattributes
Don't try to highlight and cache files hidden by .gitattributes entries.
2016-12-26 16:25:55 +00:00
Valery Sizov
f5d7a61760 Fixes ActionView::Template::Error: undefined method text? for nil:NilClass 2016-12-02 14:03:30 +02:00
Valery Sizov
847ada36c4 Fix: Timeout creating and viewing merge request for binary file 2016-11-25 15:25:01 +02:00
Adam Niedzielski
3fa265d195 Fix expanding a collapsed diff when converting a symlink to a regular file
In this case comparing old_path and new_path is not enough because there
are two entires that match.
2016-11-10 18:24:12 +01:00
Adam Niedzielski
317e48193f Fix the diff in the merge request view when converting a symlink to a regular file.
In this specific case using file_path as a cache key is not enough,
because there are two entries with the same path.
Closes #21610.
2016-10-17 18:09:34 +02:00
Dmitriy Zaporozhets
643a368fa4
Make merge request diff works with new FileCollection logic
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2016-08-15 17:57:19 +03:00
Renamed from lib/gitlab/diff/file_collection/merge_request.rb (Browse further)