Commit Graph

3602 Commits

Author SHA1 Message Date
Nick Thomas 94c7a93dca Merge branch 'fix/commits-api-empty-refname' into 'master'
fix handling of empty ref_name parameter string in commits api

Closes #64745

See merge request gitlab-org/gitlab-ce!31687
2019-08-16 14:46:22 +00:00
Douglas Barbosa Alexandre 8c8824d442 Merge branch 'sh-fix-discussions-api-perf' into 'master'
Eliminate many Gitaly calls in discussions API

Closes #65957

See merge request gitlab-org/gitlab-ce!31834
2019-08-15 16:10:14 +00:00
Stan Hu 8044440d7a Eliminate many Gitaly calls in discussions API
Previously, the API to retrieve discussions from merge requests often
generated hundreds of Gitaly calls to determine whether a system note
should be shown to the user. It did this by:

1. Rendering the Markdown
2. Extracting cross-references from the Markdown
3. For cross-references that were commits, a Gitaly FindCommit RPC
   would be issued to validate that the commit exists.

The last step is unnecessary because we don't need to display a commit
if the user doesn't have access to the project in the first place.

`RendersNotes#prepare_notes_for_rendering` is already used in
`MergeRequestsController`, which is why we don't see N+1 Gitaly calls
there. We use it here to optimize the note redaction process.

Closes https://gitlab.com/gitlab-org/gitlab-ce/issues/65957
2019-08-15 08:02:30 -07:00
Stan Hu 0495615502 Merge branch 'fix-broken-ee-master-prepend-todos-api' into 'master'
Adds EE prepend, which for some reason was missing

See merge request gitlab-org/gitlab-ce!31851
2019-08-15 14:41:17 +00:00
Alex Kalderimis 922f21e23d Adds EE prepend, which for some reason was missing 2019-08-15 14:16:29 +01:00
Luke Duncalfe d314052711 Remove prepend_if_ee from CE codebase
This was added in
https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/31789
2019-08-15 21:06:01 +12:00
Luke Duncalfe 88746f5311 CE-specific changes to allow design Todos
CE-specific changes for:
https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/15129

Co-Authored-By:    Alex Kalderimis <akalderimis@gitlab.com>
Co-Authored-By:    Luke Duncalfe <lduncalfe@eml.cc>
2019-08-15 15:08:34 +12:00
Jeremy Jackson 5d9d5e6031 Migrates Snowplow backend from EE to CE
This introduces several changes, but these are all just ported from the
EE project.
2019-08-14 19:21:58 +00:00
Armin Hohenegger 20ac5e6d4b fix handling of empty ref_name parameter string in commits api
when params[:ref_name] is set to "" by passing an empty query parameter
to the api it is evaluated as false by the || operator.
The use of active support core extensions presence method fixes the original
implemantation.

https://guides.rubyonrails.org/active_support_core_extensions.html#presence
2019-08-10 19:11:20 +02:00
Rémy Coutable 39f9f0bdbb Merge branch 'lib-differences' into 'master'
Resolve EE differences in the lib/ directory

See merge request gitlab-org/gitlab-ce!31582
2019-08-09 14:34:45 +00:00
James Lopez bbf639c43d Merge branch '39217-remove-kubernetes-service-integration' into 'master'
Remove KubernetesService integration

See merge request gitlab-org/gitlab-ce!31365
2019-08-09 07:10:26 +00:00
Rémy Coutable 44065b0138 Merge branch 'speed-up-labels-api' into 'master'
Remove label issue and MR counts from default API responses

See merge request gitlab-org/gitlab-ce!31543
2019-08-09 06:25:29 +00:00
Hordur Freyr Yngvason 5f82ff1469 Bring scoped environment variables to core
As decided in https://gitlab.com/gitlab-org/gitlab-ce/issues/53593
2019-08-08 18:51:52 +00:00
Sean McGivern e6dc5168b8 Remove label issue and MR counts from default API responses
These counts significantly increase the load time for these
requests. Users can now opt in to receiving the counts by setting
`with_counts=true` in requests. This is a breaking change, but hopefully
a fairly minor one.
2019-08-08 17:10:41 +01:00
Robert Speicher 79bff3ee7a Merge branch '12026-use-notes-finder-target-for-epics-ce' into 'master'
Use NotesFinder#target to find Epics

