Add latest changes from gitlab-org/gitlab@master

This commit is contained in:
GitLab Bot 2019-12-04 15:11:23 +00:00
parent 98420be3dd
commit 8d3aee3636
25 changed files with 119 additions and 60 deletions

1
.gitignore vendored
View File

@ -84,3 +84,4 @@ jsdoc/
.overcommit.yml
.projections.json
/qa/.rakeTasks
webpack-dev-server.json

View File

@ -245,5 +245,9 @@ webpack-dev-server:
variables:
WEBPACK_MEMORY_TEST: "true"
script:
- node --version
- node --expose-gc node_modules/.bin/webpack-dev-server --config config/webpack.config.js
artifacts:
name: webpack-dev-server
expire_in: 31d
paths:
- webpack-dev-server.json

View File

@ -5,7 +5,7 @@ module DiffPositionableNote
included do
delegate :on_text?, :on_image?, to: :position, allow_nil: true
before_validation :set_original_position, on: :create
before_validation :update_position, on: :create, if: :on_text?
before_validation :update_position, on: :create, if: :on_text?, unless: :importing?
serialize :original_position, Gitlab::Diff::Position # rubocop:disable Cop/ActiveRecordSerialize
serialize :position, Gitlab::Diff::Position # rubocop:disable Cop/ActiveRecordSerialize

View File

@ -21,8 +21,8 @@ class DiffNote < Note
validate :positions_complete
validate :verify_supported
before_validation :set_line_code, if: :on_text?
after_save :keep_around_commits
before_validation :set_line_code, if: :on_text?, unless: :importing?
after_save :keep_around_commits, unless: :importing?
after_commit :create_diff_file, on: :create
def discussion_class(*)

View File

@ -242,7 +242,7 @@ class MergeRequest < ApplicationRecord
ignore_column :state, remove_with: '12.7', remove_after: '2019-12-22'
after_save :keep_around_commit
after_save :keep_around_commit, unless: :importing?
alias_attribute :project, :target_project
alias_attribute :project_id, :target_project_id

View File

@ -164,7 +164,7 @@ class MergeRequestDiff < ApplicationRecord
# hooks that run when an attribute was changed are run twice.
reset
keep_around_commits
keep_around_commits unless importing?
end
def set_as_latest_diff

View File

@ -155,9 +155,9 @@ class Note < ApplicationRecord
after_initialize :ensure_discussion_id
before_validation :nullify_blank_type, :nullify_blank_line_code
before_validation :set_discussion_id, on: :create
after_save :keep_around_commit, if: :for_project_noteable?
after_save :expire_etag_cache
after_save :touch_noteable
after_save :keep_around_commit, if: :for_project_noteable?, unless: :importing?
after_save :expire_etag_cache, unless: :importing?
after_save :touch_noteable, unless: :importing?
after_destroy :expire_etag_cache
class << self

View File

@ -2,12 +2,12 @@
.user-callout{ data: { uid: 'dev_ops_score_intro_callout_dismissed' } }
.bordered-box.landing.content-block
%button.btn.btn-default.close.js-close-callout{ type: 'button',
'aria-label' => _('Dismiss ConvDev introduction') }
'aria-label' => _('Dismiss DevOps Score introduction') }
= icon('times', class: 'dismiss-icon', 'aria-hidden' => 'true')
.user-callout-copy
%h4
= _('Introducing Your Conversational Development Index')
= _('Introducing Your DevOps Score')
%p
= _('Your Conversational Development Index gives an overview of how you are using GitLab from a feature perspective. View how you compare with other organizations, discover features you are not using, and learn best practices through blog posts and white papers.')
.svg-container.convdev
= _('Your DevOps Score gives an overview of how you are using GitLab from a feature perspective. View how you compare with other organizations, discover features you are not using, and learn best practices through blog posts and white papers.')
.svg-container.devops
= custom_icon('dev_ops_score_overview')

View File

@ -1,4 +1,4 @@
- page_title _('ConvDev Index')
- page_title _('DevOps Score')
- usage_ping_enabled = Gitlab::CurrentSettings.usage_ping_enabled
.container

View File

@ -11,12 +11,12 @@
.nav-icon-container
= sprite_icon('comment')
%span.nav-item-name
= _('ConvDev Index')
= _('DevOps Score')
%ul.sidebar-sub-level-items.is-fly-out-only
= nav_link(controller: :dev_ops_score, html_options: { class: "fly-out-top-item" } ) do
= link_to instance_statistics_dev_ops_score_index_path do
%strong.fly-out-top-item-name
= _('ConvDev Index')
= _('DevOps Score')
- if Gitlab::CurrentSettings.usage_ping_enabled
= nav_link(controller: :cohorts) do

