Skip to content

Commit

Permalink
Merge remote-tracking branch 'elastic/master' into monitoring/skip_cl…
Browse files Browse the repository at this point in the history
…oud_test
  • Loading branch information
chrisronline committed Jan 27, 2021
2 parents 016f507 + 4663345 commit b4f26e1
Show file tree
Hide file tree
Showing 927 changed files with 14,552 additions and 10,656 deletions.
8 changes: 4 additions & 4 deletions .browserslistrc
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
last 2 Firefox versions
last 2 Chrome versions
last 2 Safari versions
> 0.25%
not ie 11
not op_mini all
not samsung 4
last 2 Edge versions
last 1 ios_saf versions
last 1 and_chr versions
last 1 samsung versions

[dev]
last 1 chrome versions
Expand Down
1 change: 0 additions & 1 deletion .ci/es-snapshots/Jenkinsfile_verify_es
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ kibanaPipeline(timeoutMinutes: 150) {
withEnv(["ES_SNAPSHOT_MANIFEST=${SNAPSHOT_MANIFEST}"]) {
parallel([
'kibana-intake-agent': workers.intake('kibana-intake', './test/scripts/jenkins_unit.sh'),
'x-pack-intake-agent': workers.intake('x-pack-intake', './test/scripts/jenkins_xpack.sh'),
'kibana-oss-agent': workers.functional('kibana-oss-tests', { kibanaPipeline.buildOss() }, [
'oss-ciGroup1': kibanaPipeline.ossCiGroupProcess(1),
'oss-ciGroup2': kibanaPipeline.ossCiGroupProcess(2),
Expand Down
1 change: 0 additions & 1 deletion .ci/jobs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

JOB:
- kibana-intake
- x-pack-intake
- kibana-firefoxSmoke
- kibana-ciGroup1
- kibana-ciGroup2
Expand Down
1 change: 1 addition & 0 deletions .ci/teamcity/default/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ node scripts/build_kibana_platform_plugins \
--scan-dir "$XPACK_DIR/test/plugin_api_integration/plugins" \
--scan-dir "$XPACK_DIR/test/plugin_api_perf/plugins" \
--scan-dir "$XPACK_DIR/test/licensing_plugin/plugins" \
--scan-dir "$XPACK_DIR/test/usage_collection/plugins" \
--verbose
tc_end_block "Build Platform Plugins"

Expand Down
10 changes: 2 additions & 8 deletions .ci/teamcity/default/jest.sh
Original file line number Diff line number Diff line change
@@ -1,10 +1,4 @@
#!/bin/bash

set -euo pipefail

source "$(dirname "${0}")/../util.sh"

export JOB=kibana-default-jest

checks-reporter-with-killswitch "Jest Unit Tests" \
node scripts/jest x-pack --ci --verbose --maxWorkers=5
# This file is temporary and can be removed once #85850 has been
# merged and the changes included in open PR's (~3 days after merging)
7 changes: 5 additions & 2 deletions .ci/teamcity/oss/jest.sh
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
#!/bin/bash

# This file is temporary and can be removed once #85850 has been
# merged and the changes included in open PR's (~3 days after merging)

set -euo pipefail

source "$(dirname "${0}")/../util.sh"

export JOB=kibana-oss-jest

checks-reporter-with-killswitch "OSS Jest Unit Tests" \
node scripts/jest --config jest.config.oss.js --ci --verbose --maxWorkers=5
checks-reporter-with-killswitch "Jest Unit Tests" \
node scripts/jest --ci --verbose
10 changes: 10 additions & 0 deletions .ci/teamcity/tests/jest.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#!/bin/bash

set -euo pipefail

source "$(dirname "${0}")/../util.sh"

export JOB=kibana-jest

checks-reporter-with-killswitch "Jest Unit Tests" \
node scripts/jest --ci --verbose --coverage
2 changes: 0 additions & 2 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
/src/plugins/advanced_settings/ @elastic/kibana-app
/src/plugins/charts/ @elastic/kibana-app
/src/plugins/discover/ @elastic/kibana-app
/src/plugins/lens_oss/ @elastic/kibana-app
/src/plugins/management/ @elastic/kibana-app
/src/plugins/kibana_legacy/ @elastic/kibana-app
/src/plugins/timelion/ @elastic/kibana-app
Expand Down Expand Up @@ -127,7 +126,6 @@
/x-pack/test/functional/es_archives/maps/ @elastic/kibana-gis
/x-pack/test/visual_regression/tests/maps/index.js @elastic/kibana-gis
#CC# /src/plugins/maps_legacy/ @elastic/kibana-gis
#CC# /src/plugins/maps_oss/ @elastic/kibana-gis
#CC# /x-pack/plugins/file_upload @elastic/kibana-gis
#CC# /x-pack/plugins/maps_legacy_licensing @elastic/kibana-gis
/src/plugins/tile_map/ @elastic/kibana-gis
Expand Down
2 changes: 0 additions & 2 deletions .i18nrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,6 @@
"visTypeVislib": "src/plugins/vis_type_vislib",
"visTypeXy": "src/plugins/vis_type_xy",
"visualizations": "src/plugins/visualizations",
"lensOss": "src/plugins/lens_oss",
"mapsOss": "src/plugins/maps_oss",
"visualize": "src/plugins/visualize",
"apmOss": "src/plugins/apm_oss",
"usageCollection": "src/plugins/usage_collection"
Expand Down
8 changes: 8 additions & 0 deletions .teamcity/src/Common.kt
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,14 @@ fun isReportingEnabled(): Boolean {
return ENABLE_REPORTING;
}

// master and 7.x get committed to so often, we only want to run full CI for them hourly
// but for other branches, we can run daily and on merge
fun isHourlyOnlyBranch(): Boolean {
val branch = getProjectBranch()

return branch == "master" || branch.matches("""^[0-9]+\.x$""".toRegex())
}

fun makeSafeId(id: String): String {
return id.replace(Regex("[^a-zA-Z0-9_]"), "_")
}
15 changes: 8 additions & 7 deletions .teamcity/src/Extensions.kt
Original file line number Diff line number Diff line change
Expand Up @@ -20,20 +20,21 @@ fun BuildType.kibanaAgent(size: Int) {
}

val testArtifactRules = """
target/junit/**/*
target/kibana-*
target/test-metrics/*
target/kibana-coverage/**/*
target/kibana-security-solution/**/*.png
target/junit/**/*
target/test-metrics/*
target/test-suites-ci-plan.json
test/**/screenshots/session/*.png
test/**/screenshots/failure/*.png
test/**/screenshots/diff/*.png
test/**/screenshots/failure/*.png
test/**/screenshots/session/*.png
test/functional/failure_debug/html/*.html
x-pack/test/**/screenshots/session/*.png
x-pack/test/**/screenshots/failure/*.png
x-pack/test/**/screenshots/diff/*.png
x-pack/test/functional/failure_debug/html/*.html
x-pack/test/**/screenshots/failure/*.png
x-pack/test/**/screenshots/session/*.png
x-pack/test/functional/apps/reporting/reports/session/*.pdf
x-pack/test/functional/failure_debug/html/*.html
""".trimIndent()

fun BuildType.addTestSettings() {
Expand Down
37 changes: 37 additions & 0 deletions .teamcity/src/builds/DailyCi.kt
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
package builds

import addSlackNotifications
import areTriggersEnabled
import dependsOn
import getProjectBranch
import jetbrains.buildServer.configs.kotlin.v2019_2.BuildType
import jetbrains.buildServer.configs.kotlin.v2019_2.FailureAction
import jetbrains.buildServer.configs.kotlin.v2019_2.triggers.schedule

object DailyCi : BuildType({
id("Daily_CI")
name = "Daily CI"
description = "Runs everything in CI, daily"
type = Type.COMPOSITE
paused = !areTriggersEnabled()

triggers {
schedule {
schedulingPolicy = cron {
hours = "0"
minutes = "0"
}
branchFilter = "refs/heads/${getProjectBranch()}"
triggerBuild = always()
withPendingChangesOnly = false
}
}

dependsOn(
FullCi
) {
onDependencyCancel = FailureAction.ADD_PROBLEM
}

addSlackNotifications()
})
34 changes: 34 additions & 0 deletions .teamcity/src/builds/OnMergeCi.kt
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
package builds

import addSlackNotifications
import areTriggersEnabled
import dependsOn
import getProjectBranch
import jetbrains.buildServer.configs.kotlin.v2019_2.BuildType
import jetbrains.buildServer.configs.kotlin.v2019_2.FailureAction
import jetbrains.buildServer.configs.kotlin.v2019_2.triggers.vcs

object OnMergeCi : BuildType({
id("OnMerge_CI")
name = "On Merge CI"
description = "Runs everything in CI, on each commit"
type = Type.COMPOSITE
paused = !areTriggersEnabled()

maxRunningBuilds = 1

triggers {
vcs {
perCheckinTriggering = false
branchFilter = "refs/heads/${getProjectBranch()}"
}
}

dependsOn(
FullCi
) {
onDependencyCancel = FailureAction.ADD_PROBLEM
}

addSlackNotifications()
})
4 changes: 4 additions & 0 deletions .teamcity/src/builds/default/DefaultFunctionalBase.kt
Original file line number Diff line number Diff line change
@@ -1,13 +1,17 @@
package builds.default

import StandardAgents
import addTestSettings
import co.elastic.teamcity.common.requireAgent
import jetbrains.buildServer.configs.kotlin.v2019_2.BuildType

open class DefaultFunctionalBase(init: BuildType.() -> Unit = {}) : BuildType({
params {
param("env.KBN_NP_PLUGINS_BUILT", "true")
}

requireAgent(StandardAgents["4"]!!)

dependencies {
defaultBuildWithPlugins()
}
Expand Down
2 changes: 1 addition & 1 deletion .teamcity/src/builds/test/AllTests.kt
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,5 @@ object AllTests : BuildType({
description = "All Non-Functional Tests"
type = Type.COMPOSITE

dependsOn(QuickTests, Jest, XPackJest, JestIntegration, OssApiServerIntegration)
dependsOn(QuickTests, Jest, JestIntegration, OssApiServerIntegration)
})
2 changes: 1 addition & 1 deletion .teamcity/src/builds/test/Jest.kt
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ object Jest : BuildType({
kibanaAgent(8)

steps {
runbld("Jest Unit", "./.ci/teamcity/oss/jest.sh")
runbld("Jest Unit", "./.ci/teamcity/tests/jest.sh")
}

addTestSettings()
Expand Down
19 changes: 0 additions & 19 deletions .teamcity/src/builds/test/XPackJest.kt

This file was deleted.

13 changes: 11 additions & 2 deletions .teamcity/src/projects/Kibana.kt
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import builds.oss.*
import builds.test.*
import CloudProfile
import co.elastic.teamcity.common.googleCloudProfile
import isHourlyOnlyBranch
import jetbrains.buildServer.configs.kotlin.v2019_2.*
import jetbrains.buildServer.configs.kotlin.v2019_2.projectFeatures.slackConnection
import templates.KibanaTemplate
Expand Down Expand Up @@ -76,7 +77,6 @@ fun Kibana(config: KibanaConfiguration = KibanaConfiguration()) : Project {
name = "Jest"

buildType(Jest)
buildType(XPackJest)
buildType(JestIntegration)
}

Expand Down Expand Up @@ -136,7 +136,16 @@ fun Kibana(config: KibanaConfiguration = KibanaConfiguration()) : Project {

buildType(FullCi)
buildType(BaselineCi)
buildType(HourlyCi)

// master and 7.x get committed to so often, we only want to run full CI for them hourly
// but for other branches, we can run daily and on merge
if (isHourlyOnlyBranch()) {
buildType(HourlyCi)
} else {
buildType(DailyCi)
buildType(OnMergeCi)
}

buildType(PullRequestCi)
}

Expand Down
2 changes: 1 addition & 1 deletion dev_docs/kibana_platform_plugin_intro.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ We recognize the need to better clarify the relationship between core functional
The main difference between core functionality and functionality supplied by plugins, is in how it is accessed. Core is
passed to plugins as the first parameter to their `start` and `setup` lifecycle functions, while plugin supplied functionality is passed as the
second parameter. Plugin dependencies must be declared explicitly inside the `kibana.json` file. Core functionality is always provided. Read the
section on [how plugins interact with eachother and core](#how-plugins-interact-with-each-other-and-core) for more information.
section on <DocLink id="kibPlatformIntro" section="how-plugins-interact-with-each-other-and-core" text="how plugins interact with eachother and core"/> for more information.

## The anatomy of a plugin

Expand Down
18 changes: 4 additions & 14 deletions docs/developer/plugin-list.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -130,11 +130,6 @@ in Kibana, e.g. visualizations. It has the form of a flyout panel.
|The legacyExport plugin adds support for the legacy saved objects export format.
|{kib-repo}blob/{branch}/src/plugins/lens_oss/README.md[lensOss]
|The lens_oss plugin registers the lens visualization on OSS.
It is registered as disabled. The x-pack plugin should unregister this.
|{kib-repo}blob/{branch}/src/plugins/management/README.md[management]
|This plugins contains the "Stack Management" page framework. It offers navigation and an API
to link individual managment section into it. This plugin does not contain any individual
Expand All @@ -145,11 +140,6 @@ management section itself.
|Internal objects used by the Coordinate, Region, and Vega visualizations.
|{kib-repo}blob/{branch}/src/plugins/maps_oss/README.md[mapsOss]
|The maps_oss plugin registers the maps visualization on OSS.
It is registered as disabled. The x-pack plugin should unregister this.
|{kib-repo}blob/{branch}/src/plugins/navigation/README.md[navigation]
|The navigation plugins exports the TopNavMenu component.
It also provides a stateful version of it on the start contract.
Expand Down Expand Up @@ -380,10 +370,6 @@ and actions.
|The features plugin enhance Kibana with a per-feature privilege system.
|{kib-repo}blob/{branch}/x-pack/plugins/file_upload/README.md[fileUpload]
|Backend and core front-end react-components for GeoJson file upload. Only supports the Maps plugin.
|{kib-repo}blob/{branch}/x-pack/plugins/fleet/README.md[fleet]
|Fleet needs to have Elasticsearch API keys enabled, and also to have TLS enabled on kibana, (if you want to run Kibana without TLS you can provide the following config flag --xpack.fleet.agents.tlsCheckDisabled=false)
Expand Down Expand Up @@ -453,6 +439,10 @@ using the CURL scripts in the scripts folder.
|Visualize geo data from Elasticsearch or 3rd party geo-services.
|{kib-repo}blob/{branch}/x-pack/plugins/maps_file_upload/README.md[mapsFileUpload]
|Deprecated - plugin targeted for removal and will get merged into file_upload plugin
|{kib-repo}blob/{branch}/x-pack/plugins/maps_legacy_licensing/README.md[mapsLegacyLicensing]
|This plugin provides access to the detailed tile map services from Elastic.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,11 @@ readonly links: {
readonly metricbeat: {
readonly base: string;
};
readonly enterpriseSearch: {
readonly base: string;
readonly appSearchBase: string;
readonly workplaceSearchBase: string;
};
readonly heartbeat: {
readonly base: string;
};
Expand Down
Loading

0 comments on commit b4f26e1

Please sign in to comment.