summaryrefslogtreecommitdiff
path: root/lib/gitlab
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch 'simplify-gitlab-url_builder-15202' into 'master' Rémy Coutable2016-04-142-35/+42
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Refactor and expose only Gitlab::UrlBuilder.build(record) ``` $ git grep Gitlab::UrlBuilder app/models/commit.rb: url: Gitlab::UrlBuilder.build(self), app/services/issues/base_service.rb: issue_url = Gitlab::UrlBuilder.build(issue) app/services/merge_requests/base_service.rb: hook_data[:object_attributes][:url] = Gitlab::UrlBuilder.build(merge_request) app/views/search/results/_note.html.haml:- note_url = Gitlab::UrlBuilder.build(note) lib/gitlab/note_data_builder.rb: base_data[:object_attributes][:url] = Gitlab::UrlBuilder.build(note) spec/lib/gitlab/note_data_builder_spec.rb: expect(data[:object_attributes][:url]).to eq(Gitlab::UrlBuilder.build(note)) spec/lib/gitlab/url_builder_spec.rb:describe Gitlab::UrlBuilder, lib: true do ``` Fixes #15202. See merge request !3696
| * Refactor and expose only Gitlab::UrlBuilder.build(record)simplify-gitlab-url_builder-15202Rémy Coutable2016-04-132-35/+42
| | | | | | | | Signed-off-by: Rémy Coutable <remy@rymai.me>
* | Merge branch 'redis_config_consistency' into 'master' Valery Sizov2016-04-131-0/+2
|\ \ | | | | | | | | | | | | | | | | | | Redis configuration consistency Related https://gitlab.com/gitlab-org/gitlab-ce/commit/cf669551f69edd66913d22c96cf1de1302e7990e See merge request !3697
| * | Redis configuration consistencyredis_config_consistencyValery Sizov2016-04-131-0/+2
| | |
* | | Merge branch 'redis_improvements' into 'master' Robert Speicher2016-04-131-5/+0
|\ \ \ | | | | | | | | | | | | | | | | Clean up ExclusiveLease See merge request !3695
| * | | clean up ExclusiveLeaseredis_improvementsValery Sizov2016-04-131-5/+0
| |/ /
* | | Merge branch 'external-omniauth-providers' into 'master' Marin Jankovski2016-04-131-0/+10
|\ \ \ | |_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Allow Omniauth providers to be marked as external Related to #4009 With this MR we will be able to allow the user to set which Omniauth Providers they would like to have as external. All users login in via these providers will be marked as external, even if they already had an account before. If the provider is removed form the list of external providers, the users will be marked as internal at their next login. MR for Omnibus: gitlab-org/omnibus-gitlab!727 /cc @dblessing @DouweM See merge request !3657
| * | Better control flow.external-omniauth-providersPatricio Cano2016-04-111-6/+4
| | |
| * | Allow `external_providers` for Omniauth to be defined to mark these users as ↵Patricio Cano2016-04-111-0/+12
| |/ | | | | | | external
* | Added ability to add custom tags to transactionsYorick Peterse2016-04-131-0/+10
| | | | | | | | | | | | | | One use case for this is manually setting the "action" tag for Grape API calls. Due to Grape running blocks there are no human readable method names that can be used for the "action" tag, thus we have to set these manually on a case by case basis.
* | Merge branch 'fix-missing-saml-error-handling' into 'master' Robert Speicher2016-04-121-1/+2
|\ \ | |/ |/| | | | | | | | | | | | | Add proper nil and error handling to SAML login process While writing the feature that would allow certain Omniauth providers to be marked as external I noticed that there is a scenario where the `gl_user` method can return `nil` and if this is not properly checked, it will lead to exceptions that will cause 500 errors. It is quite easy to land in this scenario, so I added `nil` checks. I also noticed that the `saml` method in the `omniauth_callbacks_controller.rb` file lacked a `rescue` for `Gitlab::OAuth::SignupDisabledError`, which can happen if the default configuration from `1_settings.rb` is applied. So I also added this check. See merge request !3609
| * Better control flow and added guard clause.fix-missing-saml-error-handlingPatricio Cano2016-04-111-14/+9
| |
| * Add missing proper nil and error handling to SAML login process.Patricio Cano2016-04-071-8/+14
| |
* | Fixed stubbing for Gitlab::Metrics specsYorick Peterse2016-04-111-4/+12
| | | | | | | | | | | | If the measure method uses Transaction.current directly the SQL subscriber (Subscribers::ActiveRecord) will add timings of queries triggered by DB cleaner.
* | Track call counts in Gitlab::Metrics.measure_blockmetrics-measure-block-transactionYorick Peterse2016-04-111-0/+1
| |
* | Store block timings as transaction valuesYorick Peterse2016-04-112-9/+25
| | | | | | | | | | | | | | | | | | | | This makes it easier to query, simplifies the code, and makes it possible to figure out what transaction the data belongs to (simply because it's now stored _in_ the transaction). This new setup keeps track of both the real/wall time _and_ CPU time spent in a block, both measured using milliseconds (to keep all units the same).
* | Merge branch 'redis-connection-pool' into 'master' Robert Speicher2016-04-083-31/+51
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Redis connection pool Split from https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/3232 Having an easily accessible Redis connection pool allows us to do more cool stuff with Redis in GitLab (instead of having to go through e.g. the Rails cache). See merge request !3521
| * | Put CACHE_NAMESPACE in the Gitlab::Redis moduleJacob Vosmaer2016-04-071-0/+2
| | |
| * | Be careful when setting class instance varsJacob Vosmaer2016-04-041-2/+13
| | |
| * | Add Gitlab::Redis connection poolJacob Vosmaer2016-04-042-4/+11
| | |
* | | Merge branch 'instrument-rails-cache' into 'master' Yorick Peterse2016-04-081-0/+39
|\ \ \ | | | | | | | | | | | | | | | | Instrument Rails cache code See merge request !3619
| * | | Instrument Rails cache codeinstrument-rails-cacheYorick Peterse2016-04-081-0/+39
| | |/ | |/| | | | | | | | | | This allows us to track how much time of a transaction is spent in dealing with cached data.
* | | Use more accurate timestamps for InfluxDB.metrics-timestamp-precisionYorick Peterse2016-04-081-1/+21
|/ / | | | | | | | | | | | | | | | | This changes the timestamp of metrics to be more accurate/unique by using Time#to_f combined with a small random jitter value. This combination hopefully reduces the amount of collisions, though there's no way to fully prevent any from occurring. Fixes gitlab-com/operations#175
* | Merge branch 'feature/expose-builds-badge' into 'master' Rémy Coutable2016-04-071-4/+26
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Expose badges This MR exposes badge somewhere in visible place. ![expose_badges](/uploads/d2e290d3013d1ef2b1bdeebbbe2c5d8b/expose_badges.png) Closes #13801 See merge request !3326
| * | Extend build status badge, add html/markdown methodsGrzegorz Bizon2016-04-061-4/+26
| | |
* | | Merge branch 'saml-external-groups' into 'master' Robert Speicher2016-04-073-2/+64
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Allow SAML to identify external users and set them as such Related to #4009 Fixes #14577 This allows SAML to retrieve group information form the `SAML Response` and match that to a setting that will flag all matching users as external. See merge request !3530
| * | | Implemented suggested fixesPatricio Cano2016-04-063-6/+4
| | | |
| * | | Added CHANGELOG itemsaml-external-groupsPatricio Cano2016-04-061-1/+0
| | | |
| * | | Fix error that was causing only one group to be returned and corrected specs ↵Patricio Cano2016-04-061-1/+3
| | | | | | | | | | | | | | | | to use the proper attribute type
| * | | Changed config syntax and improved how chaanges in group memberships are ↵Patricio Cano2016-04-052-29/+14
| | | | | | | | | | | | | | | | handled when external groups is set up
| * | | Prepare SAML for group retrievalPatricio Cano2016-04-043-2/+80
| | |/ | |/|
* | | Merge branch 'patch/fix-ldap-unblock-user-logic' into 'master' Robert Speicher2016-04-061-1/+4
|\ \ \ | |_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | Unblocks user when active_directory is disabled and it can be found We implemented a specific block state to handle user blocking that originates from LDAP filtering rules / directory state in !2242. That introduced a regression in LDAP authentication when Active Directory support was disabled. You could have a scenario where the user would not be temporarily found (like a filtering rule), that would mark the user as `ldap_blocked`, but will never unblock it automatically when that state changed. Fixes #14253, #13179, #13259, #13959 See merge request !3550
| * | Unblocks user when active_directory is disabled and it can be foundpatch/fix-ldap-unblock-user-logicGabriel Mazetto2016-04-051-1/+4
| | |
* | | Measure Ruby blocks using Gitlab::MetricsYorick Peterse2016-04-061-0/+26
| |/ |/| | | | | | | | | This allows measuring of timings of arbitrary Ruby blocks, this allows for more fine grained performance monitoring. Custom values and tags can also be attached to a block.
* | Merge branch 'routing' into 'master' Robert Speicher2016-04-013-2/+15
|\ \ | | | | | | | | | | | | | | | | | | Added & use Gitlab::Routing for URL helpers Extracted from !3389 See merge request !3486
| * | Added & use Gitlab::Routing for URL helpersroutingYorick Peterse2016-04-013-2/+15
| | | | | | | | | | | | | | | | | | | | | Rails' "url_helpers" method creates an anonymous Module (which a bunch of methods) on every call. By caching the output of this method in a dedicated method we can shave off about 10 seconds of loading time for an issue with around 200 comments.
* | | Merge branch 'fix/fogbugz-import' into 'master' Robert Speicher2016-04-011-1/+1
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | spec and fix for fogbugz lonely user problem Fixes https://gitlab.com/gitlab-org/gitlab-ce/issues/14766 I encountered this issue while manually testing all import types for https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/3066 This is really due to a horrible API ``` { 'people' => { 'person' => array_of_people_or_single_person_as_hash } } ``` See merge request !3457
| * | | spec and fix for fogbugz lonely user problemJames Lopez2016-03-301-1/+1
| | | |
* | | | Merge branch ↵Douwe Maan2016-04-012-9/+7
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 'snippets-with-comments-cause-a-500-when-they-show-up-in-search-results-14764' into 'master' Fix Error 500 when searching for a comment in a project snippet Closes #14764. /cc @stanhu, and thank you for the spec! ;) See merge request !3468
| * | | | Fix view of notes in search results when noteable is a snippetsnippets-with-comments-cause-a-500-when-they-show-up-in-search-results-14764Rémy Coutable2016-03-311-7/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Also, streamline the view. Signed-off-by: Rémy Coutable <remy@rymai.me>
| * | | | Rename Note#for_project_snippet? to #for_snippet?Rémy Coutable2016-03-312-2/+2
| | |/ / | |/| | | | | | | | | | Signed-off-by: Rémy Coutable <remy@rymai.me>
* | | | Merge branch 'fix/issue-move-rewrite-uploads' into 'master' Douwe Maan2016-04-012-2/+58
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Rewrite uploads when moving issue to another project Closes #14531 See merge request !3382
| * \ \ \ Merge branch 'master' into fix/issue-move-rewrite-uploadsGrzegorz Bizon2016-03-313-6/+49
| |\ \ \ \ | | |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * master: (27 commits) Fix commit comment alignment minor cleanup in system_hook_spec Pre-calculate Emoji digests Clear .todo listener Change window.location to use turbolinks Make entire todo row clickable Add 8.6.2 CHANGELOG items Ensure uploads dir exists when running backup specs Move CarrierWave test env config to separate file Remove console logs Off the event initially Collapsed sidebar opens over instead of pushing content. Sidebar collapse update issue User selection from collapsed sidebar Add json response for user avatar in merge request Make changed values visible in minimized sidebar. Fixed MergeRequestController spec We need `sha` reference from `diff_base_commit` to generate the diff Use `diff_base_commit` instead of `target_branch` to generate diffs Isolate CarrierWave uploads in test enviroment ...
| * | | | Remove reduntant `move_to_store` overrideGrzegorz Bizon2016-03-301-8/+2
| | | | |
| * | | | Add method that returns markdown in file uploaderGrzegorz Bizon2016-03-302-2/+2
| | | | |
| * | | | Check if GFM rewriters need rewrite internallyGrzegorz Bizon2016-03-302-1/+3
| | | | |
| * | | | Refactor uploads rewriter used when moving issueGrzegorz Bizon2016-03-302-13/+17
| | | | |
| * | | | Add uploads rewriter and use it when moving issueGrzegorz Bizon2016-03-301-0/+56
| | |_|/ | |/| |
* | | | Remove "Congratulations!" tweet button on newly-created project.connorshea2016-03-311-1/+0
| |/ / |/| | | | | | | | | | | | | | | | | I’ve removed everything related to the feature based on this commit: ce08f919f34fd8849834365 Resolves #10857.
* | | Merge branch '2364-fallback-to-in-reply-to-header' into 'master' Douwe Maan2016-03-302-6/+25
|\ \ \ | |_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fall back to In-Reply-To and References headers when sub-addressing is not available _Originally opened at !3024 by @dabit._ - - - Fixes #2364 Summary of the changes: - No more need to have the `%{key}` placeholder in the `incoming_email.address` - The fallback message id format is `reply-[key]@[gitlab_host]` (reminder: it doesn't have to be a real email address) - The fallback message id that includes the reply key is added to both `References` header - Documentation for the "Reply by email" feature updated See merge request !3305