Commit 3697c7b9 authored by Adam Hegyi's avatar Adam Hegyi

Make group_level_cycle_analytics enabled by default

parent 93fa7a0e
...@@ -25,12 +25,7 @@ calculates a separate median for each stage. ...@@ -25,12 +25,7 @@ calculates a separate median for each stage.
Value Stream Analytics is available: Value Stream Analytics is available:
- From GitLab 12.3, at the group level in the analytics workspace (top navigation bar) at - From GitLab 12.9, at the group level via **Group > Analytics > Value Stream**. **(PREMIUM)**
**Analytics > Value Stream Analytics**. **(PREMIUM)**
In the future, multiple groups will be selectable which will effectively make this an
instance-level feature.
- At the project level via **Project > Value Stream Analytics**. - At the project level via **Project > Value Stream Analytics**.
There are seven stages that are tracked as part of the Value Stream Analytics calculations. There are seven stages that are tracked as part of the Value Stream Analytics calculations.
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
class Analytics::AnalyticsController < Analytics::ApplicationController class Analytics::AnalyticsController < Analytics::ApplicationController
def index def index
if Feature.disabled?(:group_level_cycle_analytics) && Gitlab::Analytics.cycle_analytics_enabled? if Feature.disabled?(:group_level_cycle_analytics, default_enabled: true) && Gitlab::Analytics.cycle_analytics_enabled?
redirect_to analytics_cycle_analytics_path redirect_to analytics_cycle_analytics_path
elsif can?(current_user, :read_instance_statistics) elsif can?(current_user, :read_instance_statistics)
redirect_to instance_statistics_dev_ops_score_index_path redirect_to instance_statistics_dev_ops_score_index_path
......
...@@ -38,7 +38,7 @@ module EE ...@@ -38,7 +38,7 @@ module EE
end end
def group_cycle_analytics_navbar_link(group, current_user) def group_cycle_analytics_navbar_link(group, current_user)
return unless ::Feature.enabled?(:group_level_cycle_analytics) return unless ::Feature.enabled?(:group_level_cycle_analytics, default_enabled: true)
return unless group_sidebar_link?(:cycle_analytics) return unless group_sidebar_link?(:cycle_analytics)
navbar_sub_item( navbar_sub_item(
......
...@@ -32,7 +32,7 @@ module EE ...@@ -32,7 +32,7 @@ module EE
end end
def analytics_nav_url def analytics_nav_url
if ::Feature.disabled?(:group_level_cycle_analytics) && ::Gitlab::Analytics.any_features_enabled? if ::Feature.disabled?(:group_level_cycle_analytics, default_enabled: true) && ::Gitlab::Analytics.any_features_enabled?
return analytics_root_path return analytics_root_path
end end
...@@ -48,7 +48,7 @@ module EE ...@@ -48,7 +48,7 @@ module EE
override :get_dashboard_nav_links override :get_dashboard_nav_links
def get_dashboard_nav_links def get_dashboard_nav_links
super.tap do |links| super.tap do |links|
links << :analytics if ::Feature.disabled?(:group_level_cycle_analytics) && ::Gitlab::Analytics.any_features_enabled? links << :analytics if ::Feature.disabled?(:group_level_cycle_analytics, default_enabled: true) && ::Gitlab::Analytics.any_features_enabled?
if can?(current_user, :read_operations_dashboard) if can?(current_user, :read_operations_dashboard)
links << :environments if ::Feature.enabled?(:environments_dashboard, current_user, default_enabled: true) links << :environments if ::Feature.enabled?(:environments_dashboard, current_user, default_enabled: true)
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
= sprite_icon('chart', size: 24) = sprite_icon('chart', size: 24)
.sidebar-context-title= _('Analytics') .sidebar-context-title= _('Analytics')
%ul.sidebar-top-level-items %ul.sidebar-top-level-items
- if Feature.disabled?(:group_level_cycle_analytics) && Gitlab::Analytics.cycle_analytics_enabled? - if Feature.disabled?(:group_level_cycle_analytics, default_enabled: true) && Gitlab::Analytics.cycle_analytics_enabled?
= nav_link(controller: :cycle_analytics) do = nav_link(controller: :cycle_analytics) do
= link_to analytics_cycle_analytics_path, class: 'qa-sidebar-cycle-analytics' do = link_to analytics_cycle_analytics_path, class: 'qa-sidebar-cycle-analytics' do
.nav-icon-container .nav-icon-container
......
---
title: Move Value Stream Analytics to the group level
merge_request: 27304
author:
type: changed
...@@ -33,7 +33,7 @@ constraints(::Constraints::GroupUrlConstrainer.new) do ...@@ -33,7 +33,7 @@ constraints(::Constraints::GroupUrlConstrainer.new) do
end end
namespace :analytics do namespace :analytics do
resource :productivity_analytics, only: :show, constraints: -> (req) { Gitlab::Analytics.productivity_analytics_enabled? } resource :productivity_analytics, only: :show, constraints: -> (req) { Gitlab::Analytics.productivity_analytics_enabled? }
resource :cycle_analytics, path: 'value_stream_analytics', only: :show, constraints: -> (req) { Feature.enabled?(:group_level_cycle_analytics) && Gitlab::Analytics.cycle_analytics_enabled? } resource :cycle_analytics, path: 'value_stream_analytics', only: :show, constraints: -> (req) { Feature.enabled?(:group_level_cycle_analytics, default_enabled: true) && Gitlab::Analytics.cycle_analytics_enabled? }
end end
resource :ldap, only: [] do resource :ldap, only: [] do
......
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