See merge request gitlab-org/gitlab-ce!31408
2019-08-08 15:39:13 +00:00
Yorick Peterse 4c53b3945c
Backport EE changes to the project import API
EE added a single line to this file that can easily be backported to CE,
but it appears this was overlooked. The method called is a noop in CE,
so no additional changes are necessary.
2019-08-08 13:34:07 +02:00
Tiger e3696bf20e Final removal of KubernetesService
Creating new records has been disabled, and all
existing records been migrated to clusters as of
https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/28534
2019-08-08 09:47:07 +10:00
Camil Staps 99bb207ef1
Fix tests 2019-08-07 20:49:16 +02:00
Camil Staps e8bdcdf0f8
Expose time since starring on project/:id/starrers API endpoint; exclude private profiles here as well 2019-08-07 20:49:16 +02:00
Camil Staps 1ec8c0e837
Fix API endpoint for starred projects of a user; add info about starred projects on profile to documentation 2019-08-07 20:49:16 +02:00
Camil Staps e7c34c37c8
Add documentation and changelog for !24690 2019-08-07 20:49:15 +02:00
Camil Staps d03a4c9a07
Add users/:user_id/starred_projects API endpoint for projects starred by a user 2019-08-07 20:49:14 +02:00
Camil Staps 5b20df0a92
Add projects/:id/starrers API endpoint for users who starred a repository 2019-08-07 20:49:13 +02:00
Steve Abrams 3dbf3997bb Add group level container repository endpoints
API endpoints for requesting container repositories
and container repositories with their tag information
are enabled for users that want to specify the group
containing the repository rather than the specific project.
2019-08-05 20:00:50 +00:00
Patrick Derichs c69a47049c Use NotesFinder#target to find Epics 2019-08-04 21:04:31 +02:00
George Koltsov 5e3a208f58 Add backwards compatibility for legacy setting
`allow_local_requests_for_hooks_and_services` was renamed to
`allow_local_requests_for_web_hooks_and_services`.
2019-08-02 15:39:18 +01:00
Patrick Derichs 0e99daae4a Use NotesFinder in IssuableActions module
Remove project from NotesFinder constructor

Add project parameter to specs

Also look for methods in private scope

Fix specs to match new NotesFinder constructor
2019-08-01 10:42:42 +02:00
Diego Louzán e20538088b Add support page link in help menu
Creates a new item in help dropdown to show configured support page link
2019-07-30 17:03:17 +00:00
Robert Speicher fe22704a20
Merge branch 'master' of dev.gitlab.org:gitlab/gitlabhq 2019-07-29 13:19:50 -05:00
Stan Hu 914bfabba6 Merge branch 'ce-port-4550-add-project-download-export-audit-event' into 'master'
CE: Add project download & project export audit event

See merge request gitlab-org/gitlab-ce!31103
2019-07-29 13:10:16 +00:00
Nick Thomas 3bb3ac3d53 Merge branch 'add-git-blame-api' into 'master'
Expose git blame in api

Closes #51345

See merge request gitlab-org/gitlab-ce!30675
2019-07-29 11:41:44 +00:00
Oleg Zubchenko 5a8eaef42e Add git blame api 2019-07-26 19:27:32 +03:00
Lin Jen-Shin bd1a5a9f42 Merge branch 'remove-nested-groups-checks' into 'master'
Remove code related to object hierarchy and MySQL

Closes #65056 and #65055

See merge request gitlab-org/gitlab-ce!31095
2019-07-26 14:57:12 +00:00
Robert Speicher 900ef6fc31 Merge branch 'mc/feature/find-all-artifacts-for-sha' into 'master'
Find build by sha from ref

