Commit de156840 authored by Andrew Fontaine's avatar Andrew Fontaine

Merge branch '328538-remove-needs-flag' into 'master'

Remove pipelineGraphLayersView feature flag [RUN AS-IF-FOSS] [RUN ALL RSPEC]

See merge request gitlab-org/gitlab!67969
parents 4b98dc00 d08880a4
...@@ -4,7 +4,6 @@ import getPipelineDetails from 'shared_queries/pipelines/get_pipeline_details.qu ...@@ -4,7 +4,6 @@ import getPipelineDetails from 'shared_queries/pipelines/get_pipeline_details.qu
import getUserCallouts from '~/graphql_shared/queries/get_user_callouts.query.graphql'; import getUserCallouts from '~/graphql_shared/queries/get_user_callouts.query.graphql';
import { __ } from '~/locale'; import { __ } from '~/locale';
import LocalStorageSync from '~/vue_shared/components/local_storage_sync.vue'; import LocalStorageSync from '~/vue_shared/components/local_storage_sync.vue';
import glFeatureFlagMixin from '~/vue_shared/mixins/gl_feature_flags_mixin';
import { DEFAULT, DRAW_FAILURE, LOAD_FAILURE } from '../../constants'; import { DEFAULT, DRAW_FAILURE, LOAD_FAILURE } from '../../constants';
import DismissPipelineGraphCallout from '../../graphql/mutations/dismiss_pipeline_notification.graphql'; import DismissPipelineGraphCallout from '../../graphql/mutations/dismiss_pipeline_notification.graphql';
import getPipelineQuery from '../../graphql/queries/get_pipeline_header_data.query.graphql'; import getPipelineQuery from '../../graphql/queries/get_pipeline_header_data.query.graphql';
...@@ -32,7 +31,6 @@ export default { ...@@ -32,7 +31,6 @@ export default {
LocalStorageSync, LocalStorageSync,
PipelineGraph, PipelineGraph,
}, },
mixins: [glFeatureFlagMixin()],
inject: { inject: {
graphqlResourceEtag: { graphqlResourceEtag: {
default: '', default: '',
...@@ -200,7 +198,7 @@ export default { ...@@ -200,7 +198,7 @@ export default {
return this.$apollo.queries.pipeline.loading && !this.pipeline; return this.$apollo.queries.pipeline.loading && !this.pipeline;
}, },
showGraphViewSelector() { showGraphViewSelector() {
return Boolean(this.glFeatures.pipelineGraphLayersView && this.pipeline?.usesNeeds); return this.pipeline?.usesNeeds;
}, },
}, },
mounted() { mounted() {
......
...@@ -13,7 +13,6 @@ class Projects::PipelinesController < Projects::ApplicationController ...@@ -13,7 +13,6 @@ class Projects::PipelinesController < Projects::ApplicationController
before_action :authorize_create_pipeline!, only: [:new, :create, :config_variables] before_action :authorize_create_pipeline!, only: [:new, :create, :config_variables]
before_action :authorize_update_pipeline!, only: [:retry, :cancel] before_action :authorize_update_pipeline!, only: [:retry, :cancel]
before_action do before_action do
push_frontend_feature_flag(:pipeline_graph_layers_view, project, type: :development, default_enabled: :yaml)
push_frontend_feature_flag(:graphql_pipeline_details, project, type: :development, default_enabled: :yaml) push_frontend_feature_flag(:graphql_pipeline_details, project, type: :development, default_enabled: :yaml)
push_frontend_feature_flag(:graphql_pipeline_details_users, current_user, type: :development, default_enabled: :yaml) push_frontend_feature_flag(:graphql_pipeline_details_users, current_user, type: :development, default_enabled: :yaml)
end end
......
---
name: pipeline_graph_layers_view
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/56865
rollout_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/328538
milestone: '13.11'
type: development
group: group::pipeline authoring
default_enabled: true
...@@ -363,9 +363,7 @@ you visualize the entire pipeline, including all cross-project inter-dependencie ...@@ -363,9 +363,7 @@ you visualize the entire pipeline, including all cross-project inter-dependencie
> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/298973) in GitLab 13.12. > - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/298973) in GitLab 13.12.
> - [Deployed behind a feature flag](../../user/feature_flags.md), disabled by default. > - [Deployed behind a feature flag](../../user/feature_flags.md), disabled by default.
> - [Enabled by default](https://gitlab.com/gitlab-org/gitlab/-/issues/328538) in GitLab 13.12. > - [Enabled by default](https://gitlab.com/gitlab-org/gitlab/-/issues/328538) in GitLab 13.12.
> - Enabled on GitLab.com. > - [Feature flag removed](https://gitlab.com/gitlab-org/gitlab/-/issues/328538) in GitLab 14.2.
> - Recommended for production use.
> - To disable in GitLab self-managed instances, ask a GitLab administrator to [disable it](#enable-or-disable-job-dependency-view). **(FREE SELF)**
This in-development feature might not be available for your use. There can be This in-development feature might not be available for your use. There can be
[risks when enabling features still in development](../../administration/feature_flags.md#risks-when-enabling-features-still-in-development). [risks when enabling features still in development](../../administration/feature_flags.md#risks-when-enabling-features-still-in-development).
...@@ -391,24 +389,6 @@ To see the full `needs` dependency tree for a job, hover over it: ...@@ -391,24 +389,6 @@ To see the full `needs` dependency tree for a job, hover over it:
![single job dependency tree highlighted](img/pipelines_graph_dependency_view_hover_v13_12.png) ![single job dependency tree highlighted](img/pipelines_graph_dependency_view_hover_v13_12.png)
#### Enable or disable job dependency view **(FREE SELF)**
The job dependency view is deployed behind a feature flag that is **enabled by default**.
[GitLab administrators with access to the GitLab Rails console](../../administration/feature_flags.md)
can disable it.
To enable it:
```ruby
Feature.enable(:pipeline_graph_layers_view)
```
To disable it:
```ruby
Feature.disable(:pipeline_graph_layers_view)
```
### Pipeline mini graphs ### Pipeline mini graphs
Pipeline mini graphs take less space and can tell you at a Pipeline mini graphs take less space and can tell you at a
......
...@@ -267,28 +267,11 @@ describe('Pipeline graph wrapper', () => { ...@@ -267,28 +267,11 @@ describe('Pipeline graph wrapper', () => {
}); });
describe('view dropdown', () => { describe('view dropdown', () => {
describe('when pipelineGraphLayersView feature flag is off', () => { describe('default', () => {
beforeEach(async () => {
createComponentWithApollo();
jest.runOnlyPendingTimers();
await wrapper.vm.$nextTick();
});
it('does not appear', () => {
expect(getViewSelector().exists()).toBe(false);
});
});
describe('when pipelineGraphLayersView feature flag is on', () => {
let layersFn; let layersFn;
beforeEach(async () => { beforeEach(async () => {
layersFn = jest.spyOn(parsingUtils, 'listByLayers'); layersFn = jest.spyOn(parsingUtils, 'listByLayers');
createComponentWithApollo({ createComponentWithApollo({
provide: {
glFeatures: {
pipelineGraphLayersView: true,
},
},
mountFn: mount, mountFn: mount,
}); });
...@@ -326,14 +309,9 @@ describe('Pipeline graph wrapper', () => { ...@@ -326,14 +309,9 @@ describe('Pipeline graph wrapper', () => {
}); });
}); });
describe('when pipelineGraphLayersView feature flag is on and layers view is selected', () => { describe('when layers view is selected', () => {
beforeEach(async () => { beforeEach(async () => {
createComponentWithApollo({ createComponentWithApollo({
provide: {
glFeatures: {
pipelineGraphLayersView: true,
},
},
data: { data: {
currentViewType: LAYER_VIEW, currentViewType: LAYER_VIEW,
}, },
...@@ -356,14 +334,9 @@ describe('Pipeline graph wrapper', () => { ...@@ -356,14 +334,9 @@ describe('Pipeline graph wrapper', () => {
}); });
}); });
describe('when pipelineGraphLayersView feature flag is on, layers view is selected, and links are active', () => { describe('when layers view is selected, and links are active', () => {
beforeEach(async () => { beforeEach(async () => {
createComponentWithApollo({ createComponentWithApollo({
provide: {
glFeatures: {
pipelineGraphLayersView: true,
},
},
data: { data: {
currentViewType: LAYER_VIEW, currentViewType: LAYER_VIEW,
showLinks: true, showLinks: true,
...@@ -384,11 +357,6 @@ describe('Pipeline graph wrapper', () => { ...@@ -384,11 +357,6 @@ describe('Pipeline graph wrapper', () => {
describe('when hover tip would otherwise show, but it has been previously dismissed', () => { describe('when hover tip would otherwise show, but it has been previously dismissed', () => {
beforeEach(async () => { beforeEach(async () => {
createComponentWithApollo({ createComponentWithApollo({
provide: {
glFeatures: {
pipelineGraphLayersView: true,
},
},
data: { data: {
currentViewType: LAYER_VIEW, currentViewType: LAYER_VIEW,
showLinks: true, showLinks: true,
...@@ -412,11 +380,6 @@ describe('Pipeline graph wrapper', () => { ...@@ -412,11 +380,6 @@ describe('Pipeline graph wrapper', () => {
localStorage.setItem(VIEW_TYPE_KEY, LAYER_VIEW); localStorage.setItem(VIEW_TYPE_KEY, LAYER_VIEW);
createComponentWithApollo({ createComponentWithApollo({
provide: {
glFeatures: {
pipelineGraphLayersView: true,
},
},
mountFn: mount, mountFn: mount,
}); });
...@@ -444,11 +407,6 @@ describe('Pipeline graph wrapper', () => { ...@@ -444,11 +407,6 @@ describe('Pipeline graph wrapper', () => {
localStorage.setItem(VIEW_TYPE_KEY, LAYER_VIEW); localStorage.setItem(VIEW_TYPE_KEY, LAYER_VIEW);
createComponentWithApollo({ createComponentWithApollo({
provide: {
glFeatures: {
pipelineGraphLayersView: true,
},
},
mountFn: mount, mountFn: mount,
getPipelineDetailsHandler: jest.fn().mockResolvedValue(nonNeedsResponse), getPipelineDetailsHandler: jest.fn().mockResolvedValue(nonNeedsResponse),
}); });
...@@ -472,11 +430,6 @@ describe('Pipeline graph wrapper', () => { ...@@ -472,11 +430,6 @@ describe('Pipeline graph wrapper', () => {
nonNeedsResponse.data.project.pipeline.usesNeeds = false; nonNeedsResponse.data.project.pipeline.usesNeeds = false;
createComponentWithApollo({ createComponentWithApollo({
provide: {
glFeatures: {
pipelineGraphLayersView: true,
},
},
mountFn: mount, mountFn: mount,
getPipelineDetailsHandler: jest.fn().mockResolvedValue(nonNeedsResponse), getPipelineDetailsHandler: jest.fn().mockResolvedValue(nonNeedsResponse),
}); });
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment