| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
| |
This ensures that long URLs don't completely mess up the layout of the
table.
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Sherlock will be a new GitLab specific tool for measuring the
performance of Rails requests (and SideKiq jobs at some point). Some of
the things that are currently tracked:
* SQL queries along with their timings, backtraces and query plans
(using "EXPLAIN ANALYZE" for PostgreSQL and regular "EXPLAIN" for
MySQL)
* Timings of application files (including views) on a per line basis
* Some meta data such as the request method, path, total duration, etc
More tracking (e.g. Rugged or gitlab-shell timings) might be added in
the future.
Sherlock will replace any existing tools we have used so far (e.g.
active_record_query_trace and rack-mini-profiler), hence the
corresponding Gems have been removed from the Gemfile.
Sherlock can be enabled by starting Rails as following:
ENABLE_SHERLOCK=1 bundle exec rails s
Recorded transactions can be found at `/sherlock/transactions`.
|
|\
| |
| |
| |
| |
| |
| | |
Gilab -> GitLab
Replace `Gitlab` with `GitLab`
See merge request !1715
|
| | |
|
|\ \
| |/
|/|
| |
| |
| |
| | |
Fix typo in rake task doc
See merge request !1713
|
| | |
|
|\ \
| |/
|/|
| |
| |
| |
| | |
Fix deadlink in docs for ci/examples
Just fix a deadlink in docs for ci/examples.
See merge request !1710
|
| | |
|
|\ \
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Switch to gitlab-workhorse
This is a little annoying but it is better to change this name then
to be stuck with a bad name for a long time. Reasons for the name
change: https://gitlab.com/gitlab-org/gitlab-git-http-server/issues/13
See merge request !1707
|
| | | |
|
| | | |
|
| | | |
|
|\ \ \
| |_|/
|/| |
| | |
| | |
| | |
| | | |
Improve performance of User.find_by_any_email
See merge request !1698
|
| | |
| | |
| | |
| | |
| | |
| | | |
While these benchmarks run at roughly 1500 i/sec setting the threshold
to 1000 leaves some room for deviations (e.g. due to different DB
setups).
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This further improves performance of User.find_by_any_email and is
roughly twice as fast as the previous UNION setup.
Thanks again to @dlemstra for suggesting this.
|
| | |
| | |
| | |
| | | |
MySQL doesn't support the previous syntax.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This is significantly faster than using a sub-query, at least when run
on the GitLab.com production database. The benchmarks are a lot slower
now with these changes, most likely due to PostgreSQL choosing a
different (and less efficient) plan based on the amount of data present
in the test database.
Thanks to @dlemstra for suggesting the use of a UNION.
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This query used to rely on a JOIN, effectively producing the following
SQL:
SELECT users.*
FROM users
LEFT OUTER JOIN emails ON emails.user_id = users.id
WHERE (users.email = X OR emails.email = X)
LIMIT 1;
The use of a JOIN means having to scan over all Emails and users, join
them together and then filter out the rows that don't match the criteria
(though this step may be taken into account already when joining).
In the new setup this query instead uses a sub-query, producing the
following SQL:
SELECT *
FROM users
WHERE id IN (select user_id FROM emails WHERE email = X)
OR email = X
LIMIT 1;
This query has the benefit that it:
1. Doesn't have to JOIN any rows
2. Only has to operate on a relatively small set of rows from the
"emails" table.
Since most users will only have a handful of Emails associated
(certainly not hundreds or even thousands) the size of the set returned
by the sub-query is small enough that it should not become problematic.
Performance of the old versus new version can be measured using the
following benchmark:
# Save this in ./bench.rb
require 'benchmark/ips'
email = 'yorick@gitlab.com'
def User.find_by_any_email_old(email)
user_table = arel_table
email_table = Email.arel_table
query = user_table.
project(user_table[Arel.star]).
join(email_table, Arel::Nodes::OuterJoin).
on(user_table[:id].eq(email_table[:user_id])).
where(user_table[:email].eq(email).or(email_table[:email].eq(email)))
find_by_sql(query.to_sql).first
end
Benchmark.ips do |bench|
bench.report 'original' do
User.find_by_any_email_old(email)
end
bench.report 'optimized' do
User.find_by_any_email(email)
end
bench.compare!
end
Running this locally using "bundle exec rails r bench.rb" produces the
following output:
Calculating -------------------------------------
original 1.000 i/100ms
optimized 93.000 i/100ms
-------------------------------------------------
original 11.103 (± 0.0%) i/s - 56.000
optimized 948.713 (± 5.3%) i/s - 4.743k
Comparison:
optimized: 948.7 i/s
original: 11.1 i/s - 85.45x slower
In other words, the new setup is 85x faster compared to the old setup,
at least when running this benchmark locally.
For GitLab.com these improvements result in User.find_by_any_email
taking only ~170 ms to run, instead of around 800 ms. While this is
"only" an improvement of about 4.5 times (instead of 85x) it's still
significantly better than before.
Fixes #3242
|
|\ \ \
| |/ /
|/| |
| | |
| | |
| | |
| | | |
Minor ui fixes
See merge request !1704
|
| | |
| | |
| | |
| | | |
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
|
| | |
| | |
| | |
| | | |
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
|
| | |
| | |
| | |
| | | |
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
|
|\ \ \ |
|
| | | | |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Simply type a name with a `/` directory separator and new directories
will be created. This does not do the fancy UI work that github.com
does, but it will get the job done.
I could not find tests for file creation, so I didn't add a test for
this slight behaviour modification. I did test directory traversals
though, using both absolute paths like `/tmp/foo.txt` and relative paths
like `../../foo.txt`. Neither case escaped the repository, though
attempting to traverse with a relative path resulted in a 500 error that
did not affect application stability upon reload.
|
|\ \ \ \
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Force update refs/merge-requests/X/head upon a push to the source branch of a merge request
If a user rebases and does a force push, GitLab would not update the `refs/merge-requests/X/head` link. Using the -f flag forces this to happen.
Closes #3138
See merge request !1683
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
a merge request
Closes #3138
|
|\ \ \ \ \
| |_|/ / /
|/| | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Start putting shared files in "shared"
See merge request !1691
|
| | | | | |
|
| | | | | |
|
| | | | | |
|
| |/ / /
|/| | | |
|
|\ \ \ \
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Add copy paste text for closing down the Github issue tracker
@sytses I think we talked about closing down the Issue tracker on Github. A first step can be closing all the older issues and steering people towards the gitlab.com issue tracker.
What do you think about this text?
See merge request !1689
|
| | | | |
| | | | |
| | | | |
| | | | | |
Signed-off-by: Jeroen van Baarsen <jeroenvanbaarsen@gmail.com>
|
|\ \ \ \ \
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Use issue editor as cross reference comment author when issue is edited with a new mention.
Fixes #3244.
See merge request !1696
|
|\ \ \ \ \ \
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
Bump nprogress-rails to 0.1.6.7
Closes #2866
See merge request !1686
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
Closes #2866
|
|\ \ \ \ \ \ \
| | |/ / / / /
| |/| | | | | |
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
a new mention.
|
|\ \ \ \ \ \ \
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
Remove deprecated CI events from project settings page
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
cc @ayufan
Part of #2594
See merge request !1694
|
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
|
|\ \ \ \ \ \ \ \
| |/ / / / / / /
|/| | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
Fixed the permission doc
The guest users was missing "Pull project code" and "Download project".
/cc @axil
See merge request !1695
|
| | |/ / / / /
| |/| | | | |
| | | | | | |
| | | | | | | |
The guest users was missing "Pull project code" and "Download project".
|
|\ \ \ \ \ \ \
| |_|/ / / / /
|/| | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
Bump gitlab-shell to v2.6.6
See merge request !1673
|