Commit graph

10 commits

Author SHA1 Message Date
GitLab Bot
e5e0589e09 Add latest changes from gitlab-org/gitlab@master 2021-04-26 12:09:44 +00:00
GitLab Bot
f1a40d0db9 Add latest changes from gitlab-org/gitlab@master 2020-03-09 15:07:45 +00:00
Kamil Trzciński
3a4cb6d675 Bring backward compatibility for request profiles
It seems that we missed the backward compatibility support
for profiles in the existing folder.

This commit also fixes some specs to be idempotent
and work in a temporary directory which not always
seems to be the case.

This commit also brings the profile_spec.rb which seems
to be missing.
2019-07-23 09:30:00 +00:00
Qingyu Zhao
10e51ac5f7 Add profile mode to extend request profiling
Extend the support for "X-Profile-Token: <token>" to have an additional
header that defines type of profile we are looking for, like:
  X-Profile-Mode: execution
  X-Profile-Mode: memory
2019-07-18 23:11:08 +10:00
gfyoung
f93f8f569d Enable even more frozen string for lib/gitlab
Enables frozen string for the following:

* lib/gitlab/patch/**/*.rb
* lib/gitlab/popen/**/*.rb
* lib/gitlab/profiler/**/*.rb
* lib/gitlab/project_authorizations/**/*.rb
* lib/gitlab/prometheus/**/*.rb
* lib/gitlab/query_limiting/**/*.rb
* lib/gitlab/quick_actions/**/*.rb
* lib/gitlab/redis/**/*.rb
* lib/gitlab/request_profiler/**/*.rb
* lib/gitlab/search/**/*.rb
* lib/gitlab/sherlock/**/*.rb
* lib/gitlab/sidekiq_middleware/**/*.rb
* lib/gitlab/slash_commands/**/*.rb
* lib/gitlab/sql/**/*.rb
* lib/gitlab/template/**/*.rb
* lib/gitlab/testing/**/*.rb
* lib/gitlab/utils/**/*.rb
* lib/gitlab/webpack/**/*.rb

Partially addresses gitlab-org/gitlab-ce#47424.
2018-11-19 18:24:22 -08:00
Rémy Coutable
6dcfc4002e Don't require lib/gitlab/request_profiler/middleware.rb in config/initializers/request_profiler.rb
Signed-off-by: Rémy Coutable <remy@rymai.me>
2017-02-02 17:22:10 +01:00
Lin Jen-Shin
ec298011f2 Rails prefers require_dependency so that it won't require twice:
Closes #20724
2016-08-09 06:48:23 +00:00
Ahmad Sherif
0720b9ce00 Catch what warden might throw when profiling requests to re-throw it
Closes #20488
2016-08-01 22:10:04 +02:00
Ahmad Sherif
2e06800bfd Fix RequestProfiler::Middleware error when code is reloaded in development
Closes #20452
2016-08-01 14:26:11 +02:00
Ahmad Sherif
345cd22f21 Profile requests when a header is passed 2016-07-26 20:06:09 +02:00