View File

@ -0,0 +1,5 @@
---
title: Add services for 'soft-delete for groups' feature
merge_request: 19358
author:
type: added

View File

@ -0,0 +1,5 @@
---
title: removes references of BoardService
merge_request: 20879
author: nuwe1
type: other

View File

@ -1,5 +1,6 @@
const path = require('path');
const glob = require('glob');
const fs = require('fs');
const webpack = require('webpack');
const VueLoaderPlugin = require('vue-loader/lib/plugin');
const StatsWriterPlugin = require('webpack-stats-plugin').StatsWriterPlugin;
@ -23,6 +24,7 @@ const NO_SOURCEMAPS = process.env.NO_SOURCEMAPS;
const VUE_VERSION = require('vue/package.json').version;
const VUE_LOADER_VERSION = require('vue-loader/package.json').version;
const WEBPACK_VERSION = require('webpack/package.json').version;
const devtool = IS_PRODUCTION ? 'source-map' : 'cheap-module-eval-source-map';
@ -359,6 +361,21 @@ module.exports = {
console.log(`Webpack heap size: ${toMB(memoryUsage)} MB`);
const webpackStatistics = {
memoryUsage,
date: Date.now(), // milliseconds
commitSHA: process.env.CI_COMMIT_SHA,
nodeVersion: process.versions.node,
webpackVersion: WEBPACK_VERSION,
};
console.log(webpackStatistics);
fs.writeFileSync(
path.join(ROOT_PATH, 'webpack-dev-server.json'),
JSON.stringify(webpackStatistics),
);
// exit in case we're running webpack-dev-server
IS_DEV_SERVER && process.exit();
});

View File

