From a34adcec338b53ccc45827bfc967ceb8a2a9db99 Mon Sep 17 00:00:00 2001 From: Sam Word Date: Wed, 13 Aug 2025 16:06:45 -0400 Subject: [PATCH 1/2] Updated user mapping docs when importing into a personal namespace --- doc/api/group_placeholder_reassignments.md | 8 ++++--- doc/api/import.md | 13 ++++++++--- doc/user/project/import/_index.md | 27 +++++++++++++++++----- 3 files changed, 36 insertions(+), 12 deletions(-) diff --git a/doc/api/group_placeholder_reassignments.md b/doc/api/group_placeholder_reassignments.md index 0960241a157d6b..c5031f74e7538a 100644 --- a/doc/api/group_placeholder_reassignments.md +++ b/doc/api/group_placeholder_reassignments.md @@ -16,6 +16,7 @@ description: "Reassign placeholder users in bulk with the REST API." - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/513794) in GitLab 17.10 [with a flag](../administration/feature_flags/_index.md) named `importer_user_mapping_reassignment_csv`. Enabled by default. - [Generally available](https://gitlab.com/gitlab-org/gitlab/-/issues/478022) in GitLab 18.0. Feature flag `importer_user_mapping_reassignment_csv` removed. +- Reassignment of contributions to personal namespace owner when importing to a personal namespace [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/525342) in GitLab 18.3 [with a flag](../administration/feature_flags/_index.md) named `user_mapping_to_personal_namespace_owner`. Disabled by default. {{< /history >}} @@ -28,9 +29,10 @@ Use the following endpoints to [reassign placeholder users in bulk](../user/proj {{< alert type="note" >}} User contribution mapping is not supported when you import projects to a [personal namespace](../user/namespace/_index.md#types-of-namespaces). -When you import to a personal namespace, all contributions are assigned to -a single non-functional user called `Import User` and they cannot be reassigned. -[Issue 525342](https://gitlab.com/gitlab-org/gitlab/-/issues/525342) proposes to map all contributions to the importing user instead. +When you import to a personal namespace and the `user_mapping_to_personal_namespace_owner` feature flag +is enabled, all contributions are assigned to the personal namespace owner and they cannot be reassigned. +When the `user_mapping_to_personal_namespace_owner` feature flag is disabled, all contributions are +assigned to a single non-functional user called `Import User` and they cannot be reassigned. {{< /alert >}} diff --git a/doc/api/import.md b/doc/api/import.md index 220a32360967ce..c283172a78abde 100644 --- a/doc/api/import.md +++ b/doc/api/import.md @@ -13,14 +13,21 @@ description: "Import repositories from GitHub or Bitbucket Server with the REST {{< /details >}} +{{< history >}} + +- Reassignment of contributions to personal namespace owner when importing to a personal namespace [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/525342) in GitLab 18.3 [with a flag](../administration/feature_flags/_index.md) named `user_mapping_to_personal_namespace_owner`. Disabled by default. + +{{< /history >}} + Use the Import API to import repositories from GitHub or Bitbucket Server. {{< alert type="note" >}} User contribution mapping is not supported when you import projects to a [personal namespace](../user/namespace/_index.md#types-of-namespaces). -When you import to a personal namespace, all contributions are assigned to -a single non-functional user called `Import User` and they cannot be reassigned. -[Issue 525342](https://gitlab.com/gitlab-org/gitlab/-/issues/525342) proposes to map all contributions to the importing user instead. +When you import to a personal namespace and the `user_mapping_to_personal_namespace_owner` feature flag +is enabled, all contributions are assigned to the personal namespace owner and they cannot be reassigned. +When the `user_mapping_to_personal_namespace_owner` feature flag is disabled, all contributions are +assigned to a single non-functional user called `Import User` and they cannot be reassigned. {{< /alert >}} diff --git a/doc/user/project/import/_index.md b/doc/user/project/import/_index.md index d7d460a20d9907..a4ec6934cb751a 100644 --- a/doc/user/project/import/_index.md +++ b/doc/user/project/import/_index.md @@ -108,6 +108,7 @@ difficult, but several tools exist including: - [Enabled on GitLab.com and GitLab Self-Managed](https://gitlab.com/gitlab-org/gitlab/-/issues/472735) in GitLab 17.7 for direct transfer. - Enabled on GitLab.com in GitLab 17.7 for [Bitbucket Server](https://gitlab.com/gitlab-org/gitlab/-/issues/509897), [Gitea](https://gitlab.com/gitlab-org/gitlab/-/issues/498390), and [GitHub](https://gitlab.com/gitlab-org/gitlab/-/issues/499993). - Enabled on GitLab Self-Managed in GitLab 17.8 for [Bitbucket Server](https://gitlab.com/gitlab-org/gitlab/-/issues/509897), [Gitea](https://gitlab.com/gitlab-org/gitlab/-/issues/498390), and [GitHub](https://gitlab.com/gitlab-org/gitlab/-/issues/499993). +- Reassignment of contributions to personal namespace owner when importing to a personal namespace [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/525342) in GitLab 18.3 [with a flag](../../../administration/feature_flags/_index.md) named `user_mapping_to_personal_namespace_owner`. Disabled by default. {{< /history >}} @@ -170,9 +171,10 @@ This feature is meant to prevent accidental reassignment to users outside your o When you use a supported method to import projects to a [personal namespace](../../namespace/_index.md#types-of-namespaces), user contribution mapping is not supported. -When you import to a personal namespace, all contributions are assigned to -a single non-functional user called `Import User` and they cannot be reassigned. -[Issue 525342](https://gitlab.com/gitlab-org/gitlab/-/issues/525342) proposes to map all contributions to the importing user instead. +When you import to a personal namespace and the `user_mapping_to_personal_namespace_owner` feature flag +is enabled, all contributions are assigned to the personal namespace owner and they cannot be reassigned. +When the `user_mapping_to_personal_namespace_owner` feature flag is disabled, all contributions are +assigned to a single non-functional user called `Import User` and they cannot be reassigned. {{< /alert >}} @@ -202,15 +204,28 @@ Placeholder users do not count towards license limits. #### Exceptions +{{< history >}} + +- Reassignment of contributions to personal namespace owner when importing to a personal namespace [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/525342) in GitLab 18.3 [with a flag](../../../administration/feature_flags/_index.md) named `user_mapping_to_personal_namespace_owner`. Disabled by default. + +{{< /history >}} + +{{< alert type="flag" >}} + +The availability of this feature is controlled by a feature flag. +For more information, see the history. + +{{< /alert >}} + A placeholder user is created for each user on the source instance, except in the following scenarios: - You're importing a project from [Gitea](gitea.md), and the user was deleted on Gitea before the import. Contributions from these users are mapped to the user who imported the project, not to a placeholder user. - You have exceeded your [placeholder user limit](#placeholder-user-limits). Contributions from any new users after exceeding your limit are mapped to a single non-functional user called `Import User`. -- You are importing to a [personal namespace](../../namespace/_index.md#types-of-namespaces). - Contributions are assigned to a single non-functional user called `Import User`. - [Issue 525342](https://gitlab.com/gitlab-org/gitlab/-/issues/525342) proposes to map all contributions to the importing user instead. +- You are importing to a [personal namespace](../../namespace/_index.md#types-of-namespaces) and the `user_mapping_to_personal_namespace_owner` feature flag is enabled. + Contributions are assigned to the personal namespace owner. + When the `user_mapping_to_personal_namespace_owner` is disabled, Contributions are assigned to a single non-functional user called `Import User`. #### Placeholder user attributes -- GitLab From 9f7186f11875849acb04168c4defcb77b66a271f Mon Sep 17 00:00:00 2001 From: Sam Word Date: Thu, 14 Aug 2025 18:04:31 +0000 Subject: [PATCH 2/2] Applied docs feedback suggestions --- doc/api/group_placeholder_reassignments.md | 9 ++++++++- doc/api/import.md | 9 ++++++++- doc/user/project/import/_index.md | 21 +++++---------------- 3 files changed, 21 insertions(+), 18 deletions(-) diff --git a/doc/api/group_placeholder_reassignments.md b/doc/api/group_placeholder_reassignments.md index c5031f74e7538a..0ac6880287806d 100644 --- a/doc/api/group_placeholder_reassignments.md +++ b/doc/api/group_placeholder_reassignments.md @@ -16,10 +16,17 @@ description: "Reassign placeholder users in bulk with the REST API." - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/513794) in GitLab 17.10 [with a flag](../administration/feature_flags/_index.md) named `importer_user_mapping_reassignment_csv`. Enabled by default. - [Generally available](https://gitlab.com/gitlab-org/gitlab/-/issues/478022) in GitLab 18.0. Feature flag `importer_user_mapping_reassignment_csv` removed. -- Reassignment of contributions to personal namespace owner when importing to a personal namespace [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/525342) in GitLab 18.3 [with a flag](../administration/feature_flags/_index.md) named `user_mapping_to_personal_namespace_owner`. Disabled by default. +- Reassigning contributions to a personal namespace owner when importing to a personal namespace [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/525342) in GitLab 18.3 [with a flag](../administration/feature_flags/_index.md) named `user_mapping_to_personal_namespace_owner`. Disabled by default. {{< /history >}} +{{< alert type="flag" >}} + +The availability of this feature is controlled by a feature flag. +For more information, see the history. + +{{< /alert >}} + Prerequisites: - You must have the Owner role for the group. diff --git a/doc/api/import.md b/doc/api/import.md index c283172a78abde..75c3b3aa698cb2 100644 --- a/doc/api/import.md +++ b/doc/api/import.md @@ -15,10 +15,17 @@ description: "Import repositories from GitHub or Bitbucket Server with the REST {{< history >}} -- Reassignment of contributions to personal namespace owner when importing to a personal namespace [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/525342) in GitLab 18.3 [with a flag](../administration/feature_flags/_index.md) named `user_mapping_to_personal_namespace_owner`. Disabled by default. +- Reassigning contributions to a personal namespace owner when importing to a personal namespace [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/525342) in GitLab 18.3 [with a flag](../administration/feature_flags/_index.md) named `user_mapping_to_personal_namespace_owner`. Disabled by default. {{< /history >}} +{{< alert type="flag" >}} + +The availability of this feature is controlled by a feature flag. +For more information, see the history. + +{{< /alert >}} + Use the Import API to import repositories from GitHub or Bitbucket Server. {{< alert type="note" >}} diff --git a/doc/user/project/import/_index.md b/doc/user/project/import/_index.md index a4ec6934cb751a..29ed35b4df8248 100644 --- a/doc/user/project/import/_index.md +++ b/doc/user/project/import/_index.md @@ -108,7 +108,7 @@ difficult, but several tools exist including: - [Enabled on GitLab.com and GitLab Self-Managed](https://gitlab.com/gitlab-org/gitlab/-/issues/472735) in GitLab 17.7 for direct transfer. - Enabled on GitLab.com in GitLab 17.7 for [Bitbucket Server](https://gitlab.com/gitlab-org/gitlab/-/issues/509897), [Gitea](https://gitlab.com/gitlab-org/gitlab/-/issues/498390), and [GitHub](https://gitlab.com/gitlab-org/gitlab/-/issues/499993). - Enabled on GitLab Self-Managed in GitLab 17.8 for [Bitbucket Server](https://gitlab.com/gitlab-org/gitlab/-/issues/509897), [Gitea](https://gitlab.com/gitlab-org/gitlab/-/issues/498390), and [GitHub](https://gitlab.com/gitlab-org/gitlab/-/issues/499993). -- Reassignment of contributions to personal namespace owner when importing to a personal namespace [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/525342) in GitLab 18.3 [with a flag](../../../administration/feature_flags/_index.md) named `user_mapping_to_personal_namespace_owner`. Disabled by default. +- Reassigning contributions to a personal namespace owner when importing to a personal namespace [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/525342) in GitLab 18.3 [with a flag](../../../administration/feature_flags/_index.md) named `user_mapping_to_personal_namespace_owner`. Disabled by default. {{< /history >}} @@ -204,28 +204,17 @@ Placeholder users do not count towards license limits. #### Exceptions -{{< history >}} - -- Reassignment of contributions to personal namespace owner when importing to a personal namespace [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/525342) in GitLab 18.3 [with a flag](../../../administration/feature_flags/_index.md) named `user_mapping_to_personal_namespace_owner`. Disabled by default. - -{{< /history >}} - -{{< alert type="flag" >}} - -The availability of this feature is controlled by a feature flag. -For more information, see the history. - -{{< /alert >}} - A placeholder user is created for each user on the source instance, except in the following scenarios: - You're importing a project from [Gitea](gitea.md), and the user was deleted on Gitea before the import. Contributions from these users are mapped to the user who imported the project, not to a placeholder user. - You have exceeded your [placeholder user limit](#placeholder-user-limits). Contributions from any new users after exceeding your limit are mapped to a single non-functional user called `Import User`. -- You are importing to a [personal namespace](../../namespace/_index.md#types-of-namespaces) and the `user_mapping_to_personal_namespace_owner` feature flag is enabled. +- You're importing to a [personal namespace](../../namespace/_index.md#types-of-namespaces) + and the `user_mapping_to_personal_namespace_owner` feature flag is enabled. Contributions are assigned to the personal namespace owner. - When the `user_mapping_to_personal_namespace_owner` is disabled, Contributions are assigned to a single non-functional user called `Import User`. + When the `user_mapping_to_personal_namespace_owner` is disabled, + contributions are assigned to a single non-functional user called `Import User`. #### Placeholder user attributes -- GitLab