Commit graph

19 commits

Author SHA1 Message Date
Stan Hu
3084c37f3e Perform more redactions in Redis performance bar traces
HMSET and AUTH commands were not properly redacted. This commit
does that and adds a test.

Closes https://gitlab.com/gitlab-org/gitlab-ce/issues/64309
2019-07-09 07:21:49 -07:00
Stan Hu
dac8e99ee7 Add Redis call details in Peek performance bar
Since Redis timings appear to be increasing in production, this change
makes it easier to see what exactly which queries are being called and
where.

This is done by prepending modules in peek-redis to store the call
details.

This commit redact values for all SET commands (e.g. HMSET, GETSET,
etc.).
2019-07-02 21:55:34 -07:00
Andrew Newdigate
4f4de36cac Migrate correlation and tracing code to LabKit
This change is a fairly straightforward refactor to extract the tracing
and correlation-id code from the gitlab rails codebase into the new
LabKit-Ruby project.

The corresponding import into LabKit-Ruby was in
https://gitlab.com/gitlab-org/labkit-ruby/merge_requests/1

The code itself remains very similar for now.

Extracting it allows us to reuse it in other projects, such as
Gitaly-Ruby. This will give us the advantages of correlation-ids and
distributed tracing in that project too.
2019-04-18 09:57:16 +02:00
Andrew Newdigate
48bcd5248f Provide a performance bar link to the Jaeger UI
Jaeger is a distributed tracing tool. This change adds a "Tracing" link
to the performance bar to directly link to a current request in Jaeger.

This is useful for two reasons: 1 - it provides affordance to developers
that the distributed tracing tool is available, so that it can quickly
be discovered. 2 - it allows developers to quickly find a specific trace
without having to manually navigate to a second user-interface.
2019-02-08 14:08:31 +02:00
Zeger-Jan van de Weg
5c131dac5e
Fix bug where ID is not set
On HEAD~ we remove the ID from the class, which created a bug. Given we
don't need the ID anymore, it has been removed and simplified.
2018-11-20 13:40:45 +01:00
Sean McGivern
05dd7f9718 Merge branch '52421-show-canary-no-canary-in-the-performance-bar' into 'master'
Resolve "Show canary / no-canary in the performance bar"

Closes #52421

See merge request gitlab-org/gitlab-ce!22222
2018-10-15 07:56:51 +00:00
Sean McGivern
22d6ad7550 Show if the host is a canary host in the perf bar
If the request came from a canary host, show this in the performance bar
by:

1. Adding a bird emoji.
2. Colouring the hostname yellow.
2018-10-12 12:37:18 +01:00
gfyoung
c8755543f0 Enable even more frozen string in lib/**/*.rb
Enables frozen string for the following files:

* lib/generators/**/*.rb
* lib/gitaly/**/*.rb
* lib/google_api/**/*.rb
* lib/haml_lint/**/*.rb
* lib/json_web_token/**/*.rb
* lib/mattermost/**/*.rb
* lib/microsoft_teams/**/*.rb
* lib/object_storage/**/*.rb
* lib/omni_auth/**/*.rb
* lib/peek/**/*.rb
* lib/rouge/**/*.rb
* lib/rspec_flaky/**/*.rb
* lib/system_check/**/*.rb

Partially addresses #47424.
2018-10-08 11:16:49 -07:00
Annabel Gray
4d098451c3 Resolve "Performance bar Gitaly modal is hard to read" 2018-06-14 16:34:58 +00:00
Takuya Noguchi
045e4a9792 Fix UI broken in line profiling modal due to Bootstrap 4 2018-05-31 00:42:00 +09:00
Sean McGivern
a200619d14 Show Ajax requests in performance bar
But first, rewrite the performance bar in Vue:

1. Remove the peek-host gem and replace it with existing code. This also allows
   us to include the host in the JSON response, rather than in the page HTML.
2. Leave the line profiler parts as here-be-dragons: nicer would be a separate
   endpoint for these, so we could use them on Ajax requests too.
3. The performance bar is too fiddly to rewrite right now, so apply the same
   logic to that.

Then, add features! All requests made through Axios are able to be tracked. To
keep a lid on memory usage, only the first two requests for a given URL are
tracked, though. Each request that's tracked has the same data as the initial
page load, with the exception of the performance bar and the line profiler, as
explained above.
2018-03-19 19:06:09 +00:00
Sean McGivern
582447d9ae Capture Gitaly calls that don't go through migrate 2018-03-13 14:09:42 +00:00
Sean McGivern
d30576c5a7 Add Gitaly call details to the performance bar
The same as the SQL queries, show the details of Gitaly calls in the performance
bar, as a modal that can be opened in the same way.
2018-03-13 12:58:00 +00:00
Zeger-Jan van de Weg
5e2a748bb7
Add Gitaly data to the Peek performance bar 2017-10-23 10:14:41 +03:00
Rémy Coutable
18326c2080 Improve & fix the performance bar UI and behavior 2017-07-06 19:37:31 +00:00
Rémy Coutable
be0a949a00 DRYed peek-pg/mysql2 views and update peek-rblineprof monkey-patch file
Signed-off-by: Rémy Coutable <remy@rymai.me>
2017-06-09 17:21:39 +02:00
Rémy Coutable
e859145329 Fix Rubocop offenses, improve SQL duration format and changelog entry
Signed-off-by: Rémy Coutable <remy@rymai.me>
2017-06-09 17:21:39 +02:00
Rémy Coutable
d16a3cf7fc Fix replacement of Pygments with Rouge
Signed-off-by: Rémy Coutable <remy@rymai.me>
2017-06-09 17:21:39 +02:00
Rémy Coutable
47054451da Don't use Pygment,rb, use Rouge instead, and put peek-pg in the :postgres group
Signed-off-by: Rémy Coutable <remy@rymai.me>
2017-06-09 17:21:39 +02:00