Commit graph

28 commits

Author SHA1 Message Date
Connor Shea
903946c78a
Replace colorize gem with rainbow.
Colorize is a gem licensed under the GPLv2, so we can’t use it in GitLab without relicensing GitLab under the terms of the GPL. Rainbow is licensed under the MIT license and does the exact same thing as Colorize, so Rainbow was added in place of Colorize.

The syntax is slightly different for Rainbow vs. Colorize, and was updated in accordance.

The gem is still a dependency of Spinach, so it’s included in the development/test environments, but won’t be packaged with the actual product, and therefore doesn’t require we relicense the product.

An attempt at relicensing Colorize was made, but didn’t succeed as the library owner never responded.

Rainbow library: https://github.com/sickill/rainbow
Relevant issue regarding licensing in GitLab's gems: https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/3775
2016-06-03 10:37:09 -06:00
Yorick Peterse
72f428c7d2 Improve performance of User.by_login
Performance is improved in two steps:

1. On PostgreSQL an expression index is used for checking lower(email)
   and lower(username).
2. The check to determine if we're searching for a username or Email is
   moved to Ruby. Thanks to @haynes for suggesting and writing the
   initial implementation of this.

Moving the check to Ruby makes this method an additional 1.5 times
faster compared to doing the check in the SQL query.

With performance being improved I've now also tweaked the amount of
iterations required by the User.by_login benchmark. This method now runs
between 900 and 1000 iterations per second.
2015-10-15 11:58:25 +02:00
Yorick Peterse
c8f18fc562 Added dedicated Rake task for setting up Postgres
This ensures any PostgreSQL specific schema changes (e.g. expression
indexes) are created when setting up the database.
2015-10-08 14:35:36 +02:00
Dmitriy Zaporozhets
b8f12d1917 Replace GITLAB with GitLab in rake task descriptions 2015-06-23 16:52:40 +02:00
Jacob Vosmaer
43e77099d8 Adjust MySQL limits for existing installations 2014-04-23 11:07:36 +02:00
Dmitriy Zaporozhets
46cc3b22c9
Add mysql limits to db during setup
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
2014-03-13 10:47:53 +02:00
Jeroen van Baarsen
f9c4bb5638 Changed limits to a higher order 2014-03-12 08:13:27 +01:00
Jeroen van Baarsen
71b1030bf7 Added rake task to add limits back in mysql 2014-03-11 19:23:02 +01:00
Dmitriy Zaporozhets
3cc26654d5 Remove old migration tasks
You should update to 6.0 before proceed with update to higher version.
So its no reason to keep old tasks any more.
It should be still available in 6-0-stable but not in master
2013-08-26 14:53:36 +03:00
Dmitriy Zaporozhets
625fb2f29d Add iids to milestones. Moved iids logic to separate concern 2013-08-21 12:16:26 +03:00
Dmitriy Zaporozhets
0a44ecf3a0 Fix migrate_iids for issues 2013-08-20 22:41:05 +03:00
Dmitriy Zaporozhets
395f3a1d20 Merge branch 'feature/internal_ids' of /home/git/repositories/gitlab/gitlabhq 2013-08-20 19:30:38 +00:00
Dmitriy Zaporozhets
b66f4898ea Better message for migrating global projects 2013-08-20 12:40:51 +03:00
Dmitriy Zaporozhets
434c034159 Iid improvemets
* call set_iid before validation
* make rake task pass event if objects are invalid
* show iid in comment event at dashboard
2013-08-19 22:53:11 +03:00
Dmitriy Zaporozhets
2e5481b746 Create task to create iid for existing issues/mr 2013-08-19 22:11:18 +03:00
Dmitriy Zaporozhets
af5faaf0e1 Move diff parsing to own class. Correctly identify note diff line 2013-08-04 20:43:49 +03:00
Dmitriy Zaporozhets
2d75b454ef Store diff with line note. It makes possible to see inline notes with proper diff even if MR diff changed 2013-08-04 19:01:57 +03:00
Jacob Vosmaer
1dda34f306 Delete duplicate keys in migrate_keys task 2013-08-02 15:43:30 +02:00
Johannes Schleifenbaum
cd19f82e51 Fix typos 2013-07-29 12:47:06 +02:00
Dmitriy Zaporozhets
113d2ff525 store and display public key fingerprint 2013-06-24 20:07:21 +03:00
Dmitriy Zaporozhets
9de23248d8 You should not be able to remove a Group owner 2013-06-22 11:02:31 +03:00
Dmitriy Zaporozhets
b3ef63a0a5 Migrate global project taks. Removed more teams related functionality 2013-06-19 19:48:48 +03:00
Dmitriy Zaporozhets
cf8b465cb9 Remove Global namespace from options. Prepared file for migration of global projects 2013-06-19 18:32:08 +03:00
baba
320f0ac856 Migrate notes.line_code format.
Since version 4.1, notes.line_code means:
  {SHA1 hash of file path}_{old line}_{new line}
but the older version means:
  {file index of the commit}_{old line}_{new line}

This rake task migrate the above differences.
2013-05-11 16:53:07 +09:00
Dmitriy Zaporozhets
0715abaf24 migrate milestones with nil state 2013-04-16 20:00:30 +03:00
Dmitriy Zaporozhets
771b5c2298 Warn user about losing merge request diff 2013-04-15 19:33:44 +03:00
Dmitriy Zaporozhets
0415566b37 Remove wiki migrator. We dont need it any more. Users should migrate to 5.0 first 2013-04-10 20:48:21 +03:00
Dmitriy Zaporozhets
0da5a4fab1 separate rake task for migration and persistent one 2013-04-05 20:44:16 +03:00