diff options
author | Igor <idrozdov@gitlab.com> | 2019-08-10 00:01:55 +0300 |
---|---|---|
committer | Douwe Maan <douwe@gitlab.com> | 2019-08-10 00:01:55 +0300 |
commit | b99011af62935de0b15e8a314ffb7df1f8a3f303 (patch) | |
tree | f19bc1052fa1cd903a31d6f01489b56ec2bb7ead /lib | |
parent | 43b9be9d6cf59a02ea86795a1734848615d38a26 (diff) |
Split MR widget into cached and non-cached serializers
Splits auto-refreshing of MR widget into 2 requests:
- the one which uses etag-caching and invalidates the fields on change
- the one without caching
The idea is to gradually move all the fields to etag-cached endpoint
Diffstat (limited to 'lib')
-rw-r--r-- | lib/gitlab/etag_caching/router.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/gitlab/etag_caching/router.rb b/lib/gitlab/etag_caching/router.rb index 17fbecbd097..d09dcdbb337 100644 --- a/lib/gitlab/etag_caching/router.rb +++ b/lib/gitlab/etag_caching/router.rb @@ -61,6 +61,10 @@ module Gitlab Gitlab::EtagCaching::Router::Route.new( %r(#{RESERVED_WORDS_PREFIX}/import/gitea/realtime_changes\.json\z), 'realtime_changes_import_gitea' + ), + Gitlab::EtagCaching::Router::Route.new( + %r(#{RESERVED_WORDS_PREFIX}/merge_requests/\d+/cached_widget\.json\z), + 'merge_request_widget' ) ].freeze |