diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-11-25 12:07:43 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-11-25 12:07:43 +0300 |
commit | f15cf65c53f00e5d3a8bad666a95c076c0e4e262 (patch) | |
tree | 8197fd9c4a18adb3f5636f728c4666cf140d65dc | |
parent | 03085fd4a4047d7e7a11e29e244b7bfccfe52f53 (diff) |
Add latest changes from gitlab-org/gitlab@master
67 files changed, 178 insertions, 133 deletions
diff --git a/.rubocop_todo/layout/line_length.yml b/.rubocop_todo/layout/line_length.yml index 919d025b10e..ffc3ff3f6ec 100644 --- a/.rubocop_todo/layout/line_length.yml +++ b/.rubocop_todo/layout/line_length.yml @@ -1874,7 +1874,6 @@ Layout/LineLength: - 'ee/spec/finders/ee/group_members_finder_spec.rb' - 'ee/spec/finders/ee/projects_finder_spec.rb' - 'ee/spec/finders/epics_finder_spec.rb' - - 'ee/spec/finders/geo/container_repository_legacy_registry_finder_spec.rb' - 'ee/spec/finders/geo/project_registry_finder_spec.rb' - 'ee/spec/finders/geo/project_registry_status_finder_spec.rb' - 'ee/spec/finders/group_projects_finder_spec.rb' diff --git a/.rubocop_todo/rails/pluck.yml b/.rubocop_todo/rails/pluck.yml index d1c7192775f..d9f9f2e571b 100644 --- a/.rubocop_todo/rails/pluck.yml +++ b/.rubocop_todo/rails/pluck.yml @@ -24,7 +24,6 @@ Rails/Pluck: - 'ee/app/models/boards/epic_list.rb' - 'ee/app/models/concerns/geo/verification_state.rb' - 'ee/app/services/concerns/incident_management/oncall_rotations/shared_rotation_logic.rb' - - 'ee/app/workers/geo/container_repository_sync_dispatch_worker.rb' - 'ee/app/workers/geo/registry_sync_worker.rb' - 'ee/app/workers/geo/repository_shard_sync_worker.rb' - 'ee/app/workers/geo/repository_verification/secondary/shard_worker.rb' diff --git a/.rubocop_todo/rails/time_zone.yml b/.rubocop_todo/rails/time_zone.yml index f1e7d519a8f..6b7533d44d8 100644 --- a/.rubocop_todo/rails/time_zone.yml +++ b/.rubocop_todo/rails/time_zone.yml @@ -22,7 +22,6 @@ Rails/TimeZone: - ee/spec/lib/gitlab/elastic/client_spec.rb - ee/spec/lib/gitlab/geo/base_request_spec.rb - ee/spec/lib/gitlab/geo/log_cursor/events/cache_invalidation_event_spec.rb - - ee/spec/lib/gitlab/geo/log_cursor/events/container_repository_updated_event_spec.rb - ee/spec/lib/gitlab/geo/log_cursor/events/design_repository_updated_event_spec.rb - ee/spec/lib/gitlab/geo/log_cursor/events/event_spec.rb - ee/spec/lib/gitlab/geo/log_cursor/events/hashed_storage_attachments_event_spec.rb diff --git a/.rubocop_todo/style/hash_as_last_array_item.yml b/.rubocop_todo/style/hash_as_last_array_item.yml index aa22e9ed82b..6c4309cd6c4 100644 --- a/.rubocop_todo/style/hash_as_last_array_item.yml +++ b/.rubocop_todo/style/hash_as_last_array_item.yml @@ -43,7 +43,6 @@ Style/HashAsLastArrayItem: - 'ee/app/serializers/dashboard_environments_serializer.rb' - 'ee/spec/finders/projects/integrations/jira/by_ids_finder_spec.rb' - 'ee/spec/lib/ee/gitlab/ci/config/entry/needs_spec.rb' - - 'ee/spec/lib/gitlab/geo/log_cursor/events/container_repository_updated_event_spec.rb' - 'ee/spec/lib/gitlab/geo/log_cursor/events/design_repository_updated_event_spec.rb' - 'ee/spec/models/ee/ci/job_artifact_spec.rb' - 'lib/api/entities/project.rb' diff --git a/app/models/application_setting.rb b/app/models/application_setting.rb index adbbddd635c..797e2632d84 100644 --- a/app/models/application_setting.rb +++ b/app/models/application_setting.rb @@ -412,12 +412,10 @@ class ApplicationSetting < ApplicationRecord allow_nil: false, inclusion: { in: [true, false], message: N_('must be a boolean value') } - # rubocop:disable Cop/StaticTranslationDefinition validates :deactivate_dormant_users_period, presence: true, - numericality: { only_integer: true, greater_than_or_equal_to: 90, message: _("'%{value}' days of inactivity must be greater than or equal to 90") }, + numericality: { only_integer: true, greater_than_or_equal_to: 90, message: N_("'%{value}' days of inactivity must be greater than or equal to 90") }, if: :deactivate_dormant_users? - # rubocop:enable Cop/StaticTranslationDefinition Gitlab::SSHPublicKey.supported_types.each do |type| validates :"#{type}_key_restriction", presence: true, key_restriction: { type: type } diff --git a/app/models/ci/bridge.rb b/app/models/ci/bridge.rb index d6051d70503..22dcc7c18a0 100644 --- a/app/models/ci/bridge.rb +++ b/app/models/ci/bridge.rb @@ -18,8 +18,6 @@ module Ci belongs_to :project belongs_to :trigger_request - has_many :sourced_pipelines, class_name: "::Ci::Sources::Pipeline", - foreign_key: :source_job_id has_one :downstream_pipeline, through: :sourced_pipeline, source: :pipeline @@ -87,7 +85,7 @@ module Ci end def has_downstream_pipeline? - sourced_pipelines.exists? + sourced_pipeline.present? end def downstream_pipeline_params diff --git a/app/models/ci/build.rb b/app/models/ci/build.rb index 6441928835c..18ce02bca47 100644 --- a/app/models/ci/build.rb +++ b/app/models/ci/build.rb @@ -48,7 +48,6 @@ module Ci # Details: https://gitlab.com/gitlab-org/gitlab/-/issues/24644#note_689472685 has_many :job_artifacts, class_name: 'Ci::JobArtifact', foreign_key: :job_id, dependent: :destroy, inverse_of: :job # rubocop:disable Cop/ActiveRecordDependent has_many :job_variables, class_name: 'Ci::JobVariable', foreign_key: :job_id - has_many :sourced_pipelines, class_name: 'Ci::Sources::Pipeline', foreign_key: :source_job_id has_many :pages_deployments, inverse_of: :ci_build diff --git a/app/services/ci/pipeline_trigger_service.rb b/app/services/ci/pipeline_trigger_service.rb index d7065680053..fae3ae3bf02 100644 --- a/app/services/ci/pipeline_trigger_service.rb +++ b/app/services/ci/pipeline_trigger_service.rb @@ -62,7 +62,7 @@ module Ci response = Ci::CreatePipelineService .new(project, job.user, ref: params[:ref], variables_attributes: variables) .execute(:pipeline, ignore_skip_ci: true) do |pipeline| - source = job.sourced_pipelines.build( + source = job.build_sourced_pipeline( source_pipeline: job.pipeline, source_project: job.project, pipeline: pipeline, diff --git a/config/feature_flags/development/geo_container_repository_replication.yml b/config/feature_flags/development/geo_container_repository_replication.yml deleted file mode 100644 index 94682cc63cc..00000000000 --- a/config/feature_flags/development/geo_container_repository_replication.yml +++ /dev/null @@ -1,8 +0,0 @@ ---- -name: geo_container_repository_replication -introduced_by_url: "https://gitlab.com/gitlab-org/gitlab/-/merge_requests/93690" -rollout_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/366662 -milestone: '15.5' -type: development -group: group::geo -default_enabled: true diff --git a/config/initializers/1_settings.rb b/config/initializers/1_settings.rb index da4277c8146..d0a67c13622 100644 --- a/config/initializers/1_settings.rb +++ b/config/initializers/1_settings.rb @@ -718,9 +718,6 @@ Gitlab.ee do Settings.cron_jobs['geo_repository_verification_secondary_scheduler_worker'] ||= Settingslogic.new({}) Settings.cron_jobs['geo_repository_verification_secondary_scheduler_worker']['cron'] ||= '*/1 * * * *' Settings.cron_jobs['geo_repository_verification_secondary_scheduler_worker']['job_class'] ||= 'Geo::RepositoryVerification::Secondary::SchedulerWorker' - Settings.cron_jobs['geo_container_repository_sync_worker'] ||= Settingslogic.new({}) - Settings.cron_jobs['geo_container_repository_sync_worker']['cron'] ||= '*/1 * * * *' - Settings.cron_jobs['geo_container_repository_sync_worker']['job_class'] ||= 'Geo::ContainerRepositorySyncDispatchWorker' Settings.cron_jobs['historical_data_worker'] ||= Settingslogic.new({}) Settings.cron_jobs['historical_data_worker']['cron'] ||= '0 12 * * *' Settings.cron_jobs['historical_data_worker']['job_class'] = 'HistoricalDataWorker' diff --git a/doc/administration/geo/replication/datatypes.md b/doc/administration/geo/replication/datatypes.md index 0198d2a63e8..022fe114a33 100644 --- a/doc/administration/geo/replication/datatypes.md +++ b/doc/administration/geo/replication/datatypes.md @@ -201,7 +201,7 @@ successfully, you must replicate their data using some other means. |[CI job artifacts](../../../ci/pipelines/job_artifacts.md) | **Yes** (10.4) | **Yes** (14.10) | [**Yes** (15.1)](https://gitlab.com/groups/gitlab-org/-/epics/5551) | [No](object_storage.md#verification-of-files-in-object-storage) | Verification is behind the feature flag `geo_job_artifact_replication`, enabled by default in 14.10. | |[CI Pipeline Artifacts](https://gitlab.com/gitlab-org/gitlab/-/blob/master/app/models/ci/pipeline_artifact.rb) | [**Yes** (13.11)](https://gitlab.com/gitlab-org/gitlab/-/issues/238464) | [**Yes** (13.11)](https://gitlab.com/gitlab-org/gitlab/-/issues/238464) | [**Yes** (15.1)](https://gitlab.com/groups/gitlab-org/-/epics/5551) | [No](object_storage.md#verification-of-files-in-object-storage) | Persists additional artifacts after a pipeline completes. | |[CI Secure Files](https://gitlab.com/gitlab-org/gitlab/-/blob/master/app/models/ci/secure_file.rb) | [**Yes** (15.3)](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/91430) | [**Yes** (15.3)](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/91430) | [**Yes** (15.3)](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/91430) | [No](object_storage.md#verification-of-files-in-object-storage) | Verification is behind the feature flag `geo_ci_secure_file_replication`, enabled by default in 15.3. | -|[Container Registry](../../packages/container_registry.md) | **Yes** (12.3)* | No | No | No | Replication is behind feature flag `geo_container_repository_replication`, enabled by default. Requires additional configuration. See [instructions](container_registry.md) to set up the Container Registry replication. | +|[Container Registry](../../packages/container_registry.md) | **Yes** (12.3)* | No | No | No | See [instructions](container_registry.md) to set up the Container Registry replication. | |[Infrastructure Registry](../../../user/packages/infrastructure_registry/index.md) | **Yes** (14.0) | **Yes** (14.0) | [**Yes** (15.1)](https://gitlab.com/groups/gitlab-org/-/epics/5551) | [No](object_storage.md#verification-of-files-in-object-storage) | Behind feature flag `geo_package_file_replication`, enabled by default. | |[Project designs repository](../../../user/project/issues/design_management.md) | **Yes** (12.7) | [No](https://gitlab.com/gitlab-org/gitlab/-/issues/32467) | N/A | N/A | Designs also require replication of LFS objects and Uploads. | |[Package Registry](../../../user/packages/package_registry/index.md) | **Yes** (13.2) | **Yes** (13.10) | [**Yes** (15.1)](https://gitlab.com/groups/gitlab-org/-/epics/5551) | [No](object_storage.md#verification-of-files-in-object-storage) | Behind feature flag `geo_package_file_replication`, enabled by default. | diff --git a/doc/api/graphql/reference/index.md b/doc/api/graphql/reference/index.md index 647246705ed..adf558eb91d 100644 --- a/doc/api/graphql/reference/index.md +++ b/doc/api/graphql/reference/index.md @@ -13001,11 +13001,7 @@ four standard [pagination arguments](#connection-pagination-arguments): ##### `GeoNode.containerRepositoryRegistries` -Find Container Repository registries on this Geo node. Ignored if `geo_container_repository_replication` feature flag is disabled. - -WARNING: -**Introduced** in 15.5. -This feature is in Alpha. It can be changed or removed at any time. +Find Container Repository registries on this Geo node. Returns [`ContainerRepositoryRegistryConnection`](#containerrepositoryregistryconnection). diff --git a/doc/ci/examples/deployment/composer-npm-deploy.md b/doc/ci/examples/deployment/composer-npm-deploy.md index a603207aef7..533b6519d9a 100644 --- a/doc/ci/examples/deployment/composer-npm-deploy.md +++ b/doc/ci/examples/deployment/composer-npm-deploy.md @@ -120,7 +120,7 @@ Therefore, for a production environment we use additional steps to ensure that a ## Where to go next -Since this was a WordPress project, I gave real life code snippets. Some further ideas you can pursue: +Since this was a WordPress project, it includes real code snippets. Some further ideas you can pursue: - Having a slightly different script for the default branch allows you to deploy to a production server from that branch and to a stage server from any other branches. - Instead of pushing it live, you can push it to WordPress official repository. diff --git a/doc/development/code_review.md b/doc/development/code_review.md index 25cd95a6f04..209e971c952 100644 --- a/doc/development/code_review.md +++ b/doc/development/code_review.md @@ -185,49 +185,49 @@ Using checklists improves quality in software engineering. This checklist is a s See the [test engineering process](https://about.gitlab.com/handbook/engineering/quality/quality-engineering/test-engineering/) for further quality guidelines. -1. I have self-reviewed this MR per [code review guidelines](code_review.md). -1. For the code that this change impacts, I believe that the automated tests ([Testing Guide](testing_guide/index.md)) validate functionality that is highly important to users (including consideration of [all test levels](testing_guide/testing_levels.md)). -1. If the existing automated tests do not cover the above functionality, I have added the necessary additional tests or added an issue to describe the automation testing gap and linked it to this MR. -1. I have considered the technical aspects of this change's impact on GitLab.com hosted customers and self-managed customers. -1. I have considered the impact of this change on the frontend, backend, and database portions of the system where appropriate and applied the `~ux`, `~frontend`, `~backend`, and `~database` labels accordingly. -1. I have tested this MR in [all supported browsers](../install/requirements.md#supported-web-browsers), or determined that this testing is not needed. -1. I have confirmed that this change is [backwards compatible across updates](multi_version_compatibility.md), or I have decided that this does not apply. -1. I have properly separated EE content from FOSS, or this MR is FOSS only. +1. You have self-reviewed this MR per [code review guidelines](code_review.md). +1. For the code that this change impacts, you believe that the automated tests ([Testing Guide](testing_guide/index.md)) validate functionality that is highly important to users (including consideration of [all test levels](testing_guide/testing_levels.md)). +1. If the existing automated tests do not cover the above functionality, you have added the necessary additional tests or added an issue to describe the automation testing gap and linked it to this MR. +1. You have considered the technical aspects of this change's impact on GitLab.com hosted customers and self-managed customers. +1. You have considered the impact of this change on the frontend, backend, and database portions of the system where appropriate and applied the `~ux`, `~frontend`, `~backend`, and `~database` labels accordingly. +1. You have tested this MR in [all supported browsers](../install/requirements.md#supported-web-browsers), or determined that this testing is not needed. +1. You have confirmed that this change is [backwards compatible across updates](multi_version_compatibility.md), or you have decided that this does not apply. +1. You have properly separated EE content from FOSS, or this MR is FOSS only. - [Where should EE code go?](ee_features.md) -1. I have considered that existing data may be surprisingly varied. For example, a new model validation can break existing records. Consider making validation on existing data optional rather than required if you haven't confirmed that existing data will pass validation. +1. You have considered that existing data may be surprisingly varied. For example, a new model validation can break existing records. Consider making validation on existing data optional rather than required if you haven't confirmed that existing data will pass validation. ##### Performance, reliability, and availability -1. I am confident that this MR does not harm performance, or I have asked a reviewer to help assess the performance impact. ([Merge request performance guidelines](merge_request_performance_guidelines.md)) -1. I have added [information for database reviewers in the MR description](database_review.md#required), or I have decided that it is unnecessary. +1. You are confident that this MR does not harm performance, or you have asked a reviewer to help assess the performance impact. ([Merge request performance guidelines](merge_request_performance_guidelines.md)) +1. You have added [information for database reviewers in the MR description](database_review.md#required), or you have decided that it is unnecessary. - [Does this MR have database-related changes?](database_review.md) -1. I have considered the availability and reliability risks of this change. -1. I have considered the scalability risk based on future predicted growth. -1. I have considered the performance, reliability, and availability impacts of this change on large customers who may have significantly more data than the average customer. +1. You have considered the availability and reliability risks of this change. +1. You have considered the scalability risk based on future predicted growth. +1. You have considered the performance, reliability, and availability impacts of this change on large customers who may have significantly more data than the average customer. ##### Observability instrumentation -1. I have included enough instrumentation to facilitate debugging and proactive performance improvements through observability. +1. You have included enough instrumentation to facilitate debugging and proactive performance improvements through observability. See [example](https://gitlab.com/gitlab-org/gitlab/-/issues/346124#expectations) of adding feature flags, logging, and instrumentation. ##### Documentation -1. I have included changelog trailers, or I have decided that they are not needed. +1. You have included changelog trailers, or you have decided that they are not needed. - [Does this MR need a changelog?](changelog.md#what-warrants-a-changelog-entry) -1. I have added/updated documentation or decided that documentation changes are unnecessary for this MR. +1. You have added/updated documentation or decided that documentation changes are unnecessary for this MR. - [Is documentation required?](https://about.gitlab.com/handbook/product/ux/technical-writing/workflow/#when-documentation-is-required) ##### Security -1. I have confirmed that if this MR contains changes to processing or storing of credentials or tokens, authorization, and authentication methods, or other items described in [the security review guidelines](https://about.gitlab.com/handbook/security/#when-to-request-a-security-review), I have added the `~security` label and I have `@`-mentioned `@gitlab-com/gl-security/appsec`. -1. I have reviewed the documentation regarding [internal application security reviews](https://about.gitlab.com/handbook/security/#internal-application-security-reviews) for **when** and **how** to request a security review and requested a security review if this is warranted for this change. +1. You have confirmed that if this MR contains changes to processing or storing of credentials or tokens, authorization, and authentication methods, or other items described in [the security review guidelines](https://about.gitlab.com/handbook/security/#when-to-request-a-security-review), you have added the `~security` label and you have `@`-mentioned `@gitlab-com/gl-security/appsec`. +1. You have reviewed the documentation regarding [internal application security reviews](https://about.gitlab.com/handbook/security/#internal-application-security-reviews) for **when** and **how** to request a security review and requested a security review if this is warranted for this change. ##### Deployment -1. I have considered using a feature flag for this change because the change may be high risk. -1. If I am using a feature flag, I plan to test the change in staging before I test it in production, and I have considered rolling it out to a subset of production customers before rolling it out to all customers. +1. You have considered using a feature flag for this change because the change may be high risk. +1. If you are using a feature flag, you plan to test the change in staging before you test it in production, and you have considered rolling it out to a subset of production customers before rolling it out to all customers. - [When to use a feature flag](https://about.gitlab.com/handbook/product-development-flow/feature-flag-lifecycle/#when-to-use-feature-flags) -1. I have informed the Infrastructure department of a default setting or new setting change per [definition of done](contributing/merge_request_workflow.md#definition-of-done), or decided that this is unnecessary. +1. You have informed the Infrastructure department of a default setting or new setting change per [definition of done](contributing/merge_request_workflow.md#definition-of-done), or decided that this is unnecessary. ### The responsibility of the merge request author diff --git a/doc/development/contributing/merge_request_workflow.md b/doc/development/contributing/merge_request_workflow.md index f2c06e289c9..247383d1f39 100644 --- a/doc/development/contributing/merge_request_workflow.md +++ b/doc/development/contributing/merge_request_workflow.md @@ -313,7 +313,7 @@ The following items are checked after the merge request has been merged: 1. Confirmed to be working in staging before implementing the change in production, where possible. 1. Confirmed to be working in the production with no new [Sentry](https://about.gitlab.com/handbook/engineering/monitoring/#sentry) errors after the contribution is deployed. 1. Confirmed that the [rollout plan](https://about.gitlab.com/handbook/engineering/development/processes/rollout-plans/) has been completed. -1. If there is a performance risk in the change, I have analyzed the performance of the system before and after the change. +1. If there is a performance risk in the change, you have analyzed the performance of the system before and after the change. 1. *If the merge request uses feature flags, per-project or per-group enablement, and a staged rollout:* - Confirmed to be working on GitLab projects. - Confirmed to be working at each stage for all projects added. diff --git a/doc/development/documentation/topic_types/concept.md b/doc/development/documentation/topic_types/concept.md index 7be6bef4fad..e01b06c2c07 100644 --- a/doc/development/documentation/topic_types/concept.md +++ b/doc/development/documentation/topic_types/concept.md @@ -11,7 +11,7 @@ A concept introduces a single feature or concept. A concept should answer the questions: - What is this? -- Why would I use it? +- Why would you use it? Think of everything someone might want to know if they've never heard of this concept before. diff --git a/doc/development/fe_guide/source_editor.md b/doc/development/fe_guide/source_editor.md index b7cd903485e..4cfc68553e0 100644 --- a/doc/development/fe_guide/source_editor.md +++ b/doc/development/fe_guide/source_editor.md @@ -66,9 +66,9 @@ with additional functions on the instance level: | Function | Arguments | Description | --------------------- | ----- | ----- | -| `updateModelLanguage` | `path`: String | Updates the instance's syntax highlighting to follow the extension of the passed `path`. Available only on the instance level.| -| `use` | Array of objects | Array of extensions to apply to the instance. Accepts only the array of _objects_. You must fetch the extensions' ES6 modules must be fetched and resolved in your views or components before they are passed to `use`. This property is available on _instance_ (applies extension to this particular instance) and _global editor_ (applies the same extension to all instances) levels. | -| Monaco Editor options | See [documentation](https://microsoft.github.io/monaco-editor/api/interfaces/monaco.editor.IStandaloneCodeEditor.html) | Default Monaco editor options | +| `updateModelLanguage` | `path`: String | Updates the instance's syntax highlighting to follow the extension of the passed `path`. Available only on the instance level. | +| `use` | Array of objects | Array of extensions to apply to the instance. Accepts only an array of **objects**. The extensions' ES6 modules must be fetched and resolved in your views or components before they're passed to `use`. Available on the instance and global editor (all instances) levels. | +| Monaco Editor options | See [documentation](https://microsoft.github.io/monaco-editor/api/interfaces/monaco.editor.IStandaloneCodeEditor.html) | Default Monaco editor options. | ## Tips diff --git a/doc/development/fe_guide/style/scss.md b/doc/development/fe_guide/style/scss.md index 98f74813231..c20ade6bc1d 100644 --- a/doc/development/fe_guide/style/scss.md +++ b/doc/development/fe_guide/style/scss.md @@ -41,13 +41,13 @@ GitLab differs from the scale used in the Bootstrap library. For a Bootstrap pad utility, you may need to double the size of the applied utility to achieve the same visual result (such as `ml-1` becoming `gl-ml-2`). -#### Where should I put new utility classes? +#### Where should you put new utility classes? If a class you need has not been added to GitLab UI, you get to add it! Follow the naming patterns documented in the [utility files](https://gitlab.com/gitlab-org/gitlab-ui/-/tree/main/src/scss/utility-mixins) and refer to [GitLab UI's CSS documentation](https://gitlab.com/gitlab-org/gitlab-ui/-/blob/main/doc/contributing/adding_css.md#adding-utility-mixins) for more details, especially about adding responsive and stateful rules. If it is not possible to wait for a GitLab UI update (generally one day), add the class to [`utilities.scss`](https://gitlab.com/gitlab-org/gitlab/-/blob/master/app/assets/stylesheets/utilities.scss) following the same naming conventions documented in GitLab UI. A follow-up issue to backport the class to GitLab UI and delete it from GitLab should be opened. -#### When should I create component classes? +#### When should you create component classes? We recommend a "utility-first" approach. diff --git a/doc/development/fe_guide/troubleshooting.md b/doc/development/fe_guide/troubleshooting.md index 873a14b8f14..3e4c5007b64 100644 --- a/doc/development/fe_guide/troubleshooting.md +++ b/doc/development/fe_guide/troubleshooting.md @@ -10,13 +10,13 @@ Running into a problem? Maybe this will help ¯\_(ツ)_/¯. ## Troubleshooting issues -### This guide doesn't contain the issue I ran into +### This guide doesn't contain the issue you ran into If you run into a Frontend development issue that is not in this guide, consider updating this guide with your issue and possible remedies. This way future adventurers can face these dragons with more success, being armed with your experience and knowledge. ## Testing issues -### ``Property or method `nodeType` is not defined`` but I'm not using `nodeType` anywhere +### ``Property or method `nodeType` is not defined`` but you're not using `nodeType` anywhere This issue can happen in Vue component tests, when an expectation fails, but there is an error thrown when Jest tries to pretty print the diff in the console. It's been noted that using `toEqual` with an array as a diff --git a/doc/development/feature_development.md b/doc/development/feature_development.md index d839dcbdf77..645505b2da1 100644 --- a/doc/development/feature_development.md +++ b/doc/development/feature_development.md @@ -204,3 +204,4 @@ The following integration guides are internal. Some integrations require access - [Run full Auto DevOps cycle in a GDK instance](https://gitlab.com/gitlab-org/gitlab-development-kit/blob/main/doc/howto/auto_devops.md) - [Using GitLab Runner with the GDK](https://gitlab.com/gitlab-org/gitlab-development-kit/blob/main/doc/howto/runner.md) - [Using the Web IDE terminal with the GDK](https://gitlab.com/gitlab-org/gitlab-development-kit/-/blob/main/doc/howto/web_ide_terminal_gdk_setup.md) +- [Gitpod configuration internals page](gitpod_internals.md) diff --git a/doc/development/gitpod_internals.md b/doc/development/gitpod_internals.md new file mode 100644 index 00000000000..a4674df758d --- /dev/null +++ b/doc/development/gitpod_internals.md @@ -0,0 +1,30 @@ +--- +stage: none +group: Engineering Productivity +info: To determine the technical writer assigned to the Stage/Group associated with this page, see https://about.gitlab.com/handbook/product/ux/technical-writing/#assignments +--- + +# Gitpod internal configuration + +## Settings + +The settings for `gitlab-org/gitlab` are defined under a [project's settings in a Gitpod dashboard](https://gitpod.io/t/gitlab-org/gitlab/settings). To view the settings, you must first join the `gitlab-org` team on [Gitpod.io](https://gitpod.io/). You can join the team using the bookmark link at the top of `#gitpod-gdk` internal Slack channel. + +The current settings are: + +- `Enable Incremental Prebuilds`: Uses an earlier successful prebuild to create new prebuilds faster. +- `Use Last Successful Prebuild`: Skips waiting for prebuilds currently in progress and uses the last successful prebuild from previous commits on the same branch. + +## Webhooks + +A webhook that starts with `https://gitpod.io/` is created to enable prebuilds (see [Enabling Prebuilds](https://www.gitpod.io/docs/configure/authentication/gitlab#enabling-prebuilds) for more details). The webhook is maintained by an [Engineering Productivity team](https://about.gitlab.com/handbook/engineering/quality/engineering-productivity/). + +You can find this webhook in [Webhook Settings in `gitlab-org/gitlab`](https://gitlab.com/gitlab-org/gitlab/-/hooks). If you cannot access this setting, please chat to the [Engineering Productivity team](https://about.gitlab.com/handbook/engineering/quality/engineering-productivity/). + +### Troubleshooting a failed webhook + +If a webhook failed to connect for a long time, then it may have been disabled in the project. + +To re-enable a failing or failed webhook, send a test request in [Webhook Settings](https://gitlab.com/gitlab-org/gitlab/-/hooks). See [Re-enable disabled webhooks page](https://docs.gitlab.com/15.4/ee/user/project/integrations/webhooks.html#re-enable-disabled-webhooks) for more details. + +After re-enabling, check the prebuilds' health in a [project's prebuilds](https://gitpod.io/t/gitlab-org/gitlab/prebuilds) and confirm that prebuilds start without any errors. diff --git a/doc/development/multi_version_compatibility.md b/doc/development/multi_version_compatibility.md index 8e2103b2f3e..36b392a0037 100644 --- a/doc/development/multi_version_compatibility.md +++ b/doc/development/multi_version_compatibility.md @@ -112,7 +112,7 @@ During an update, there will be [two different versions of GitLab running in dif Yes! We have specific instructions for [zero-downtime updates](../update/index.md#upgrading-without-downtime) because it allows us to ignore some permutations of compatibility. This is why we don't worry about Rails code making DB calls to an old PostgreSQL database schema. -## I've identified a potential backwards compatibility problem, what can I do about it? +## You've identified a potential backwards compatibility problem, what can you do about it? ### Coordinate diff --git a/doc/development/projections.md b/doc/development/projections.md index e45a16c267d..49480981d8d 100644 --- a/doc/development/projections.md +++ b/doc/development/projections.md @@ -20,7 +20,7 @@ Projections are a way to define relations between files. Every file can have a You can find a basic list of projection options in [projectionist.txt](https://github.com/tpope/vim-projectionist/blob/master/doc/projectionist.txt) -## Which plugins can I use +## Which plugins can you use - vim - [vim-projectionist](https://github.com/tpope/vim-projectionist) diff --git a/doc/development/testing_guide/end_to_end/index.md b/doc/development/testing_guide/end_to_end/index.md index 8ffe044c4d8..55d725ba4ae 100644 --- a/doc/development/testing_guide/end_to_end/index.md +++ b/doc/development/testing_guide/end_to_end/index.md @@ -238,7 +238,7 @@ Each type of scheduled pipeline generates a static link for the latest test repo - [`production`](https://storage.googleapis.com/gitlab-qa-allure-reports/production-full/master/index.html) - [`production-sanity`](https://storage.googleapis.com/gitlab-qa-allure-reports/production-sanity/master/index.html) -## How do I run the tests? +## How do you run the tests? If you are not [testing code in a merge request](#testing-code-in-merge-requests), there are two main options for running the tests. If you want to run @@ -255,12 +255,12 @@ and the section below. Learn how to perform [tests that require special setup or consideration to run on your local environment](running_tests_that_require_special_setup.md). -## How do I write tests? +## How do you write tests? In order to write new tests, you first need to learn more about GitLab QA architecture. See the [documentation about it](https://gitlab.com/gitlab-org/gitlab-qa/blob/master/docs/architecture.md). -Once you decided where to put [test environment orchestration scenarios](https://gitlab.com/gitlab-org/gitlab-qa/tree/master/lib/gitlab/qa/scenario) and +After you've decided where to put [test environment orchestration scenarios](https://gitlab.com/gitlab-org/gitlab-qa/tree/master/lib/gitlab/qa/scenario) and [instance-level scenarios](https://gitlab.com/gitlab-org/gitlab-foss/tree/master/qa/qa/specs/features), take a look at the [GitLab QA README](https://gitlab.com/gitlab-org/gitlab/-/tree/master/qa/README.md), the [GitLab QA orchestrator README](https://gitlab.com/gitlab-org/gitlab-qa/tree/master/README.md), and [the already existing instance-level scenarios](https://gitlab.com/gitlab-org/gitlab-foss/tree/master/qa/qa/specs/features). @@ -283,7 +283,7 @@ Continued reading: - [Execution context selection](execution_context_selection.md) - [Troubleshooting](troubleshooting.md) -## Where can I ask for help? +## Where can you ask for help? You can ask question in the `#quality` channel on Slack (GitLab internal) or you can find an issue you would like to work on in diff --git a/doc/development/testing_guide/frontend_testing.md b/doc/development/testing_guide/frontend_testing.md index 041b0f0a4f4..56bbcb815d1 100644 --- a/doc/development/testing_guide/frontend_testing.md +++ b/doc/development/testing_guide/frontend_testing.md @@ -90,7 +90,7 @@ function getFahrenheit(celsius) { } ``` -It does not make sense to test our `getFahrenheit` function because underneath it does nothing else but invoking the library function, and we can expect that one is working as intended. (Simplified, I know) +It does not make sense to test our `getFahrenheit` function because underneath it does nothing else but invoking the library function, and we can expect that one is working as intended. Let's take a short look into Vue land. Vue is a critical part of the GitLab JavaScript codebase. When writing specs for Vue components, a common gotcha is to actually end up testing Vue provided functionality, because it appears to be the easiest thing to test. Here's an example taken from our codebase. @@ -713,7 +713,7 @@ unit testing by mocking out modules that cannot be easily consumed in our test e > Instead, consider using [`jest.mock(..)`](https://jestjs.io/docs/jest-object#jestmockmodulename-factory-options) > (or a similar mocking function) in the relevant spec file. -#### Where should I put manual mocks? +#### Where should you put manual mocks? Jest supports [manual module mocks](https://jestjs.io/docs/manual-mocks) by placing a mock in a `__mocks__/` directory next to the source module (for example, `app/assets/javascripts/ide/__mocks__`). **Don't do this.** We want to keep all of our test-related code in one place (the `spec/` folder). diff --git a/doc/development/uploads/working_with_uploads.md b/doc/development/uploads/working_with_uploads.md index c88762e6bd5..92d0f45bd4b 100644 --- a/doc/development/uploads/working_with_uploads.md +++ b/doc/development/uploads/working_with_uploads.md @@ -8,9 +8,9 @@ info: To determine the technical writer assigned to the Stage/Group associated w ## Recommendations -- When creating an uploader, [make it a subclass](#where-should-i-store-my-files) of `AttachmentUploader` +- When creating an uploader, [make it a subclass](#where-should-you-store-your-files) of `AttachmentUploader` - Add your uploader to the [tables](#tables) in this document -- Do not add [new object storage buckets](#where-should-i-store-my-files) +- Do not add [new object storage buckets](#where-should-you-store-your-files) - Implement [direct upload](#implementing-direct-upload-support) - If you need to process your uploads, decide [where to do that](#processing-uploads) @@ -19,7 +19,7 @@ info: To determine the technical writer assigned to the Stage/Group associated w - [CarrierWave Uploaders](#carrierwave-uploaders) - [GitLab modifications to CarrierWave](#gitlab-modifications-to-carrierwave) -## Where should I store my files? +## Where should you store your files? CarrierWave Uploaders determine where files get stored. When you create a new Uploader class you are deciding where to store the files of your new @@ -169,8 +169,8 @@ class Project < ApplicationRecord end ``` -Now if I upload an avatar called `tanuki.png` the idea is that in the -`projects.avatar` column for my project, CarrierWave stores the string +Now if you upload an avatar called `tanuki.png` the idea is that in the +`projects.avatar` column for your project, CarrierWave stores the string `tanuki.png`, and that the AttachmentUploader class contains the configuration data and directory schema. For example if the project ID is 123, the actual file may be in diff --git a/doc/integration/advanced_search/elasticsearch_troubleshooting.md b/doc/integration/advanced_search/elasticsearch_troubleshooting.md index 11d8ad0a596..5833b6667c6 100644 --- a/doc/integration/advanced_search/elasticsearch_troubleshooting.md +++ b/doc/integration/advanced_search/elasticsearch_troubleshooting.md @@ -96,7 +96,7 @@ Here are some common pitfalls and how to overcome them. a Lucene index. - **Replicas**: Failover mechanisms that duplicate indices. -## How can I verify that my GitLab instance is using Elasticsearch? +## How can you verify that your GitLab instance is using Elasticsearch? There are a couple of ways to achieve that: @@ -184,13 +184,13 @@ If reindexing the project shows: - Elasticsearch errors or doesn't present any errors at all, reach out to your Elasticsearch administrator to check the instance. -### I updated GitLab and now I can't find anything +### You updated GitLab and now you can't find anything We continuously make updates to our indexing strategies and aim to support newer versions of Elasticsearch. When indexing changes are made, it may be necessary for you to [reindex](elasticsearch.md#zero-downtime-reindexing) after updating GitLab. -### I indexed all the repositories but I can't get any hits for my search term in the UI +### You indexed all the repositories but you can't get any hits for your search term in the UI Make sure you [indexed all the database data](elasticsearch.md#enable-advanced-search). @@ -220,7 +220,7 @@ The above instructions are not to be used for scenarios that only index a [subse See [Elasticsearch Index Scopes](elasticsearch.md#advanced-search-index-scopes) for more information on searching for specific types of data. -### I indexed all the repositories but then switched Elasticsearch servers and now I can't find anything +### You indexed all the repositories but then switched Elasticsearch servers and now you can't find anything You must re-run all the Rake tasks to reindex the database, repositories, and wikis. @@ -228,11 +228,11 @@ You must re-run all the Rake tasks to reindex the database, repositories, and wi The more data present in your GitLab instance, the longer the indexing process takes. -### There are some projects that weren't indexed, but I don't know which ones +### There are some projects that weren't indexed, but you don't know which ones You can run `sudo gitlab-rake gitlab:elastic:projects_not_indexed` to display projects that aren't indexed. -### No new data is added to the Elasticsearch index when I push code +### No new data is added to the Elasticsearch index when you push code NOTE: This was [fixed](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/35936) in GitLab 13.2 and the Rake task is not available for versions greater than that. diff --git a/doc/integration/jira/connect-app.md b/doc/integration/jira/connect-app.md index 171c1cbe484..4db213ce9a8 100644 --- a/doc/integration/jira/connect-app.md +++ b/doc/integration/jira/connect-app.md @@ -72,6 +72,53 @@ for details. If the app requires additional permissions, [the update must first be manually approved in Jira](https://developer.atlassian.com/platform/marketplace/upgrading-and-versioning-cloud-apps/#changes-that-require-manual-customer-approval). +## Connect the GitLab.com for Jira Cloud app for self-managed instances **(FREE SELF)** + +> Introduced in GitLab 15.6 [with flags](../../administration/feature_flags.md) named [`jira_connect_oauth_self_managed_setting`](https://gitlab.com/gitlab-org/gitlab/-/issues/377679), [`jira_connect_oauth`](https://gitlab.com/gitlab-org/gitlab/-/issues/355048), and [`jira_connect_oauth_self_managed`](https://gitlab.com/gitlab-org/gitlab/-/issues/359940). Disabled by default. + +FLAG: +On self-managed GitLab, by default this feature is not available. To make it available, +ask an administrator to [enable the feature flags](../../administration/feature_flags.md) named +`jira_connect_oauth_self_managed_setting`, `jira_connect_oauth`, and `jira_connect_oauth_self_managed`. +On GitLab.com, this feature is not available. The feature is not ready for production use. + +Prerequisites: + +- GitLab.com must serve as a proxy for the instance. +- The instance must be publicly available. + +You can link self-managed instances after installing the GitLab.com for Jira Cloud app from the marketplace. +Jira apps can only link to one URL per marketplace listing. The official listing links to GitLab.com. + +### Set up your instance + +To set up your self-managed instance for the GitLab.com for Jira Cloud app: + +1. On the top bar, select **Main menu > Admin**. +1. On the left sidebar, select **Applications** (`/admin/applications`). +1. Select **New application**. +1. In **Redirect URI**, enter `https://gitlab.com/-/jira_connect/oauth_callbacks`. +1. Ensure the **Trusted** and **Confidential** checkboxes are cleared. +<!-- markdownlint-disable MD044 --> +1. In **Scopes**, select the **api** checkbox only. +<!-- markdownlint-enable MD044 --> +1. Select **Save application**. +1. Copy the **Application ID** value. +1. On the left sidebar, select **Settings > General** (`/admin/application_settings/general`). +1. Expand the **GitLab for Jira App** section. +1. Paste the **Application ID** value into **Jira Connect Application ID**. +1. In **Jira Connect Proxy URL**, enter `https://gitlab.com`. +1. Select **Save changes**. + +### Link your instance + +To link your self-managed instance to the GitLab.com for Jira Cloud app: + +1. Install the [GitLab.com for Jira Cloud app](https://marketplace.atlassian.com/apps/1221011/gitlab-com-for-jira-cloud?tab=overview&hosting=cloud). +1. Select **GitLab (self-managed)**. +1. Enter your GitLab instance URL. +1. Select **Save**. + ## Install the GitLab.com for Jira Cloud app for self-managed instances **(FREE SELF)** If your GitLab instance is self-managed, you must follow some diff --git a/doc/topics/authentication/index.md b/doc/topics/authentication/index.md index 12ff5cb50b8..763e16bc31d 100644 --- a/doc/topics/authentication/index.md +++ b/doc/topics/authentication/index.md @@ -12,7 +12,7 @@ This page gathers all the resources for the topic **Authentication** within GitL - [SSH](../../user/ssh.md) - [Two-factor authentication](../../user/profile/account/two_factor_authentication.md) -- [Why do I keep getting signed out?](../../user/profile/index.md#why-do-i-keep-getting-signed-out) +- [Why do you keep getting signed out?](../../user/profile/index.md#why-do-you-keep-getting-signed-out) - **Articles:** - [Support for Universal 2nd Factor Authentication - YubiKeys](https://about.gitlab.com/blog/2016/06/22/gitlab-adds-support-for-u2f/) - [Security Webcast with Yubico](https://about.gitlab.com/blog/2016/08/31/gitlab-and-yubico-security-webcast/) diff --git a/doc/user/application_security/dependency_scanning/index.md b/doc/user/application_security/dependency_scanning/index.md index 4ed9ceedb4d..2c0b762345d 100644 --- a/doc/user/application_security/dependency_scanning/index.md +++ b/doc/user/application_security/dependency_scanning/index.md @@ -1257,7 +1257,7 @@ file in the `CI_BUILDS_DIR` directory triggers the dependency scanning job. We recommend committing the lock files, which prevents this warning. -### I no longer get the latest Docker image after setting `DS_MAJOR_VERSION` or `DS_ANALYZER_IMAGE` +### You no longer get the latest Docker image after setting `DS_MAJOR_VERSION` or `DS_ANALYZER_IMAGE` If you have manually set `DS_MAJOR_VERSION` or `DS_ANALYZER_IMAGE` for specific reasons, and now must update your configuration to again get the latest patched versions of our diff --git a/doc/user/application_security/index.md b/doc/user/application_security/index.md index f92eee83c74..22965fb6bbb 100644 --- a/doc/user/application_security/index.md +++ b/doc/user/application_security/index.md @@ -683,7 +683,7 @@ This can be used for offline setups or for anyone wishing to use [Auto DevOps](. Instructions are available in the [legacy template project](https://gitlab.com/gitlab-org/auto-devops-v12-10). -#### Vulnerabilities are found, but the job succeeds. How can I have a pipeline fail instead? +#### Vulnerabilities are found, but the job succeeds. How can you have a pipeline fail instead? In these circumstances, that the job succeeds is the default behavior. The job's status indicates success or failure of the analyzer itself. Analyzer results are displayed in the diff --git a/doc/user/profile/active_sessions.md b/doc/user/profile/active_sessions.md index 430d1c3dc9f..7a837258cb2 100644 --- a/doc/user/profile/active_sessions.md +++ b/doc/user/profile/active_sessions.md @@ -40,7 +40,7 @@ To revoke an active session: NOTE: When any session is revoked all **Remember me** tokens for all -devices are revoked. See [Why do I keep getting signed out?](index.md#why-do-i-keep-getting-signed-out) +devices are revoked. See [Why do you keep getting signed out?](index.md#why-do-you-keep-getting-signed-out) for more information about the **Remember me** feature. <!-- ## Troubleshooting diff --git a/doc/user/profile/index.md b/doc/user/profile/index.md index 4adf6c351df..d6c5bd6c108 100644 --- a/doc/user/profile/index.md +++ b/doc/user/profile/index.md @@ -328,7 +328,7 @@ To view a user's activity in a top-level Activity view: ## Troubleshooting -### Why do I keep getting signed out? +### Why do you keep getting signed out? When you sign in to the main GitLab application, a `_gitlab_session` cookie is set. When you close your browser, the cookie is cleared client-side @@ -368,7 +368,7 @@ GitLab uses both session and persistent cookies: - Session cookie: Session cookies are normally removed at the end of the browser session when the browser is closed. The `_gitlab_session` cookie has no fixed expiration date. However, - it expires based on its [`session_expire_delay`](#why-do-i-keep-getting-signed-out). + it expires based on its [`session_expire_delay`](#why-do-you-keep-getting-signed-out). - Persistent cookie: The `remember_user_token` is a cookie with an expiration date of two weeks. GitLab activates this cookie if you select **Remember Me** when you sign in. diff --git a/doc/user/upgrade_email_bypass.md b/doc/user/upgrade_email_bypass.md index ef58d8aec66..afbdcbcdf09 100644 --- a/doc/user/upgrade_email_bypass.md +++ b/doc/user/upgrade_email_bypass.md @@ -76,7 +76,7 @@ Your primary email address is not confirmed. You can assure your users that they have not been [Blocked](admin_area/moderate_users.md#block-and-unblock-users) by an administrator. When affected users see this message, they must confirm their email address before they can commit code. -## What do I need to know as an administrator of a GitLab self-managed Instance? +## What do you need to know as an administrator of a GitLab self-managed Instance? You have the following options to help your users: @@ -85,7 +85,7 @@ You have the following options to help your users: As an administrator, you may also confirm a user in the [Admin Area](admin_area/index.md#administering-users). -## What do I do if I am an administrator and I am locked out? +## What do you do if you are an administrator and you're locked out? If you are an administrator and cannot otherwise verify your email address, sign in to your GitLab instance with a [Rails console session](../administration/operations/rails_console.md#starting-a-rails-console-session). @@ -97,7 +97,7 @@ admin.confirmed_at = Time.zone.now admin.save! ``` -## How do I force-confirm all users on my self-managed instance? +## How do you force-confirm all users on your self-managed instance? If you are an administrator and would like to force-confirm all users on your system, sign in to your GitLab instance with a [Rails console session](../administration/operations/rails_console.md#starting-a-rails-console-session). diff --git a/locale/gitlab.pot b/locale/gitlab.pot index fce0bf197b5..39ef9139441 100644 --- a/locale/gitlab.pot +++ b/locale/gitlab.pot @@ -10434,12 +10434,6 @@ msgstr "" msgid "Container registry is not enabled on this GitLab instance. Ask an administrator to enable it in order for Auto DevOps to work." msgstr "" -msgid "Container repositories" -msgstr "" - -msgid "Container repository" -msgstr "" - msgid "ContainerRegistry| Please visit the %{linkStart}administration settings%{linkEnd} to enable this feature." msgstr "" diff --git a/spec/features/boards/board_filters_spec.rb b/spec/features/boards/board_filters_spec.rb index eab92de7e8a..4ed1a7a58f4 100644 --- a/spec/features/boards/board_filters_spec.rb +++ b/spec/features/boards/board_filters_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'Issue board filters', :js do +RSpec.describe 'Issue board filters', :js, feature_category: :team_planning do let_it_be(:project) { create(:project, :repository) } let_it_be(:user) { create(:user) } let_it_be(:board) { create(:board, project: project) } diff --git a/spec/features/boards/boards_spec.rb b/spec/features/boards/boards_spec.rb index fee9b5b378e..9e0a507626a 100644 --- a/spec/features/boards/boards_spec.rb +++ b/spec/features/boards/boards_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'Project issue boards', :js do +RSpec.describe 'Project issue boards', :js, feature_category: :team_planning do include DragTo include MobileHelpers include BoardHelpers diff --git a/spec/features/boards/focus_mode_spec.rb b/spec/features/boards/focus_mode_spec.rb index 453a8d8870b..8f3ce25b583 100644 --- a/spec/features/boards/focus_mode_spec.rb +++ b/spec/features/boards/focus_mode_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'Issue Boards focus mode', :js do +RSpec.describe 'Issue Boards focus mode', :js, feature_category: :team_planning do let(:project) { create(:project, :public) } before do diff --git a/spec/features/boards/issue_ordering_spec.rb b/spec/features/boards/issue_ordering_spec.rb index a3dda3b9d2f..f1ee7a8fde7 100644 --- a/spec/features/boards/issue_ordering_spec.rb +++ b/spec/features/boards/issue_ordering_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'Issue Boards', :js do +RSpec.describe 'Issue Boards', :js, feature_category: :team_planning do include DragTo let(:project) { create(:project, :public) } diff --git a/spec/features/boards/keyboard_shortcut_spec.rb b/spec/features/boards/keyboard_shortcut_spec.rb index cefb486349d..6f03f6db3ab 100644 --- a/spec/features/boards/keyboard_shortcut_spec.rb +++ b/spec/features/boards/keyboard_shortcut_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'Issue Boards shortcut', :js do +RSpec.describe 'Issue Boards shortcut', :js, feature_category: :team_planning do context 'issues are enabled' do let(:project) { create(:project) } diff --git a/spec/features/boards/multi_select_spec.rb b/spec/features/boards/multi_select_spec.rb index cad303a14e5..7afe34be3d8 100644 --- a/spec/features/boards/multi_select_spec.rb +++ b/spec/features/boards/multi_select_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'Multi Select Issue', :js do +RSpec.describe 'Multi Select Issue', :js, feature_category: :team_planning do include DragTo let(:group) { create(:group, :nested) } diff --git a/spec/features/boards/multiple_boards_spec.rb b/spec/features/boards/multiple_boards_spec.rb index 219f24f60d7..e9d34c6f87f 100644 --- a/spec/features/boards/multiple_boards_spec.rb +++ b/spec/features/boards/multiple_boards_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'Multiple Issue Boards', :js do +RSpec.describe 'Multiple Issue Boards', :js, feature_category: :team_planning do let_it_be(:user) { create(:user) } let_it_be(:project) { create(:project, :public) } let_it_be(:planning) { create(:label, project: project, name: 'Planning') } diff --git a/spec/features/boards/new_issue_spec.rb b/spec/features/boards/new_issue_spec.rb index 5f4517d47ee..1b0695e4e60 100644 --- a/spec/features/boards/new_issue_spec.rb +++ b/spec/features/boards/new_issue_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'Issue Boards new issue', :js do +RSpec.describe 'Issue Boards new issue', :js, feature_category: :team_planning do let_it_be(:project) { create(:project, :public) } let_it_be(:board) { create(:board, project: project) } let_it_be(:backlog_list) { create(:backlog_list, board: board) } diff --git a/spec/features/boards/reload_boards_on_browser_back_spec.rb b/spec/features/boards/reload_boards_on_browser_back_spec.rb index 7fa440befc1..0ca680c5ed5 100644 --- a/spec/features/boards/reload_boards_on_browser_back_spec.rb +++ b/spec/features/boards/reload_boards_on_browser_back_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'Ensure Boards do not show stale data on browser back', :js do +RSpec.describe 'Ensure Boards do not show stale data on browser back', :js, feature_category: :team_planning do let(:project) { create(:project, :public) } let(:board) { create(:board, project: project) } let(:user) { create(:user) } diff --git a/spec/features/boards/sidebar_assignee_spec.rb b/spec/features/boards/sidebar_assignee_spec.rb index 63553cec89b..44ae0c5a3b4 100644 --- a/spec/features/boards/sidebar_assignee_spec.rb +++ b/spec/features/boards/sidebar_assignee_spec.rb @@ -2,7 +2,8 @@ require 'spec_helper' -RSpec.describe 'Project issue boards sidebar assignee', :js, quarantine: 'https://gitlab.com/gitlab-org/gitlab/-/issues/332230' do +RSpec.describe 'Project issue boards sidebar assignee', :js, quarantine: 'https://gitlab.com/gitlab-org/gitlab/-/issues/332230', + feature_category: :team_planning do include BoardHelpers let_it_be(:user) { create(:user) } diff --git a/spec/features/boards/sidebar_labels_in_namespaces_spec.rb b/spec/features/boards/sidebar_labels_in_namespaces_spec.rb index 8395a0b33c0..c3bb58df797 100644 --- a/spec/features/boards/sidebar_labels_in_namespaces_spec.rb +++ b/spec/features/boards/sidebar_labels_in_namespaces_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'Issue boards sidebar labels select', :js do +RSpec.describe 'Issue boards sidebar labels select', :js, feature_category: :team_planning do include BoardHelpers include_context 'labels from nested groups and projects' diff --git a/spec/features/boards/sidebar_labels_spec.rb b/spec/features/boards/sidebar_labels_spec.rb index 12d91e9c5a8..460d0d232b3 100644 --- a/spec/features/boards/sidebar_labels_spec.rb +++ b/spec/features/boards/sidebar_labels_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'Project issue boards sidebar labels', :js do +RSpec.describe 'Project issue boards sidebar labels', :js, feature_category: :team_planning do include BoardHelpers let_it_be(:group) { create(:group, :public) } diff --git a/spec/features/boards/sidebar_spec.rb b/spec/features/boards/sidebar_spec.rb index 2b2a412194a..0a16e95c0bf 100644 --- a/spec/features/boards/sidebar_spec.rb +++ b/spec/features/boards/sidebar_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'Project issue boards sidebar', :js do +RSpec.describe 'Project issue boards sidebar', :js, feature_category: :team_planning do include BoardHelpers let_it_be(:user) { create(:user) } diff --git a/spec/features/boards/user_adds_lists_to_board_spec.rb b/spec/features/boards/user_adds_lists_to_board_spec.rb index 480a88a6b84..a936e14168c 100644 --- a/spec/features/boards/user_adds_lists_to_board_spec.rb +++ b/spec/features/boards/user_adds_lists_to_board_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'User adds lists', :js do +RSpec.describe 'User adds lists', :js, feature_category: :team_planning do let_it_be(:group) { create(:group, :nested) } let_it_be(:project) { create(:project, :public, namespace: group) } let_it_be(:group_board) { create(:board, group: group) } diff --git a/spec/features/boards/user_visits_board_spec.rb b/spec/features/boards/user_visits_board_spec.rb index c386477fa9d..44c691435df 100644 --- a/spec/features/boards/user_visits_board_spec.rb +++ b/spec/features/boards/user_visits_board_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'User visits issue boards', :js do +RSpec.describe 'User visits issue boards', :js, feature_category: :team_planning do using RSpec::Parameterized::TableSyntax let_it_be(:group) { create_default(:group, :public) } diff --git a/spec/features/file_uploads/attachment_spec.rb b/spec/features/file_uploads/attachment_spec.rb index 41da0e9fbe0..cff0c0b52b4 100644 --- a/spec/features/file_uploads/attachment_spec.rb +++ b/spec/features/file_uploads/attachment_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'Upload an attachment', :api, :js do +RSpec.describe 'Upload an attachment', :api, :js, feature_category: :projects do include_context 'file upload requests helpers' let_it_be(:project) { create(:project) } diff --git a/spec/features/file_uploads/ci_artifact_spec.rb b/spec/features/file_uploads/ci_artifact_spec.rb index 4f3b6c90ad4..420329cc952 100644 --- a/spec/features/file_uploads/ci_artifact_spec.rb +++ b/spec/features/file_uploads/ci_artifact_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'Upload ci artifact', :api, :js do +RSpec.describe 'Upload ci artifact', :api, :js, feature_category: :build_artifacts do include_context 'file upload requests helpers' let_it_be(:user) { create(:user, :admin) } diff --git a/spec/features/file_uploads/git_lfs_spec.rb b/spec/features/file_uploads/git_lfs_spec.rb index 8d15c5c33f7..6af4bef2ec4 100644 --- a/spec/features/file_uploads/git_lfs_spec.rb +++ b/spec/features/file_uploads/git_lfs_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'Upload a git lfs object', :js do +RSpec.describe 'Upload a git lfs object', :js, feature_category: :source_code_management do include_context 'file upload requests helpers' let_it_be(:project) { create(:project) } diff --git a/spec/features/file_uploads/graphql_add_design_spec.rb b/spec/features/file_uploads/graphql_add_design_spec.rb index 17fbf5f6838..0b61c952b55 100644 --- a/spec/features/file_uploads/graphql_add_design_spec.rb +++ b/spec/features/file_uploads/graphql_add_design_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'Upload a design through graphQL', :js do +RSpec.describe 'Upload a design through graphQL', :js, feature_category: :design_management do include_context 'file upload requests helpers' let_it_be(:query) do diff --git a/spec/features/file_uploads/group_import_spec.rb b/spec/features/file_uploads/group_import_spec.rb index a8592f99bd6..f5082e31c06 100644 --- a/spec/features/file_uploads/group_import_spec.rb +++ b/spec/features/file_uploads/group_import_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'Upload a group export archive', :api, :js do +RSpec.describe 'Upload a group export archive', :api, :js, feature_category: :subgroups do include_context 'file upload requests helpers' let_it_be(:user) { create(:user, :admin) } diff --git a/spec/features/file_uploads/maven_package_spec.rb b/spec/features/file_uploads/maven_package_spec.rb index 70302142fa2..8a8bac53613 100644 --- a/spec/features/file_uploads/maven_package_spec.rb +++ b/spec/features/file_uploads/maven_package_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'Upload a maven package', :api, :js do +RSpec.describe 'Upload a maven package', :api, :js, feature_category: :package_registry do include_context 'file upload requests helpers' let_it_be(:project) { create(:project) } diff --git a/spec/features/file_uploads/multipart_invalid_uploads_spec.rb b/spec/features/file_uploads/multipart_invalid_uploads_spec.rb index cff8b4e61a5..8d86c8fa6da 100644 --- a/spec/features/file_uploads/multipart_invalid_uploads_spec.rb +++ b/spec/features/file_uploads/multipart_invalid_uploads_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'Invalid uploads that must be rejected', :api, :js do +RSpec.describe 'Invalid uploads that must be rejected', :api, :js, feature_category: :package_registry do include_context 'file upload requests helpers' let_it_be(:project) { create(:project) } diff --git a/spec/features/file_uploads/nuget_package_spec.rb b/spec/features/file_uploads/nuget_package_spec.rb index cbffd34d4ab..0dc48114e9a 100644 --- a/spec/features/file_uploads/nuget_package_spec.rb +++ b/spec/features/file_uploads/nuget_package_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'Upload a nuget package', :api, :js do +RSpec.describe 'Upload a nuget package', :api, :js, feature_category: :package_registry do include_context 'file upload requests helpers' let_it_be(:project) { create(:project) } diff --git a/spec/features/file_uploads/project_import_spec.rb b/spec/features/file_uploads/project_import_spec.rb index 82b6f490d2a..c261834206d 100644 --- a/spec/features/file_uploads/project_import_spec.rb +++ b/spec/features/file_uploads/project_import_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'Upload a project export archive', :api, :js do +RSpec.describe 'Upload a project export archive', :api, :js, feature_category: :projects do include_context 'file upload requests helpers' let_it_be(:user) { create(:user, :admin) } diff --git a/spec/features/file_uploads/rubygem_package_spec.rb b/spec/features/file_uploads/rubygem_package_spec.rb index f91fb407b28..9c4512e4eab 100644 --- a/spec/features/file_uploads/rubygem_package_spec.rb +++ b/spec/features/file_uploads/rubygem_package_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'Upload a RubyGems package', :api, :js do +RSpec.describe 'Upload a RubyGems package', :api, :js, feature_category: :package_registry do include_context 'file upload requests helpers' let_it_be(:project) { create(:project) } diff --git a/spec/features/file_uploads/user_avatar_spec.rb b/spec/features/file_uploads/user_avatar_spec.rb index 34cfb4a4128..06501e09866 100644 --- a/spec/features/file_uploads/user_avatar_spec.rb +++ b/spec/features/file_uploads/user_avatar_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' -RSpec.describe 'Upload a user avatar', :js do +RSpec.describe 'Upload a user avatar', :js, feature_category: :users do let_it_be(:user, reload: true) { create(:user) } let(:file) { fixture_file_upload('spec/fixtures/banana_sample.gif') } diff --git a/spec/models/ci/bridge_spec.rb b/spec/models/ci/bridge_spec.rb index df24c92149d..fcbb4b97a75 100644 --- a/spec/models/ci/bridge_spec.rb +++ b/spec/models/ci/bridge_spec.rb @@ -21,8 +21,8 @@ RSpec.describe Ci::Bridge do { trigger: { project: 'my/project', branch: 'master' } } end - it 'has many sourced pipelines' do - expect(bridge).to have_many(:sourced_pipelines) + it 'has one sourced pipeline' do + expect(bridge).to have_one(:sourced_pipeline) end it_behaves_like 'has ID tokens', :ci_bridge diff --git a/spec/models/ci/build_spec.rb b/spec/models/ci/build_spec.rb index 9269b341627..22fa020ad02 100644 --- a/spec/models/ci/build_spec.rb +++ b/spec/models/ci/build_spec.rb @@ -24,7 +24,6 @@ RSpec.describe Ci::Build do it { is_expected.to belong_to(:erased_by) } it { is_expected.to have_many(:needs) } - it { is_expected.to have_many(:sourced_pipelines) } it { is_expected.to have_one(:sourced_pipeline) } it { is_expected.to have_many(:job_variables) } it { is_expected.to have_many(:report_results) } diff --git a/spec/models/ci/processable_spec.rb b/spec/models/ci/processable_spec.rb index e62e5f84a6d..004716fffc4 100644 --- a/spec/models/ci/processable_spec.rb +++ b/spec/models/ci/processable_spec.rb @@ -81,7 +81,7 @@ RSpec.describe Ci::Processable do commit_id deployment erased_by_id project_id runner_id tag_taggings taggings tags trigger_request_id user_id auto_canceled_by_id retried failure_reason - sourced_pipelines sourced_pipeline artifacts_file_store artifacts_metadata_store + sourced_pipeline artifacts_file_store artifacts_metadata_store metadata runner_session trace_chunks upstream_pipeline_id artifacts_file artifacts_metadata artifacts_size commands resource resource_group_id processed security_scans author diff --git a/spec/services/ci/create_downstream_pipeline_service_spec.rb b/spec/services/ci/create_downstream_pipeline_service_spec.rb index 9c02c5218f1..751d976dd10 100644 --- a/spec/services/ci/create_downstream_pipeline_service_spec.rb +++ b/spec/services/ci/create_downstream_pipeline_service_spec.rb @@ -110,7 +110,7 @@ RSpec.describe Ci::CreateDownstreamPipelineService, '#execute' do expect(pipeline.user).to eq bridge.user expect(pipeline.project).to eq downstream_project - expect(bridge.sourced_pipelines.first.pipeline).to eq pipeline + expect(bridge.reload.sourced_pipeline.pipeline).to eq pipeline expect(pipeline.triggered_by_pipeline).to eq upstream_pipeline expect(pipeline.source_bridge).to eq bridge expect(pipeline.source_bridge).to be_a ::Ci::Bridge @@ -131,7 +131,7 @@ RSpec.describe Ci::CreateDownstreamPipelineService, '#execute' do context 'when bridge job has already any downstream pipelines' do before do - bridge.sourced_pipelines.create!( + bridge.create_sourced_pipeline!( source_pipeline: bridge.pipeline, source_project: bridge.project, project: bridge.project, @@ -178,7 +178,7 @@ RSpec.describe Ci::CreateDownstreamPipelineService, '#execute' do expect(pipeline.user).to eq bridge.user expect(pipeline.project).to eq downstream_project - expect(bridge.sourced_pipelines.first.pipeline).to eq pipeline + expect(bridge.reload.sourced_pipeline.pipeline).to eq pipeline expect(pipeline.triggered_by_pipeline).to eq upstream_pipeline expect(pipeline.source_bridge).to eq bridge expect(pipeline.source_bridge).to be_a ::Ci::Bridge @@ -231,7 +231,7 @@ RSpec.describe Ci::CreateDownstreamPipelineService, '#execute' do expect(pipeline.builds.map(&:name)).to match_array(%w[rspec echo]) expect(pipeline.user).to eq bridge.user expect(pipeline.project).to eq bridge.project - expect(bridge.sourced_pipelines.first.pipeline).to eq pipeline + expect(bridge.reload.sourced_pipeline.pipeline).to eq pipeline expect(pipeline.triggered_by_pipeline).to eq upstream_pipeline expect(pipeline.source_bridge).to eq bridge expect(pipeline.source_bridge).to be_a ::Ci::Bridge diff --git a/spec/services/ci/pipeline_trigger_service_spec.rb b/spec/services/ci/pipeline_trigger_service_spec.rb index 4b3e774ff3c..d8ea546742b 100644 --- a/spec/services/ci/pipeline_trigger_service_spec.rb +++ b/spec/services/ci/pipeline_trigger_service_spec.rb @@ -225,7 +225,7 @@ RSpec.describe Ci::PipelineTriggerService do expect { result }.to change { Ci::PipelineVariable.count }.by(2) .and change { Ci::Sources::Pipeline.count }.by(1) expect(result[:pipeline].variables.map { |v| { v.key => v.value } }.first).to eq(variables) - expect(job.sourced_pipelines.last.pipeline_id).to eq(result[:pipeline].id) + expect(job.sourced_pipeline.pipeline_id).to eq(result[:pipeline].id) end end diff --git a/spec/support/rspec_order_todo.yml b/spec/support/rspec_order_todo.yml index a07f049fbbe..d2367f93d41 100644 --- a/spec/support/rspec_order_todo.yml +++ b/spec/support/rspec_order_todo.yml @@ -1482,7 +1482,6 @@ - './ee/spec/lib/gitlab/geo/log_cursor/daemon_spec.rb' - './ee/spec/lib/gitlab/geo/log_cursor/event_logs_spec.rb' - './ee/spec/lib/gitlab/geo/log_cursor/events/cache_invalidation_event_spec.rb' -- './ee/spec/lib/gitlab/geo/log_cursor/events/container_repository_updated_event_spec.rb' - './ee/spec/lib/gitlab/geo/log_cursor/events/design_repository_updated_event_spec.rb' - './ee/spec/lib/gitlab/geo/log_cursor/events/event_spec.rb' - './ee/spec/lib/gitlab/geo/log_cursor/events/hashed_storage_attachments_event_spec.rb' @@ -1875,7 +1874,6 @@ - './ee/spec/models/geo/cache_invalidation_event_spec.rb' - './ee/spec/models/geo/ci_secure_file_registry_spec.rb' - './ee/spec/models/geo/container_repository_registry_spec.rb' -- './ee/spec/models/geo/container_repository_updated_event_spec.rb' - './ee/spec/models/geo/deleted_project_spec.rb' - './ee/spec/models/geo/design_registry_spec.rb' - './ee/spec/models/geo/event_log_spec.rb' @@ -2860,7 +2858,6 @@ - './ee/spec/services/geo/cache_invalidation_event_store_spec.rb' - './ee/spec/services/geo/container_repository_sync_service_spec.rb' - './ee/spec/services/geo/container_repository_sync_spec.rb' -- './ee/spec/services/geo/container_repository_updated_event_store_spec.rb' - './ee/spec/services/geo/design_repository_sync_service_spec.rb' - './ee/spec/services/geo/event_service_spec.rb' - './ee/spec/services/geo/file_registry_removal_service_spec.rb' |