@ -158,7 +158,10 @@ If you select `Limit namespaces and projects that can be indexed`, more options
You can select namespaces and projects to index exclusively. Please note that if the namespace is a group it will include
any sub-groups and projects belonging to those sub-groups to be indexed as well.
Elasticsearch only provides cross-group code/commit search (global) if all name-spaces are indexed. In this particular scenario where only a subset of namespaces are indexed, a global search will not provide a code or commit scope. This will be possible only in the scope of an indexed namespace. Currently there is no way to code/commit search in multiple indexed namespaces (when only a subset of namespaces has been indexed). For example if two groups are indexed, there is no way to run a single code search on both. You can only run a code search on the first group and then on the second.
You can filter the selection dropdown by writing part of the namespace or project name you're interested in.
![limit namespace filter](img/limit_namespace_filter.png)
NOTE: **Note**:
@ -502,6 +505,9 @@ Here are some common pitfalls and how to overcome them:
If you see `Elasticsearch::Model::Response::Records`, you are using Elasticsearch.
NOTE: **Note**:
The above instructions are used to verify that GitLab is using Elasticsearch only when indexing all namespaces. This is not to be used for scenarios that only index a [subset of namespaces](https://docs.gitlab.com/ee/integration/elasticsearch.html#limiting-namespaces-and-projects).
- **I updated GitLab and now I can't find anything**
We continuously make updates to our indexing strategies and aim to support
@ -522,6 +528,9 @@ Here are some common pitfalls and how to overcome them:
pp s.search_objects.to_a
```
NOTE: **Note**:
The above instructions are not to be used for scenarios that only index a [subset of namespaces](https://docs.gitlab.com/ee/integration/elasticsearch.html#limiting-namespaces-and-projects).
See [Elasticsearch Index Scopes](#elasticsearch-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**

View File

@ -1,5 +0,0 @@
---
redirect_to: '../../instance_statistics/convdev.md'
---
This document was moved to [another location](../../instance_statistics/convdev.md).

View File

@ -0,0 +1,5 @@
---
redirect_to: '../../instance_statistics/dev_ops_score.md'
---
This document was moved to [another location](../../instance_statistics/dev_ops_score.md).

View File

@ -14,6 +14,17 @@ Below are the fingerprints for GitLab.com's SSH host keys.
| ED25519 | `2e:65:6a:c8:cf:bf:b2:8b:9a:bd:6d:9f:11:5c:12:16` | `eUXGGm1YGsMAS7vkcx6JOJdOGHPem5gQp4taiCfCLB8` |
| RSA | `b6:03:0e:39:97:9e:d0:e7:24:ce:a3:77:3e:01:42:09` | `ROQFvPThGrW4RuWLoL9tq9I9zJ42fK4XywyRtbOz/EQ` |
## SSH `known_hosts` entries
Add the following to `.ssh/known_hosts` to skip manual fingerprint
confirmation in SSH:
```
gitlab.com ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIAfuCHKVTjquxvt6CM6tdG4SLp1Btn/nOeHHE5UOzRdf
gitlab.com ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCsj2bNKTBSpIYDEGk9KxsGh3mySTRgMtXL583qmBpzeQ+jqCMRgBqB98u3z++J1sKlXHWfM9dyhSevkMwSbhoR8XIq/U0tCNyokEi/ueaBMCvbcTHhO7FcwzY92WK4Yt0aGROY5qX2UKSeOvuP4D6TPqKF1onrSzH9bx9XUf2lEdWT/ia1NEKjunUqu1xOB/StKDHMoX4/OKyIzuS0q/T1zOATthvasJFoPrAjkohTyaDUz2LN5JoH839hViyEG82yB+MjcFV5MU3N1l1QL3cVUCh93xSaua1N85qivl+siMkPGbO5xR/En4iEY6K2XPASUEMaieWVNTRCtJ4S8H+9
gitlab.com ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBFSMqzJeV9rUzU4kWitGjeR4PWSa29SPqJ1fVkhtj3Hw9xjLVXVYrU9QlYWrOLXBpQ6KWjbjTDTdDkoohFzgbEY=
```
## Mail configuration
GitLab.com sends emails from the `mg.gitlab.com` domain via [Mailgun] and has

View File

@ -1,12 +1,12 @@
# Conversational Development Index
# DevOps Score
> [Introduced](https://gitlab.com/gitlab-org/gitlab-foss/issues/30469) in GitLab 9.3.
> [Renamed from Conversational Development Index](https://gitlab.com/gitlab-org/gitlab/issues/20976) in GitLab 12.6.
NOTE: **Note:**
Your GitLab instance's [usage ping](../admin_area/settings/usage_statistics.md#usage-ping-core-only) must be activated in order to use this feature.
The [Conversational Development](http://conversationaldevelopment.com/2017/04/16/what-is-conversational-development/) Index (ConvDev Index) gives you an overview of your entire
instance's adoption of [Concurrent DevOps](https://about.gitlab.com/concurrent-devops/)
The DevOps Score gives you an overview of your entire instance's adoption of
[Concurrent DevOps](https://about.gitlab.com/concurrent-devops/)
from planning to monitoring.
This displays the usage of these GitLab features over
@ -16,7 +16,7 @@ of top-performing instances based on [usage ping data](../admin_area/settings/us
collected. Your score is compared to the lead score of each feature and then expressed as a percentage at the bottom of said feature.
Your overall index score is an average of all your feature score percentages - this percentage value is presented above all the of features on the page.
![ConvDev index](img/convdev_index.png)
![DevOps Score](img/dev_ops_score.png)
The page also provides helpful links to articles and GitLab docs, to help you
improve your scores.

View File

Before

Width:  |  Height:  |  Size: 84 KiB

After

Width:  |  Height:  |  Size: 84 KiB

View File

@ -12,5 +12,5 @@ and can be accessed via the top bar.
There are two kinds of statistics:
- [Conversational Development (ConvDev) Index](convdev.md): Provides an overview of your entire instance's feature usage.
- [Dev Ops Score](dev_ops_score.md): Provides an overview of your entire instance's feature usage.
- [User Cohorts](user_cohorts.md): Display the monthly cohorts of new users and their activities over time.

View File

@ -1826,9 +1826,15 @@ msgstr ""
msgid "Any Milestone"
msgstr ""
msgid "Any eligible user"
msgstr ""
msgid "Any encrypted tokens"
msgstr ""
msgid "Any member with Developer or higher permissions to the project."
msgstr ""
msgid "Any namespace"
msgstr ""
@ -1936,9 +1942,6 @@ msgid_plural "ApprovalRuleSummary|%{count} approvals required from %{membersCoun
msgstr[0] ""
msgstr[1] ""
msgid "ApprovalRule|All members with Developer role or higher and code owners (if any)"
msgstr ""
msgid "ApprovalRule|Approvers"
msgstr ""
@ -4307,6 +4310,9 @@ msgstr ""
msgid "Code Owners"
msgstr ""
msgid "Code Owners to the merge request changes."
msgstr ""
msgid "Code owner approval is required"
msgstr ""
@ -4737,9 +4743,6 @@ msgstr ""
msgid "Control the maximum concurrency of repository backfill for this secondary node"
msgstr ""
msgid "ConvDev Index"
msgstr ""
msgid "Cookie domain"
msgstr ""
@ -4860,6 +4863,9 @@ msgstr ""
msgid "Could not remove the trigger."
msgstr ""
msgid "Could not restore the group"
msgstr ""
msgid "Could not revoke impersonation token %{token_name}."
msgstr ""
@ -5910,6 +5916,9 @@ msgstr ""
msgid "Detect host keys"
msgstr ""
msgid "DevOps Score"
msgstr ""
msgid "Diff content limits"
msgstr ""
@ -6012,10 +6021,10 @@ msgstr ""
msgid "Dismiss"
msgstr ""
msgid "Dismiss ConvDev introduction"
msgid "Dismiss Cycle Analytics introduction box"
msgstr ""
msgid "Dismiss Cycle Analytics introduction box"
msgid "Dismiss DevOps Score introduction"
msgstr ""
msgid "Dismiss Merge Request promotion"
@ -8675,6 +8684,12 @@ msgstr ""
msgid "Group details"
msgstr ""
msgid "Group has been already marked for deletion"
msgstr ""
msgid "Group has not been marked for deletion"
msgstr ""
msgid "Group info:"
msgstr ""
@ -9579,7 +9594,7 @@ msgstr ""
msgid "Introducing Cycle Analytics"
msgstr ""
msgid "Introducing Your Conversational Development Index"
msgid "Introducing Your DevOps Score"
msgstr ""
msgid "Invalid Git ref"
@ -19351,6 +19366,9 @@ msgstr ""
msgid "Users"
msgstr ""
msgid "Users or groups set as approvers in the project's or merge request's settings."
msgstr ""
msgid "Users outside of license"
msgstr ""
@ -19748,6 +19766,9 @@ msgstr ""
msgid "Whitelist to allow requests to the local network from hooks and services"
msgstr ""
msgid "Who can be an approver?"
msgstr ""
msgid "Who can see this group?"
msgstr ""
@ -19973,6 +19994,9 @@ msgstr ""
msgid "You are not allowed to unlink your primary login account"
msgstr ""
msgid "You are not authorized to perform this action"
msgstr ""
msgid "You are now impersonating %{username}"
msgstr ""
@ -20300,10 +20324,10 @@ msgstr ""
msgid "Your Commit Email will be used for web based operations, such as edits and merges."
msgstr ""
msgid "Your Conversational Development Index gives an overview of how you are using GitLab from a feature perspective. View how you compare with other organizations, discover features you are not using, and learn best practices through blog posts and white papers."
msgid "Your Default Notification Email will be used for account notifications if a %{openingTag}group-specific email address%{closingTag} is not set."
msgstr ""
msgid "Your Default Notification Email will be used for account notifications if a %{openingTag}group-specific email address%{closingTag} is not set."
msgid "Your DevOps Score gives an overview of how you are using GitLab from a feature perspective. View how you compare with other organizations, discover features you are not using, and learn best practices through blog posts and white papers."
msgstr ""
msgid "Your GPG keys (%{count})"

View File

@ -2,7 +2,7 @@
require 'spec_helper'
describe 'Dev Ops Score' do
describe 'DevOps Score' do
before do
sign_in(create(:admin))
end
@ -10,11 +10,11 @@ describe 'Dev Ops Score' do
it 'has dismissable intro callout', :js do
visit instance_statistics_dev_ops_score_index_path
expect(page).to have_content 'Introducing Your Conversational Development Index'
expect(page).to have_content 'Introducing Your DevOps Score'
find('.js-close-callout').click
expect(page).not_to have_content 'Introducing Your Conversational Development Index'
expect(page).not_to have_content 'Introducing Your DevOps Score'
end
context 'when usage ping is disabled' do
@ -31,7 +31,7 @@ describe 'Dev Ops Score' do
it 'hides the intro callout' do
visit instance_statistics_dev_ops_score_index_path
expect(page).not_to have_content 'Introducing Your Conversational Development Index'
expect(page).not_to have_content 'Introducing Your DevOps Score'
end
end

View File

@ -1,4 +1,3 @@
import BoardService from '~/boards/services/board_service';
import boardsStore from '~/boards/stores/boards_store';
export const setMockEndpoints = (opts = {}) => {
@ -87,22 +86,6 @@ export const boardsMockInterceptor = config => {
return [200, body];
};
export const mockBoardService = (opts = {}) => {
const boardsEndpoint = opts.boardsEndpoint || '/test/issue-boards/-/boards.json';
const listsEndpoint = opts.listsEndpoint || '/test/-/boards/1/lists';
const bulkUpdatePath = opts.bulkUpdatePath || '';
const boardId = opts.boardId || '1';
boardsStore.setEndpoints({
boardsEndpoint,
listsEndpoint,
bulkUpdatePath,
boardId,
});
return new BoardService();
};
export const mockAssigneesList = [
{
id: 2,

View File

@ -42,7 +42,7 @@ describe SubmitUsagePingService do
subject.execute
end
it 'saves conversational development index data from the response' do
it 'saves DevOps Score data from the response' do
stub_response(with_conv_index_params)
expect { subject.execute }