Closes #64534 and #45697

See merge request gitlab-org/gitlab-ce!30843
2019-07-26 14:32:20 +00:00
GitLab Release Tools Bot 890c1421a4 Merge branch 'security-remove-take-trigger-ownership-feature' into 'master'
Drop feature to take ownership of a trigger token

Closes #2868

See merge request gitlab/gitlabhq!3198
2019-07-26 13:41:02 +00:00
Peter Leitzen 8136fac26c Prefer `flat_map` over `map` + `flatten`
Convert several occurrences of `map` + `flatten` to
`flat_map` where applicable.
2019-07-26 10:44:13 +00:00
manojmj 6cfd13726f CE: Add project download & project export audit event
This change adds audit events for
download of repository and export of
project.
2019-07-26 12:25:56 +05:30
Matija Čupić 38ab1ae2f2
Rename latest_successful to be more explicit
* Reword Project#latest_successful_build_for to
Project#latest_successful_build_for_ref
* Reword Ci::Pipeline#latest_successful_for to
Ci::Pipeline#latest_successful_build_for_ref
2019-07-26 00:17:52 +02:00
Heinrich Lee Yu 1ce5bcacdb Remove code related to object hierarchy in MySQL
These are not required because MySQL is not
supported anymore
2019-07-25 15:35:06 +08:00
Nick Thomas 4aa76dddec
Remove dead MySQL code
None of this code can be reached any more, so it can all be removed
2019-07-23 16:53:03 +01:00
Sean McGivern b2e4a7957a Merge branch 'gsemet/gitlab-ce-gsemet-master-patch-33258' into 'master'
Multiple pipeline support for Build status

See merge request gitlab-org/gitlab-ce!30828
2019-07-23 11:57:30 +00:00
Matija Čupić 41b8dca877
Add specs for specifying pipeline behavior
Adds specs for testing the new behavior of specifying a pipeline when
POSTing a status.
2019-07-23 12:02:07 +02:00
Douglas Barbosa Alexandre 0854f18352 Merge branch 'ci_default_git_depth_only' into 'master'
API: Allow changing only ci_default_git_depth

See merge request gitlab-org/gitlab-ce!30888
2019-07-18 12:31:12 +00:00
Nick Thomas 3069cb2545 Merge branch 'webide-commit-use-correct-parent' into 'master'
Use correct parent when committing in WebIDE

See merge request gitlab-org/gitlab-ce!29598
2019-07-18 10:47:35 +00:00
Mathieu Parent 0f585d0de8 API: Allow changing only ci_default_git_depth 2019-07-18 10:18:23 +02:00
Markus Koller f8cecafb07
Add start_sha to commits API
When passing start_branch on committing from the WebIDE, it's possible
that the branch has changed since editing started, which results in the
change being applied on top of the latest commit in the branch and
overwriting the new changes.

By passing the start_sha instead we can make sure that the change is
applied on top of the commit which the user started editing from.
2019-07-18 09:19:18 +02:00
Francisco Javier López bcd2458076 Refactor RedisCounter and WebIdeCommitsCounter
This MR refactor RedisCounter and WebIdeCommitsCounter
to be reused by other components.
2019-07-17 23:45:35 +00:00
Gaetan Semet 4e814c257b
Multiple pipeline support for Build status
This allows user to specify the pipeline ID
when several pipelines has been triggered
on the same branch and commit.

Signed-off-by: Gaetan Semet <gaetan.semet@renault.com>
2019-07-17 14:43:15 +02:00
Imre Farkas 7aa1d17475 CE port of "Move external authorization service API management to EE"
EE MR: https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/14598
2019-07-17 07:20:17 +00:00
Stan Hu f0400dc7c0 Merge branch '12800-read-and-write-user-admin-notes-via-api-ce' into 'master'
CE Backport: Read and write User "Admin notes" via API

See merge request gitlab-org/gitlab-ce!30775
2019-07-16 22:13:26 +00:00