Commit graph

9 commits

Author SHA1 Message Date
Oswaldo Ferreira
00a273d3a9 Revert "Automatically update MR merge-ref along merge status" 2019-06-11 13:08:25 -03:00
Oswaldo Ferreira
b965009ddd Automatically update MR merge-ref along merge status
This couples the code that transitions the `MergeRequest#merge_status`
and refs/merge-requests/:iid/merge ref update.

In general, instead of directly telling `MergeToRefService` to update
the merge ref, we should rely on `MergeabilityCheckService` to keep
both the merge status and merge ref synced. Now, if the merge_status is
`can_be_merged` it means the merge-ref is also updated to the latest.

We've also updated the logic to be more systematic and less user-based.
2019-05-31 19:16:01 -03:00
Shinya Maeda
a7d4824ded Check mergeability in merge to ref service
and add spec

Add changelog

ok

ok
2019-04-01 14:02:57 +07:00
Oswaldo Ferreira
2cb45dd0d5 Provide reliable source and target IDs
Returns the source and target IDs used to create
the merge commit on Gitaly.
2019-03-06 17:49:31 -03:00
Oswaldo Ferreira
959ad992b6 Ref merge does not fail upon FF config enabled 2019-03-06 10:53:55 -03:00
Oswaldo Ferreira
7a8a5fe541 Extend error checking to be overwritten in EE 2019-02-25 10:41:02 -03:00
Oswaldo Ferreira
4e16edbe0a Add feature-flag support
Returns error in MergeToRefService when
merge_to_tmp_merge_ref_path ff is disabled.
2019-02-25 10:41:02 -03:00
Oswaldo Ferreira
105212ce49 Check authorization in merge services
Move authorization checks to merge services
instead relying solely on external checks.
2019-02-25 10:41:01 -03:00
Oswaldo Ferreira
1ad699677f Support merge to ref for merge-commit and squash
Adds the ground work for writing into
the merge ref refs/merge-requests/:iid/merge the
merge result between source and target branches of
a MR, without further side-effects such as
mailing, MR updates and target branch changes.
2019-02-25 10:40:58 -03:00