diff --git a/.ci/Jenkinsfile_flaky b/.ci/Jenkinsfile_flaky
new file mode 100644
index 0000000000000..3f77243da2c1b
--- /dev/null
+++ b/.ci/Jenkinsfile_flaky
@@ -0,0 +1,113 @@
+#!/bin/groovy
+
+library 'kibana-pipeline-library'
+kibanaLibrary.load()
+
+// Looks like 'oss:ciGroup:1' or 'oss:firefoxSmoke'
+def JOB_PARTS = params.CI_GROUP.split(':')
+def IS_XPACK = JOB_PARTS[0] == 'xpack'
+def JOB = JOB_PARTS[1]
+def CI_GROUP = JOB_PARTS.size() > 2 ? JOB_PARTS[2] : ''
+
+def worker = getWorkerFromParams(IS_XPACK, JOB, CI_GROUP)
+
+def workerFailures = []
+
+currentBuild.displayName += trunc(" ${params.GITHUB_OWNER}:${params.branch_specifier}", 24)
+currentBuild.description = "${params.CI_GROUP}
Executions: ${params.NUMBER_EXECUTIONS}"
+
+// Note: If you increase agent count, it will execute NUMBER_EXECUTIONS per agent. It will not divide them up amongst the agents
+// e.g. NUMBER_EXECUTIONS = 25, agentCount = 4 results in 100 total executions
+def agentCount = 1
+
+stage("Kibana Pipeline") {
+ timeout(time: 180, unit: 'MINUTES') {
+ timestamps {
+ ansiColor('xterm') {
+ def agents = [:]
+ for(def agentNumber = 1; agentNumber <= agentCount; agentNumber++) {
+ agents["agent-${agentNumber}"] = {
+ catchError {
+ kibanaPipeline.withWorkers('flaky-test-runner', {
+ if (!IS_XPACK) {
+ kibanaPipeline.buildOss()
+ if (CI_GROUP == '1') {
+ runbld "./test/scripts/jenkins_build_kbn_tp_sample_panel_action.sh"
+ }
+ } else {
+ kibanaPipeline.buildXpack()
+ }
+ }, getWorkerMap(agentNumber, params.NUMBER_EXECUTIONS.toInteger(), worker, workerFailures))()
+ }
+ }
+ }
+
+ parallel(agents)
+
+ currentBuild.description += ", Failures: ${workerFailures.size()}"
+
+ if (workerFailures.size() > 0) {
+ print "There were ${workerFailures.size()} test suite failures."
+ print "The executions that failed were:"
+ print workerFailures.join("\n")
+ print "Please check 'Test Result' and 'Pipeline Steps' pages for more info"
+ }
+ }
+ }
+ }
+}
+
+def getWorkerFromParams(isXpack, job, ciGroup) {
+ if (!isXpack) {
+ if (job == 'firefoxSmoke') {
+ return kibanaPipeline.getPostBuildWorker('firefoxSmoke', { runbld './test/scripts/jenkins_firefox_smoke.sh' })
+ } else if(job == 'visualRegression') {
+ return kibanaPipeline.getPostBuildWorker('visualRegression', { runbld './test/scripts/jenkins_visual_regression.sh' })
+ } else {
+ return kibanaPipeline.getOssCiGroupWorker(ciGroup)
+ }
+ }
+
+ if (job == 'firefoxSmoke') {
+ return kibanaPipeline.getPostBuildWorker('xpack-firefoxSmoke', { runbld './test/scripts/jenkins_xpack_firefox_smoke.sh' })
+ } else if(job == 'visualRegression') {
+ return kibanaPipeline.getPostBuildWorker('xpack-visualRegression', { runbld './test/scripts/jenkins_xpack_visual_regression.sh' })
+ } else {
+ return kibanaPipeline.getXpackCiGroupWorker(ciGroup)
+ }
+}
+
+def getWorkerMap(agentNumber, numberOfExecutions, worker, workerFailures, maxWorkers = 14) {
+ def workerMap = [:]
+ def numberOfWorkers = Math.min(numberOfExecutions, maxWorkers)
+
+ for(def i = 1; i <= numberOfWorkers; i++) {
+ def workerExecutions = numberOfExecutions/numberOfWorkers + (i <= numberOfExecutions%numberOfWorkers ? 1 : 0)
+
+ workerMap["agent-${agentNumber}-worker-${i}"] = { workerNumber ->
+ for(def j = 0; j < workerExecutions; j++) {
+ print "Execute agent-${agentNumber} worker-${workerNumber}: ${j}"
+ withEnv(["JOB=agent-${agentNumber}-worker-${workerNumber}-${j}"]) {
+ catchError {
+ try {
+ worker(workerNumber)
+ } catch (ex) {
+ workerFailures << "agent-${agentNumber} worker-${workerNumber}-${j}"
+ throw ex
+ }
+ }
+ }
+ }
+ }
+ }
+
+ return workerMap
+}
+
+def trunc(str, length) {
+ if (str.size() >= length) {
+ return str.take(length) + "..."
+ }
+
+ return str;
+}
diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS
index 4ae7b27a58ee4..7001e32754abb 100644
--- a/.github/CODEOWNERS
+++ b/.github/CODEOWNERS
@@ -10,6 +10,7 @@
/src/plugins/data/ @elastic/kibana-app-arch
/src/plugins/kibana_utils/ @elastic/kibana-app-arch
/src/plugins/kibana_react/ @elastic/kibana-app-arch
+/src/plugins/navigation/ @elastic/kibana-app-arch
# APM
/x-pack/legacy/plugins/apm/ @elastic/apm-ui
diff --git a/.github/labeler.yml b/.github/labeler.yml
index 8a776a909cd9e..57b299912ae9e 100644
--- a/.github/labeler.yml
+++ b/.github/labeler.yml
@@ -2,6 +2,7 @@
- src/plugins/data/**/*
- src/plugins/embeddable/**/*
- src/plugins/kibana_react/**/*
+- src/plugins/navigation/**/*
- src/plugins/kibana_utils/**/*
- src/legacy/core_plugins/dashboard_embeddable_container/**/*
- src/legacy/core_plugins/data/**/*
diff --git a/.i18nrc.json b/.i18nrc.json
index 0ea51fe8212c4..d77293e3dc8f7 100644
--- a/.i18nrc.json
+++ b/.i18nrc.json
@@ -4,6 +4,7 @@
"data": ["src/legacy/core_plugins/data", "src/plugins/data"],
"expressions": "src/legacy/core_plugins/expressions",
"kibana_react": "src/legacy/core_plugins/kibana_react",
+ "navigation": "src/legacy/core_plugins/navigation",
"server": "src/legacy/server",
"console": "src/legacy/core_plugins/console",
"core": "src/core",
diff --git a/Jenkinsfile b/Jenkinsfile
index fca814b265295..4820de9876737 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -1,6 +1,7 @@
#!/bin/groovy
library 'kibana-pipeline-library'
+kibanaLibrary.load()
stage("Kibana Pipeline") { // This stage is just here to help the BlueOcean UI a little bit
timeout(time: 180, unit: 'MINUTES') {
@@ -8,301 +9,42 @@ stage("Kibana Pipeline") { // This stage is just here to help the BlueOcean UI a
ansiColor('xterm') {
catchError {
parallel([
- 'kibana-intake-agent': legacyJobRunner('kibana-intake'),
- 'x-pack-intake-agent': legacyJobRunner('x-pack-intake'),
- 'kibana-oss-agent': withWorkers('kibana-oss-tests', { buildOss() }, [
- 'oss-ciGroup1': getOssCiGroupWorker(1),
- 'oss-ciGroup2': getOssCiGroupWorker(2),
- 'oss-ciGroup3': getOssCiGroupWorker(3),
- 'oss-ciGroup4': getOssCiGroupWorker(4),
- 'oss-ciGroup5': getOssCiGroupWorker(5),
- 'oss-ciGroup6': getOssCiGroupWorker(6),
- 'oss-ciGroup7': getOssCiGroupWorker(7),
- 'oss-ciGroup8': getOssCiGroupWorker(8),
- 'oss-ciGroup9': getOssCiGroupWorker(9),
- 'oss-ciGroup10': getOssCiGroupWorker(10),
- 'oss-ciGroup11': getOssCiGroupWorker(11),
- 'oss-ciGroup12': getOssCiGroupWorker(12),
- 'oss-firefoxSmoke': getPostBuildWorker('firefoxSmoke', { runbld './test/scripts/jenkins_firefox_smoke.sh' }),
- // 'oss-visualRegression': getPostBuildWorker('visualRegression', { runbld './test/scripts/jenkins_visual_regression.sh' }),
+ 'kibana-intake-agent': kibanaPipeline.legacyJobRunner('kibana-intake'),
+ 'x-pack-intake-agent': kibanaPipeline.legacyJobRunner('x-pack-intake'),
+ 'kibana-oss-agent': kibanaPipeline.withWorkers('kibana-oss-tests', { kibanaPipeline.buildOss() }, [
+ 'oss-ciGroup1': kibanaPipeline.getOssCiGroupWorker(1),
+ 'oss-ciGroup2': kibanaPipeline.getOssCiGroupWorker(2),
+ 'oss-ciGroup3': kibanaPipeline.getOssCiGroupWorker(3),
+ 'oss-ciGroup4': kibanaPipeline.getOssCiGroupWorker(4),
+ 'oss-ciGroup5': kibanaPipeline.getOssCiGroupWorker(5),
+ 'oss-ciGroup6': kibanaPipeline.getOssCiGroupWorker(6),
+ 'oss-ciGroup7': kibanaPipeline.getOssCiGroupWorker(7),
+ 'oss-ciGroup8': kibanaPipeline.getOssCiGroupWorker(8),
+ 'oss-ciGroup9': kibanaPipeline.getOssCiGroupWorker(9),
+ 'oss-ciGroup10': kibanaPipeline.getOssCiGroupWorker(10),
+ 'oss-ciGroup11': kibanaPipeline.getOssCiGroupWorker(11),
+ 'oss-ciGroup12': kibanaPipeline.getOssCiGroupWorker(12),
+ 'oss-firefoxSmoke': kibanaPipeline.getPostBuildWorker('firefoxSmoke', { runbld './test/scripts/jenkins_firefox_smoke.sh' }),
+ // 'oss-visualRegression': kibanaPipeline.getPostBuildWorker('visualRegression', { runbld './test/scripts/jenkins_visual_regression.sh' }),
]),
- 'kibana-xpack-agent': withWorkers('kibana-xpack-tests', { buildXpack() }, [
- 'xpack-ciGroup1': getXpackCiGroupWorker(1),
- 'xpack-ciGroup2': getXpackCiGroupWorker(2),
- 'xpack-ciGroup3': getXpackCiGroupWorker(3),
- 'xpack-ciGroup4': getXpackCiGroupWorker(4),
- 'xpack-ciGroup5': getXpackCiGroupWorker(5),
- 'xpack-ciGroup6': getXpackCiGroupWorker(6),
- 'xpack-ciGroup7': getXpackCiGroupWorker(7),
- 'xpack-ciGroup8': getXpackCiGroupWorker(8),
- 'xpack-ciGroup9': getXpackCiGroupWorker(9),
- 'xpack-ciGroup10': getXpackCiGroupWorker(10),
- 'xpack-firefoxSmoke': getPostBuildWorker('xpack-firefoxSmoke', { runbld './test/scripts/jenkins_xpack_firefox_smoke.sh' }),
- // 'xpack-visualRegression': getPostBuildWorker('xpack-visualRegression', { runbld './test/scripts/jenkins_xpack_visual_regression.sh' }),
+ 'kibana-xpack-agent': kibanaPipeline.withWorkers('kibana-xpack-tests', { kibanaPipeline.buildXpack() }, [
+ 'xpack-ciGroup1': kibanaPipeline.getXpackCiGroupWorker(1),
+ 'xpack-ciGroup2': kibanaPipeline.getXpackCiGroupWorker(2),
+ 'xpack-ciGroup3': kibanaPipeline.getXpackCiGroupWorker(3),
+ 'xpack-ciGroup4': kibanaPipeline.getXpackCiGroupWorker(4),
+ 'xpack-ciGroup5': kibanaPipeline.getXpackCiGroupWorker(5),
+ 'xpack-ciGroup6': kibanaPipeline.getXpackCiGroupWorker(6),
+ 'xpack-ciGroup7': kibanaPipeline.getXpackCiGroupWorker(7),
+ 'xpack-ciGroup8': kibanaPipeline.getXpackCiGroupWorker(8),
+ 'xpack-ciGroup9': kibanaPipeline.getXpackCiGroupWorker(9),
+ 'xpack-ciGroup10': kibanaPipeline.getXpackCiGroupWorker(10),
+ 'xpack-firefoxSmoke': kibanaPipeline.getPostBuildWorker('xpack-firefoxSmoke', { runbld './test/scripts/jenkins_xpack_firefox_smoke.sh' }),
+ // 'xpack-visualRegression': kibanaPipeline.getPostBuildWorker('xpack-visualRegression', { runbld './test/scripts/jenkins_xpack_visual_regression.sh' }),
]),
])
}
- node('flyweight') {
- // If the build doesn't have a result set by this point, there haven't been any errors and it can be marked as a success
- // The e-mail plugin for the infra e-mail depends upon this being set
- currentBuild.result = currentBuild.result ?: 'SUCCESS'
-
- sendMail()
- }
+ kibanaPipeline.sendMail()
}
}
}
}
-
-def withWorkers(name, preWorkerClosure = {}, workerClosures = [:]) {
- return {
- jobRunner('tests-xl', true) {
- try {
- doSetup()
- preWorkerClosure()
-
- def nextWorker = 1
- def worker = { workerClosure ->
- def workerNumber = nextWorker
- nextWorker++
-
- return {
- workerClosure(workerNumber)
- }
- }
-
- def workers = [:]
- workerClosures.each { workerName, workerClosure ->
- workers[workerName] = worker(workerClosure)
- }
-
- parallel(workers)
- } finally {
- catchError {
- uploadAllGcsArtifacts(name)
- }
-
- catchError {
- runbldJunit()
- }
-
- catchError {
- publishJunit()
- }
-
- catchError {
- runErrorReporter()
- }
- }
- }
- }
-}
-
-def getPostBuildWorker(name, closure) {
- return { workerNumber ->
- def kibanaPort = "61${workerNumber}1"
- def esPort = "61${workerNumber}2"
- def esTransportPort = "61${workerNumber}3"
-
- withEnv([
- "CI_WORKER_NUMBER=${workerNumber}",
- "TEST_KIBANA_HOST=localhost",
- "TEST_KIBANA_PORT=${kibanaPort}",
- "TEST_KIBANA_URL=http://elastic:changeme@localhost:${kibanaPort}",
- "TEST_ES_URL=http://elastic:changeme@localhost:${esPort}",
- "TEST_ES_TRANSPORT_PORT=${esTransportPort}",
- "IS_PIPELINE_JOB=1",
- ]) {
- closure()
- }
- }
-}
-
-def getOssCiGroupWorker(ciGroup) {
- return getPostBuildWorker("ciGroup" + ciGroup, {
- withEnv([
- "CI_GROUP=${ciGroup}",
- "JOB=kibana-ciGroup${ciGroup}",
- ]) {
- runbld "./test/scripts/jenkins_ci_group.sh"
- }
- })
-}
-
-def getXpackCiGroupWorker(ciGroup) {
- return getPostBuildWorker("xpack-ciGroup" + ciGroup, {
- withEnv([
- "CI_GROUP=${ciGroup}",
- "JOB=xpack-kibana-ciGroup${ciGroup}",
- ]) {
- runbld "./test/scripts/jenkins_xpack_ci_group.sh"
- }
- })
-}
-
-def legacyJobRunner(name) {
- return {
- parallel([
- "${name}": {
- withEnv([
- "JOB=${name}",
- ]) {
- jobRunner('linux && immutable', false) {
- try {
- runbld('.ci/run.sh', true)
- } finally {
- catchError {
- uploadAllGcsArtifacts(name)
- }
- catchError {
- publishJunit()
- }
- catchError {
- runErrorReporter()
- }
- }
- }
- }
- }
- ])
- }
-}
-
-def jobRunner(label, useRamDisk, closure) {
- node(label) {
- if (useRamDisk) {
- // Move to a temporary workspace, so that we can symlink the real workspace into /dev/shm
- def originalWorkspace = env.WORKSPACE
- ws('/tmp/workspace') {
- sh """
- mkdir -p /dev/shm/workspace
- mkdir -p '${originalWorkspace}' # create all of the directories leading up to the workspace, if they don't exist
- rm --preserve-root -rf '${originalWorkspace}' # then remove just the workspace, just in case there's stuff in it
- ln -s /dev/shm/workspace '${originalWorkspace}'
- """
- }
- }
-
- def scmVars = checkout scm
-
- withEnv([
- "CI=true",
- "HOME=${env.JENKINS_HOME}",
- "PR_SOURCE_BRANCH=${env.ghprbSourceBranch ?: ''}",
- "PR_TARGET_BRANCH=${env.ghprbTargetBranch ?: ''}",
- "PR_AUTHOR=${env.ghprbPullAuthorLogin ?: ''}",
- "TEST_BROWSER_HEADLESS=1",
- "GIT_BRANCH=${scmVars.GIT_BRANCH}",
- ]) {
- withCredentials([
- string(credentialsId: 'vault-addr', variable: 'VAULT_ADDR'),
- string(credentialsId: 'vault-role-id', variable: 'VAULT_ROLE_ID'),
- string(credentialsId: 'vault-secret-id', variable: 'VAULT_SECRET_ID'),
- ]) {
- // scm is configured to check out to the ./kibana directory
- dir('kibana') {
- closure()
- }
- }
- }
- }
-}
-
-// TODO what should happen if GCS, Junit, or email publishing fails? Unstable build? Failed build?
-
-def uploadGcsArtifact(workerName, pattern) {
- def storageLocation = "gs://kibana-ci-artifacts/jobs/${env.JOB_NAME}/${BUILD_NUMBER}/${workerName}" // TODO
- // def storageLocation = "gs://kibana-pipeline-testing/jobs/pipeline-test/${BUILD_NUMBER}/${workerName}"
-
- googleStorageUpload(
- credentialsId: 'kibana-ci-gcs-plugin',
- bucket: storageLocation,
- pattern: pattern,
- sharedPublicly: true,
- showInline: true,
- )
-}
-
-def uploadAllGcsArtifacts(workerName) {
- def ARTIFACT_PATTERNS = [
- 'target/kibana-*',
- 'target/junit/**/*',
- 'test/**/screenshots/**/*.png',
- 'test/functional/failure_debug/html/*.html',
- 'x-pack/test/**/screenshots/**/*.png',
- 'x-pack/test/functional/failure_debug/html/*.html',
- 'x-pack/test/functional/apps/reporting/reports/session/*.pdf',
- ]
-
- ARTIFACT_PATTERNS.each { pattern ->
- uploadGcsArtifact(workerName, pattern)
- }
-}
-
-def publishJunit() {
- junit(testResults: 'target/junit/**/*.xml', allowEmptyResults: true, keepLongStdio: true)
-}
-
-def sendMail() {
- sendInfraMail()
- sendKibanaMail()
-}
-
-def sendInfraMail() {
- catchError {
- step([
- $class: 'Mailer',
- notifyEveryUnstableBuild: true,
- recipients: 'infra-root+build@elastic.co',
- sendToIndividuals: false
- ])
- }
-}
-
-def sendKibanaMail() {
- catchError {
- def buildStatus = buildUtils.getBuildStatus()
-
- if(params.NOTIFY_ON_FAILURE && buildStatus != 'SUCCESS' && buildStatus != 'ABORTED') {
- emailext(
- to: 'build-kibana@elastic.co',
- subject: "${env.JOB_NAME} - Build # ${env.BUILD_NUMBER} - ${buildStatus}",
- body: '${SCRIPT,template="groovy-html.template"}',
- mimeType: 'text/html',
- )
- }
- }
-}
-
-def runbld(script, enableJunitProcessing = false) {
- def extraConfig = enableJunitProcessing ? "" : "--config ${env.WORKSPACE}/kibana/.ci/runbld_no_junit.yml"
-
- sh "/usr/local/bin/runbld -d '${pwd()}' ${extraConfig} ${script}"
-}
-
-def runbldJunit() {
- sh "/usr/local/bin/runbld -d '${pwd()}' ${env.WORKSPACE}/kibana/test/scripts/jenkins_runbld_junit.sh"
-}
-
-def bash(script) {
- sh "#!/bin/bash\n${script}"
-}
-
-def doSetup() {
- runbld "./test/scripts/jenkins_setup.sh"
-}
-
-def buildOss() {
- runbld "./test/scripts/jenkins_build_kibana.sh"
-}
-
-def buildXpack() {
- runbld "./test/scripts/jenkins_xpack_build_kibana.sh"
-}
-
-def runErrorReporter() {
- bash """
- source src/dev/ci_setup/setup_env.sh
- node scripts/report_failed_tests
- """
-}
diff --git a/config/kibana.yml b/config/kibana.yml
index 9525a6423d90a..47482f9e6d59f 100644
--- a/config/kibana.yml
+++ b/config/kibana.yml
@@ -50,7 +50,8 @@
#server.ssl.key: /path/to/your/server.key
# Optional settings that provide the paths to the PEM-format SSL certificate and key files.
-# These files validate that your Elasticsearch backend uses the same key files.
+# These files are used to verify the identity of Kibana to Elasticsearch and are required when
+# xpack.ssl.verification_mode in Elasticsearch is set to either certificate or full.
#elasticsearch.ssl.certificate: /path/to/your/client.crt
#elasticsearch.ssl.key: /path/to/your/client.key
diff --git a/docs/canvas/canvas-function-reference.asciidoc b/docs/canvas/canvas-function-reference.asciidoc
index df4b17e905772..07f3cf028dc0e 100644
--- a/docs/canvas/canvas-function-reference.asciidoc
+++ b/docs/canvas/canvas-function-reference.asciidoc
@@ -25,6 +25,32 @@ A † denotes an argument can be passed multiple times.
Returns `true` if all of the conditions are met. See also <>.
+*Expression syntax*
+[source,js]
+----
+all {neq “foo”} {neq “bar”} {neq “fizz”}
+all condition={gt 10} condition={lt 20}
+----
+
+*Code example*
+[source,text]
+----
+filters
+| demodata
+| math "mean(percent_uptime)"
+| formatnumber "0.0%"
+| metric "Average uptime"
+ metricFont={
+ font size=48 family="'Open Sans', Helvetica, Arial, sans-serif"
+ color={
+ if {all {gte 0} {lt 0.8}} then="red" else="green"
+ }
+ align="center" lHeight=48
+ }
+| render
+----
+This sets the color of the metric text to `”red”` if the context passed into `metric` is greater than or equal to 0 and less than 0.8. Otherwise, the color is set to `"green"`.
+
*Accepts:* `null`
[cols="3*^<"]
@@ -47,6 +73,24 @@ Alias: `condition`
Converts between core types, including `string`, `number`, `null`, `boolean`, and `date`, and renames columns. See also <> and <>.
+*Expression syntax*
+[source,js]
+----
+alterColumn “cost” type=”string”
+alterColumn column=”@timestamp” name=”foo”
+----
+
+*Code example*
+[source,text]
+----
+filters
+| demodata
+| alterColumn “time” name=”time_in_ms” type=”number”
+| table
+| render
+----
+This renames the `time` column to `time_in_ms` and converts the type of the column’s values from `date` to `number`.
+
*Accepts:* `datatable`
[cols="3*^<"]
@@ -77,6 +121,27 @@ Alias: `column`
Returns `true` if at least one of the conditions is met. See also <>.
+*Expression syntax*
+[source,js]
+----
+any {eq “foo”} {eq “bar”} {eq “fizz”}
+any condition={lte 10} condition={gt 30}
+----
+
+*Code example*
+[source,text]
+----
+filters
+| demodata
+| filterrows {
+ getCell "project" | any {eq "elasticsearch"} {eq "kibana"} {eq "x-pack"}
+ }
+| pointseries color="project" size="max(price)"
+| pie
+| render
+----
+This filters out any rows that don’t contain `“elasticsearch”`, `“kibana”` or `“x-pack”` in the `project` field.
+
*Accepts:* `null`
[cols="3*^<"]
@@ -99,6 +164,28 @@ Alias: `condition`
Creates a `datatable` with a single value. See also <>.
+*Expression syntax*
+[source,js]
+----
+as
+as “foo”
+as name=”bar”
+----
+
+*Code example*
+[source,text]
+----
+filters
+| demodata
+| ply by="project" fn={math "count(username)" | as "num_users"} fn={math "mean(price)" | as "price"}
+| pointseries x="project" y="num_users" size="price" color="project"
+| plot
+| render
+----
+`as` casts any primitive value (`string`, `number`, `date`, `null`) into a `datatable` with a single row and a single column with the given name (or defaults to `"value"` if no name is provided). This is useful when piping a primitive value into a function that only takes `datatable` as an input.
+
+In the example above, `ply` expects each `fn` subexpression to return a `datatable` in order to merge the results of each `fn` back into a `datatable`, but using a `math` aggregation in the subexpressions returns a single `math` value, which is then cast into a `datatable` using `as`.
+
*Accepts:* `string`, `boolean`, `number`, `null`
[cols="3*^<"]
@@ -123,6 +210,21 @@ Default: `"value"`
Retrieves Canvas workpad asset objects to provide as argument values. Usually images.
+*Expression syntax*
+[source,js]
+----
+asset "asset-52f14f2b-fee6-4072-92e8-cd2642665d02"
+asset id="asset-498f7429-4d56-42a2-a7e4-8bf08d98d114"
+----
+
+*Code example*
+[source,text]
+----
+image dataurl={asset "asset-c661a7cc-11be-45a1-a401-d7592ea7917a"} mode="contain"
+| render
+----
+The image asset stored with the ID `“asset-c661a7cc-11be-45a1-a401-d7592ea7917a”` is passed into the `dataurl` argument of the `image` function to display the stored asset.
+
*Accepts:* `null`
[cols="3*^<"]
@@ -145,6 +247,27 @@ Alias: `id`
Configures the axis of a visualization. Only used with <>.
+*Expression syntax*
+[source,js]
+----
+axisConfig show=false
+axisConfig position=”right” min=0 max=10 tickSize=1
+----
+
+*Code example*
+[source,text]
+----
+filters
+| demodata
+| pointseries x="size(cost)" y="project" color="project"
+| plot defaultStyle={seriesStyle bars=0.75 horizontalBars=true}
+ legend=false
+ xaxis={axisConfig position="top" min=0 max=400 tickSize=100}
+ yaxis={axisConfig position="right"}
+| render
+----
+This sets the `x-axis` to display on the top of the chart and sets the range of values to `0-400` with ticks displayed at `100` intervals. The `y-axis` is configured to display on the `right`.
+
*Accepts:* `null`
[cols="3*^<"]
@@ -188,6 +311,34 @@ Default: `true`
Builds a `case` (including a condition/result) to pass to the <> function.
+*Expression syntax*
+[source,js]
+----
+case 0 then=”red”
+case when=5 then=”yellow”
+case if={lte 50} then=”green”
+----
+
+*Code example*
+[source,text]
+----
+math "random()"
+| progress shape="gauge" label={formatnumber "0%"}
+ font={font size=24 family="'Open Sans', Helvetica, Arial, sans-serif" align="center"
+ color={
+ switch {case if={lte 0.5} then="green"}
+ {case if={all {gt 0.5} {lte 0.75}} then="orange"}
+ default="red"
+ }}
+ valueColor={
+ switch {case if={lte 0.5} then="green"}
+ {case if={all {gt 0.5} {lte 0.75}} then="orange"}
+ default="red"
+ }
+| render
+----
+This sets the color of the progress indicator and the color of the label to `"green"` if the value is less than or equal to `0.5`, `"orange"` if the value is greater than `0.5` and less than or equal to `0.75`, and `"red"` if `none` of the case conditions are met.
+
*Accepts:* `any`
[cols="3*^<"]
@@ -229,6 +380,24 @@ Clears the _context_, and returns `null`.
Includes or excludes columns from a data table. If you specify both, this will exclude first.
+*Expression syntax*
+[source,js]
+----
+columns include=”@timestamp, projects, cost”
+columns exclude=”username, country, age”
+----
+
+*Code example*
+[source,text]
+----
+filters
+| demodata
+| columns include="price, cost, state, project"
+| table
+| render
+----
+This only keeps the `price`, `cost`, `state`, and `project` columns from the `demodata` data source and removes all other columns.
+
*Accepts:* `datatable`
[cols="3*^<"]
@@ -257,6 +426,31 @@ Compares the _context_ to specified value to determine `true` or `false`.
Usually used in combination with <> or <>. This only works with primitive types,
such as `number`, `string`, and `boolean`. See also <>, <>, <>, <>, <>, and <>.
+*Expression syntax*
+[source,js]
+----
+compare “neq” to=”elasticsearch”
+compare op=”lte” to=100
+----
+
+*Code example*
+[source,text]
+----
+filters
+| demodata
+| mapColumn project
+ fn=${getCell project |
+ switch
+ {case if={compare eq to=kibana} then=kibana}
+ {case if={compare eq to=elasticsearch} then=elasticsearch}
+ default="other"
+ }
+| pointseries size="size(cost)" color="project"
+| pie
+| render
+----
+This maps all `project` values that aren’t `“kibana”` and `“elasticsearch”` to `“other”`. Alternatively, you can use the individual comparator functions instead of compare. See <>, <>, <>, <>, <>, and <>.
+
*Accepts:* `string`, `number`, `boolean`, `null`
[cols="3*^<"]
@@ -287,6 +481,35 @@ Alias: `this`, `b`
Creates an object used for styling an element's container, including background, border, and opacity.
+*Expression syntax*
+[source,js]
+----
+containerStyle backgroundColor=”red”’
+containerStyle borderRadius=”50px”
+containerStyle border=”1px solid black”
+containerStyle padding=”5px”
+containerStyle opacity=”0.5”
+containerStyle overflow=”hidden”
+containerStyle backgroundImage={asset id=asset-f40d2292-cf9e-4f2c-8c6f-a504a25e949c}
+ backgroundRepeat="no-repeat"
+ backgroundSize="cover"
+----
+
+*Code example*
+[source,text]
+----
+shape "star" fill="#E61D35" maintainAspect=true
+| render
+ containerStyle={
+ containerStyle backgroundColor="#F8D546"
+ borderRadius="200px"
+ border="4px solid #05509F"
+ padding="0px"
+ opacity="0.9"
+ overflow="hidden"
+ }
+----
+
*Accepts:* `null`
[cols="3*^<"]
@@ -346,6 +569,22 @@ Default: `"hidden"`
Returns whatever you pass into it. This can be useful when you need to use the
_context_ as an argument to a function as a sub-expression.
+*Expression syntax*
+[source,js]
+----
+context
+----
+
+*Code example*
+[source,text]
+----
+date
+| formatdate "LLLL"
+| markdown "Last updated: " {context}
+| render
+----
+Using the `context` function allows us to pass the output, or _context_, of the previous function as a value to an argument in the next function. Here we get the formatted date string from the previous function and pass it as `content` for the markdown element.
+
*Accepts:* `any`
*Returns:* Original _context_
@@ -356,6 +595,26 @@ _context_ as an argument to a function as a sub-expression.
Creates a `datatable` from CSV input.
+*Expression syntax*
+[source,js]
+----
+csv “fruit, stock
+ kiwi, 10
+ Banana, 5”
+----
+
+*Code example*
+[source,text]
+----
+csv "fruit,stock
+ kiwi,10
+ banana,5"
+| pointseries color=fruit size=stock
+| pie
+| render
+----
+This is useful for quickly mocking data.
+
*Accepts:* `null`
[cols="3*^<"]
@@ -390,6 +649,30 @@ Alias: `data`
Returns the current time, or a time parsed from a `string`, as milliseconds since epoch.
+*Expression syntax*
+[source,js]
+----
+date
+date value=1558735195
+date “2019-05-24T21:59:55+0000”
+date “01/31/2019” format=”MM/DD/YYYY”
+----
+
+*Code example*
+[source,text]
+----
+date
+| formatdate "LLL"
+| markdown {context}
+ font={font family="Arial, sans-serif" size=30 align="left"
+ color="#000000"
+ weight="normal"
+ underline=false
+ italic=false}
+| render
+----
+Using `date` without passing any arguments will return the current date and time.
+
*Accepts:* `null`
[cols="3*^<"]
@@ -418,6 +701,24 @@ using the `format` argument. Must be an ISO8601 string or you must provide the f
A mock data set that includes project CI times with usernames, countries, and run phases.
+*Expression syntax*
+[source,js]
+----
+demodata
+demodata “ci”
+demodata type=”shirts”
+----
+
+*Code example*
+[source,text]
+----
+filters
+| demodata
+| table
+| render
+----
+`demodata` is a mock data set that you can use to start playing around in Canvas.
+
*Accepts:* `filter`
[cols="3*^<"]
@@ -442,6 +743,23 @@ Default: `"ci"`
Executes multiple sub-expressions, then returns the original _context_. Use for running functions that produce an action or side effect without changing the original _context_.
+*Expression syntax*
+[source,js]
+----
+do fn={something cool}
+----
+
+*Code example*
+[source,text]
+----
+filters
+| demodata
+| do fn={something cool}
+| table
+| render
+----
+`do` should be used to invoke a function that produces as a side effect without changing the `context`.
+
*Accepts:* `any`
[cols="3*^<"]
@@ -464,6 +782,22 @@ Aliases: `expression`, `exp`, `fn`, `function`
Configures a dropdown filter control element.
+*Expression syntax*
+[source,js]
+----
+dropdownControl valueColumn=project filterColumn=project
+dropdownControl valueColumn=agent filterColumn=agent.keyword filterGroup=group1
+----
+
+*Code example*
+[source,text]
+----
+demodata
+| dropdownControl valueColumn=project filterColumn=project
+| render
+----
+This creates a dropdown filter element. It requires a data source and uses the unique values from the given `valueColumn` (i.e. `project`) and applies the filter to the `project` column. Note: `filterColumn` should point to a keyword type field for Elasticsearch data sources.
+
*Accepts:* `datatable`
[cols="3*^<"]
@@ -496,6 +830,33 @@ Configures a dropdown filter control element.
Returns whether the _context_ is equal to the argument.
+*Expression syntax*
+[source,js]
+----
+eq true
+eq null
+eq 10
+eq “foo”
+----
+
+*Code example*
+[source,text]
+----
+filters
+| demodata
+| mapColumn project
+ fn=${getCell project |
+ switch
+ {case if={eq kibana} then=kibana}
+ {case if={eq elasticsearch} then=elasticsearch}
+ default="other"
+ }
+| pointseries size="size(cost)" color="project"
+| pie
+| render
+----
+This changes all values in the project column that don’t equal `“kibana”` or `“elasticsearch”` to `“other”`.
+
*Accepts:* `boolean`, `number`, `string`, `null`
[cols="3*^<"]
@@ -518,6 +879,28 @@ Alias: `value`
Queries {es} for the number of hits matching the specified query.
+*Expression syntax*
+[source,js]
+----
+escount index=”logstash-*”
+escount "currency:\"EUR\"" index=”kibana_sample_data_ecommerce”
+escount query="response:404" index=”kibana_sample_data_logs”
+----
+
+*Code example*
+[source,text]
+----
+filters
+| escount "Cancelled:true" index="kibana_sample_data_flights"
+| math "value"
+| progress shape="semicircle"
+ label={formatnumber 0,0}
+ font={font size=24 family="'Open Sans', Helvetica, Arial, sans-serif" color="#000000" align=center}
+ max={filters | escount index="kibana_sample_data_flights"}
+| render
+----
+The first `escount` expression retrieves the number of flights that were cancelled. The second `escount` expression retrieves the total number of flights.
+
*Accepts:* `filter`
[cols="3*^<"]
@@ -549,6 +932,34 @@ Default: `_all`
Queries {es} for raw documents. Specify the fields you want to retrieve,
especially if you are asking for a lot of rows.
+*Expression syntax*
+[source,js]
+----
+esdocs index=”logstash-*”
+esdocs "currency:\"EUR\"" index=”kibana_sample_data_ecommerce”
+esdocs query="response:404" index=”kibana_sample_data_logs”
+esdocs index=”kibana_sample_data_flights” count=100
+esdocs index="kibana_sample_data_flights" sort="AvgTicketPrice, asc"
+----
+
+*Code example*
+[source,text]
+----
+filters
+| esdocs index="kibana_sample_data_ecommerce"
+ fields="customer_gender, taxful_total_price, order_date"
+ sort="order_date, asc"
+ count=10000
+| mapColumn "order_date"
+ fn={getCell "order_date" | date {context} | rounddate "YYYY-MM-DD"}
+| alterColumn "order_date" type="date"
+| pointseries x="order_date" y="sum(taxful_total_price)" color="customer_gender"
+| plot defaultStyle={seriesStyle lines=3}
+ palette={palette "#7ECAE3" "#003A4D" gradient=true}
+| render
+----
+This retrieves the latest 10000 documents data from the `kibana_sample_data_ecommerce` index sorted by `order_date` in ascending order and only requests the `customer_gender`, `taxful_total_price`, and `order_date` fields.
+
*Accepts:* `filter`
[cols="3*^<"]
@@ -593,6 +1004,21 @@ Default: `"_all"`
Queries {es} using {es} SQL.
+*Expression syntax*
+[source,js]
+----
+essql query=”SELECT * FROM \”logstash*\””
+essql “SELECT * FROM \”apm*\”” count=10000
+----
+
+*Code example*
+[source,text]
+----
+filters
+| essql query="SELECT Carrier, FlightDelayMin, AvgTicketPrice FROM \"kibana_sample_data_flights\""
+----
+This retrieves the `Carrier`, `FlightDelayMin`, and `AvgTicketPrice` fields from the “kibana_sample_data_flights” index.
+
*Accepts:* `filter`
[cols="3*^<"]
@@ -627,6 +1053,26 @@ Default: `UTC`
Creates a filter that matches a given column to an exact value.
+*Expression syntax*
+[source,js]
+----
+exactly “state” value=”running”
+exactly “age” value=50 filterGroup=”group2”
+exactly column=“project” value=”beats”
+----
+
+*Code example*
+[source,text]
+----
+filters
+| exactly column=project value=elasticsearch
+| demodata
+| pointseries x=project y="mean(age)"
+| plot defaultStyle={seriesStyle bars=1}
+| render
+----
+The `exactly` filter here is added to existing filters retrieved by the `filters` function and further filters down the data to only have `”elasticsearch”` data. The `exactly` filter only applies to this one specific element and will not affect other elements in the workpad.
+
*Accepts:* `filter`
[cols="3*^<"]
@@ -664,6 +1110,29 @@ capitalization.
Filters rows in a `datatable` based on the return value of a sub-expression.
+*Expression syntax*
+[source,js]
+----
+filterrows {getCell “project” | eq “kibana”}
+filterrows fn={getCell “age” | gt 50}
+----
+
+*Code example*
+[source,text]
+----
+filters
+| demodata
+| filterrows {getCell "country" | any {eq "IN"} {eq "US"} {eq "CN"}}
+| mapColumn "@timestamp"
+ fn={getCell "@timestamp" | rounddate "YYYY-MM"}
+| alterColumn "@timestamp" type="date"
+| pointseries x="@timestamp" y="mean(cost)" color="country"
+| plot defaultStyle={seriesStyle points="2" lines="1"}
+ palette={palette "#01A4A4" "#CC6666" "#D0D102" "#616161" "#00A1CB" "#32742C" "#F18D05" "#113F8C" "#61AE24" "#D70060" gradient=false}
+| render
+----
+This uses `filterrows` to only keep data from India (`IN`), the United States (`US`), and China (`CN`).
+
*Accepts:* `datatable`
[cols="3*^<"]
@@ -688,6 +1157,34 @@ and a `false` value removes it.
Aggregates element filters from the workpad for use elsewhere, usually a data source.
+*Expression syntax*
+[source,js]
+----
+filters
+filters group=”timefilter1”
+filters group=”timefilter2” group=”dropdownfilter1” ungrouped=true
+----
+
+*Code example*
+[source,text]
+----
+filters group=group2 ungrouped=true
+| demodata
+| pointseries x="project" y="size(cost)" color="project"
+| plot defaultStyle={seriesStyle bars=0.75} legend=false
+ font={
+ font size=14
+ family="'Open Sans', Helvetica, Arial, sans-serif"
+ align="left"
+ color="#FFFFFF"
+ weight="lighter"
+ underline=true
+ italic=true
+ }
+| render
+----
+`filters` sets the existing filters as context and accepts `group` parameter to create filter groups.
+
*Accepts:* `null`
[cols="3*^<"]
@@ -718,6 +1215,38 @@ Default: `false`
Creates a font style.
+*Expression syntax*
+[source,js]
+----
+font size=12
+font family=Arial
+font align=middle
+font color=pink
+font weight=lighter
+font underline=true
+font italic=false
+font lHeight=32
+----
+
+*Code example*
+[source,text]
+----
+filters
+| demodata
+| pointseries x="project" y="size(cost)" color="project"
+| plot defaultStyle={seriesStyle bars=0.75} legend=false
+ font={
+ font size=14
+ family="'Open Sans', Helvetica, Arial, sans-serif"
+ align="left"
+ color="#FFFFFF"
+ weight="lighter"
+ underline=true
+ italic=true
+ }
+| render
+----
+
*Accepts:* `null`
[cols="3*^<"]
@@ -781,6 +1310,25 @@ Default: `"normal"`
Formats an ISO8601 date string or a date in milliseconds since epoch using MomentJS. See https://momentjs.com/docs/#/displaying/.
+*Expression syntax*
+[source,js]
+----
+formatdate format=”YYYY-MM-DD”
+formatdate “MM/DD/YYYY”
+----
+
+*Code example*
+[source,text]
+----
+filters
+| demodata
+| mapColumn "time" fn={getCell time | formatdate "MMM 'YY"}
+| pointseries x="time" y="sum(price)" color="state"
+| plot defaultStyle={seriesStyle points=5}
+| render
+----
+This transforms the dates in the `time` field into strings that look like `“Jan ‘19”`, `“Feb ‘19”`, etc. using a MomentJS format.
+
*Accepts:* `number`, `string`
[cols="3*^<"]
@@ -803,6 +1351,26 @@ Alias: `format`
Formats a `number` into a formatted `string` using NumeralJS. See http://numeraljs.com/#format.
+*Expression syntax*
+[source,js]
+----
+formatnumber format=”$0,0.00”
+formatnumber “0.0a”
+----
+
+*Code example*
+[source,text]
+----
+filters
+| demodata
+| math "mean(percent_uptime)"
+| progress shape="gauge"
+ label={formatnumber "0%"}
+ font={font size=24 family="'Open Sans', Helvetica, Arial, sans-serif" color="#000000" align="center"}
+| render
+----
+The `formatnumber` subexpression receives the same `context` as the `progress` function, which is the output of the `math` function. It formats the value into a percentage.
+
*Accepts:* `number`
[cols="3*^<"]
diff --git a/docs/code/code-basic-nav.asciidoc b/docs/code/code-basic-nav.asciidoc
deleted file mode 100644
index ccd290532b669..0000000000000
--- a/docs/code/code-basic-nav.asciidoc
+++ /dev/null
@@ -1,25 +0,0 @@
-[[code-basic-nav]]
-== Basic navigation
-
-[float]
-==== View file structure and information
-The *File* tree on the left is the primary way to navigate through your folder structure. When you are in a directory, *Code* also presents a finder-like view on the right. Additionally, a file path breadcrumb makes it easy to go back to any parent directory.
-
-[float]
-==== Git History and Blame
-The *Directory* view shows the most recent commits. Clicking *View More* or *History* shows the complete commit history of the current folder or file.
-
-[role="screenshot"]
-image::images/code-history.png[]
-
-Clicking *Blame* shows the most recent commit per line.
-
-[role="screenshot"]
-image::images/code-blame.png[]
-
-[float]
-==== Branch selector
-You can use the Branch selector to view different branches of a repo. Note that code intelligence and search index are not available for any branch other than the master branch.
-
-
-include::code-semantic-nav.asciidoc[]
diff --git a/docs/code/code-import-first-repo.asciidoc b/docs/code/code-import-first-repo.asciidoc
deleted file mode 100644
index 0c8b2660edcab..0000000000000
--- a/docs/code/code-import-first-repo.asciidoc
+++ /dev/null
@@ -1,48 +0,0 @@
-[[code-import-first-repo]]
-== Import your first repo
-
-The easiest way to get started with *Code* is to import a real-world repository.
-
-[float]
-==== Before you begin
-You must have a {kib} instance up and running.
-
-If you are in an environment where you have multiple {kib} instances in a cluster, see the <>.
-
-[float]
-==== Enable Code app
-While in beta, you can turn on *Code* by adding the following line to `kibana.yaml`:
-
-[source,yaml]
-----
-xpack.code.ui.enabled: true
-----
-
-[float]
-==== Import your first repository
-. In {Kib}, navigate to *Code*.
-
-. In the *Repository URL* field, paste the following GitHub clone URL:
-+
-[source,bash]
-----
-https://github.com/Microsoft/TypeScript-Node-Starter
-----
-
-`https` is recommend for cloning most git repositories. To clone a private repository, <>.
-
-. Click *Import*.
-+
-A new item in the list displays the cloning and indexing progress of the `TypeScript-Node-Starter` repo.
-+
-[role="screenshot"]
-image::images/code-import-repo.png[]
-
-. After the indexing is complete, navigate to the repo by clicking its name in the list.
-+
-[role="screenshot"]
-image::images/code-starter-root.png[]
-+
-Congratulations! You just imported your first repo into *Code*.
-
-include::code-repo-management.asciidoc[]
diff --git a/docs/code/code-install-lang-server.asciidoc b/docs/code/code-install-lang-server.asciidoc
deleted file mode 100644
index 4d4349e654c08..0000000000000
--- a/docs/code/code-install-lang-server.asciidoc
+++ /dev/null
@@ -1,25 +0,0 @@
-[[code-install-lang-server]]
-== Install language server
-
-*Code* comes with built-in language support for TypeScript. You can install additional languages as a {kib} plugin. Plugin's reduce the distribution size to run Code inside {kib}. Install only the languages needed for your indexed repositories.
-
-[role="screenshot"]
-image::images/code-lang-server-tab.png[]
-
-For the current version, *Code* supports the following languages in addition to TypeScript:
-
-* `Java`
-* `GO`
-
-You can check the status of the language servers and get installation instructions on the *Language Servers* tab. Make sure the status of the language server is `INSTALLED` or `RUNNING` after you restart the {kib} instance.
-[role="screenshot"]
-image::images/code-lang-server-status.png[]
-
-////
-[float]
-=== Ctag language server
-*Code* also uses a Ctag language server to generate symbol information and code intelligence when a dedicated language server is not available. The code intelligence information generated by the Ctag language server is less accurate but covers more languages.
-////
-
-
-include::code-basic-nav.asciidoc[]
diff --git a/docs/code/code-multiple-kibana-instances-config.asciidoc b/docs/code/code-multiple-kibana-instances-config.asciidoc
deleted file mode 100644
index 359e0764d28f1..0000000000000
--- a/docs/code/code-multiple-kibana-instances-config.asciidoc
+++ /dev/null
@@ -1,10 +0,0 @@
-[[code-multiple-kibana-instances-config]]
-== Config for multiple {kib} instances
-If you are using multiple instances of {kib}, you must manually assign at least one {kib} instance as a *Code* `node`. Add the following line of code to your `kibana.yml` file for each {kib} instance you wish to use and restart the instances:
-
-[source,yaml]
-----
-xpack.code.codeNodeUrl: 'http://$YourCodeNodeAddress'
-----
-
-`$YourCodeNoteAddress` is the URL of your assigned *Code* node accessible by other {kib} instances.
diff --git a/docs/code/code-repo-management.asciidoc b/docs/code/code-repo-management.asciidoc
deleted file mode 100644
index 1fbd8934f57be..0000000000000
--- a/docs/code/code-repo-management.asciidoc
+++ /dev/null
@@ -1,76 +0,0 @@
-[[code-repo-management]]
-== Repo management
-
-Code starts with an overview of your repositories. You can then use the UI to add, delete, and reindex a repo.
-[role="screenshot"]
-image::images/code-repo-management.png[]
-
-[float]
-[[add-delete-a-repo]]
-==== Add and delete a repo
-The <> page provides step-by-step instructions for adding a GitHub repo to *Code*. You can fine-tune the hostname of the git clone URL in your `kibana.yml` file.
-
-For security reasons, Code allows only a few <>, such as github.com. To clone private repositories see <>.
-
-To delete a repository, go to the **Repositories** tab, find the name of the repo, and click *Delete*.
-
-[float]
-[[clone-private-repo]]
-==== Clone private repo with an SSH key
-Clones of private repos require an SSH key for authentication. The username associated with your host must have write access to the repository you want to clone.
-
-The following section provides links for generating your ssh key through GitHub. If you already have an SSH key added through your host, skip to step 4.
-
-1. https://help.github.com/en/articles/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent#generating-a-new-ssh-key[Generate an ssh key].
-
-2. https://help.github.com/en/articles/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent#adding-your-ssh-key-to-the-ssh-agent[Add the ssh key to your ssh-agent.]
-
-3. https://help.github.com/en/articles/adding-a-new-ssh-key-to-your-github-account[Add the ssh key to your host].
-
-4. Copy the ssh key into `data/code/credentials/` under the {kib} folder.
-
-You can now copy private Git repositories into Code.
-
-To delete a repository, find the go to the **Repositories** tab, find the name of the repo and click *Delete*.
-
-[float]
-[[reindex-a-repo]]
-==== Reindex a repo
-*Code* automatically reindexes an imported repo at set intervals, but in some cases, you might need to refresh the index manually. For example, you might refresh an index after a new language server installs. Or, you might want to update the index to the HEAD revision immediately. Click *Reindex* to initiate a reindex.
-
-[float]
-[[clone-url-management]]
-==== Clone URL management
-For security reasons, *Code* only allows the following hostnames in the git clone URL by default:
-
-- `github.com`
-- `gitlab.com`
-- `bitbucket.org`
-- `gitbox.apache.org`
-- `eclipse.org`
-
-You can add your own hostname (for example, acme.com) to the whitelist by adding the following line to your `config/kibana.yaml` file:
-
-[source,yaml]
-----
-xpack.code.security.gitHostWhitelist: [ "github.com", "gitlab.com", "bitbucket.org", "gitbox.apache.org", "eclipse.org", "acme.com" ]
-----
-
-Set `xpack.code.security.gitHostWhitelist` to [] (empty list) allow any hostname.
-
-You can also control the protocol to use for the clone address. By default, the following protocols are supported: `[ 'https', 'git', 'ssh' ]`. You can change this value by adding the following line to your `config/kibana.yaml` file. In this example, the user only wants to support the `https` protocol:
-
-[source,yaml]
-----
-xpack.code.security.gitProtocolWhitelist: [ "https" ]
-----
-
-[float]
-[[repo-limitations]]
-==== Limitations
-Consider the following limitations before cloning repositories:
-
-- Only Git is supported. Other version control systems, such as Mercurial and SVN, are not supported.
-- Your disk might not have enough space to clone repositories due to {kib} watermark settings. To update your watermark settings, contact your system administrator and request additional disk space.
-
-include::code-install-lang-server.asciidoc[]
diff --git a/docs/code/code-search.asciidoc b/docs/code/code-search.asciidoc
deleted file mode 100644
index c3086bfb850a0..0000000000000
--- a/docs/code/code-search.asciidoc
+++ /dev/null
@@ -1,24 +0,0 @@
-[[code-search]]
-== Search
-
-[float]
-==== Typeahead search
-The search bar is designed to help you find what you're looking for as quickly as possible. It shows `Symbols`, `Files`, and `Repos` results as you type. Clicking on any result takes you to the definition. You can use the search type dropdown to show all types of results or limit it to a specific search type.
-
-[role="screenshot"]
-image::images/code-quick-search.png[]
-
-[float]
-==== Full-text search
-If the quick search results don’t contain what you are looking for, you can press ‘Enter’ to conduct a full-text search.
-[role="screenshot"]
-image::images/code-full-text-search.png[]
-You can further refine the results by using the repo and language filters on the left.
-
-[float]
-==== Search filter
-You can also use the Search Filters to limit the search scope to certain repos before issuing a query. To search across all repos, remove any applied repo filters. By default, search results are limited to the repo you're currently viewing.
-[role="screenshot"]
-image::images/code-search-filter.png[]
-
-include::code-multiple-kibana-instances-config.asciidoc[]
diff --git a/docs/code/code-semantic-nav.asciidoc b/docs/code/code-semantic-nav.asciidoc
deleted file mode 100644
index a1535f1449dfe..0000000000000
--- a/docs/code/code-semantic-nav.asciidoc
+++ /dev/null
@@ -1,28 +0,0 @@
-[[code-semantic-nav]]
-
-== Semantic code navigation
-
-You can navigate a file with semantic code navigation features if:
-
-- *Code* supports the file's <>
-- You have installed the corresponding <>
-
-[float]
-==== Goto definition and find reference
-Hovering your cursor over a symbol in a file opens information about the symbol, including its qualified name and documentation, when available. You can perform two actions:
-
-* *Goto Definition* navigates to the symbol definition. Definitions defined in a different repo can be found, provided that you have imported the repo with the definition.
-
-* *Find Reference* opens a panel that lists all references to the symbol.
-
-[role="screenshot"]
-image::images/code-semantic-nav.png[]
-
-[float]
-==== View symbol table
-From the *Structure* tab, you can open a symbol table that details the structure of the current class. Clicking on a member function or variable jumps to its definition.
-
-[role="screenshot"]
-image::images/code-symbol-table.png[]
-
-include::code-search.asciidoc[]
diff --git a/docs/code/index.asciidoc b/docs/code/index.asciidoc
deleted file mode 100644
index 799b356cb42c3..0000000000000
--- a/docs/code/index.asciidoc
+++ /dev/null
@@ -1,21 +0,0 @@
-[[code]]
-= Code
-
-[partintro]
---
-
-beta[]
-
-Interaction with source code is pervasive and essential for any technology company. Speed of innovation is limited by how easy it is to search, navigate, and gain insight into your source code.
-Elastic *Code* provides an easy-to-use code search solution that scales with your organization and empowers your team to understand your codebase faster than ever before.
-*Code* offers the following functions:
-
-* Find references and definitions for any object or symbol
-* Typeahead search for symbol definition, file, and repo
-* Symbol table
-* Full-text search with repo and language filters
-
-<> with *Code* by importing your first repo.
---
-
-include::code-import-first-repo.asciidoc[]
diff --git a/docs/developer/core/development-modules.asciidoc b/docs/developer/core/development-modules.asciidoc
index 603c0f2952d0c..b36be6bbb5d25 100644
--- a/docs/developer/core/development-modules.asciidoc
+++ b/docs/developer/core/development-modules.asciidoc
@@ -13,15 +13,6 @@ To prevent this from being an issue the ui module provides "autoloading"
modules. The sole purpose of these modules is to extend the environment with
certain components. Here is a breakdown of those modules:
-- *`import 'ui/autoload/styles'`*
- Imports all styles at the root of `src/legacy/ui/public/styles`
-
-- *`import 'ui/autoload/directives'`*
- Imports all directives in `src/legacy/ui/public/directives`
-
-- *`import 'ui/autoload/filters'`*
- Imports all filters in `src/legacy/ui/public/filters`
-
- *`import 'ui/autoload/modules'`*
Imports angular and several ui services and "components" which Kibana
depends on without importing. The full list of imports is hard coded in the
diff --git a/docs/development/core/public/kibana-plugin-public.chromedoctitle.change.md b/docs/development/core/public/kibana-plugin-public.chromedoctitle.change.md
new file mode 100644
index 0000000000000..eba149bf93a4c
--- /dev/null
+++ b/docs/development/core/public/kibana-plugin-public.chromedoctitle.change.md
@@ -0,0 +1,34 @@
+
+
+[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [ChromeDocTitle](./kibana-plugin-public.chromedoctitle.md) > [change](./kibana-plugin-public.chromedoctitle.change.md)
+
+## ChromeDocTitle.change() method
+
+Changes the current document title.
+
+Signature:
+
+```typescript
+change(newTitle: string | string[]): void;
+```
+
+## Parameters
+
+| Parameter | Type | Description |
+| --- | --- | --- |
+| newTitle | string | string[]
| |
+
+Returns:
+
+`void`
+
+## Example
+
+How to change the title of the document
+
+```ts
+chrome.docTitle.change('My application title')
+chrome.docTitle.change(['My application', 'My section'])
+
+```
+
diff --git a/docs/development/core/public/kibana-plugin-public.chromedoctitle.md b/docs/development/core/public/kibana-plugin-public.chromedoctitle.md
new file mode 100644
index 0000000000000..3c6cfab486288
--- /dev/null
+++ b/docs/development/core/public/kibana-plugin-public.chromedoctitle.md
@@ -0,0 +1,39 @@
+
+
+[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [ChromeDocTitle](./kibana-plugin-public.chromedoctitle.md)
+
+## ChromeDocTitle interface
+
+APIs for accessing and updating the document title.
+
+Signature:
+
+```typescript
+export interface ChromeDocTitle
+```
+
+## Methods
+
+| Method | Description |
+| --- | --- |
+| [change(newTitle)](./kibana-plugin-public.chromedoctitle.change.md) | Changes the current document title. |
+| [reset()](./kibana-plugin-public.chromedoctitle.reset.md) | Resets the document title to it's initial value. (meaning the one present in the title meta at application load.) |
+
+## Example 1
+
+How to change the title of the document
+
+```ts
+chrome.docTitle.change('My application')
+
+```
+
+## Example 2
+
+How to reset the title of the document to it's initial value
+
+```ts
+chrome.docTitle.reset()
+
+```
+
diff --git a/docs/development/core/public/kibana-plugin-public.chromedoctitle.reset.md b/docs/development/core/public/kibana-plugin-public.chromedoctitle.reset.md
new file mode 100644
index 0000000000000..4b4c6f573e006
--- /dev/null
+++ b/docs/development/core/public/kibana-plugin-public.chromedoctitle.reset.md
@@ -0,0 +1,17 @@
+
+
+[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [ChromeDocTitle](./kibana-plugin-public.chromedoctitle.md) > [reset](./kibana-plugin-public.chromedoctitle.reset.md)
+
+## ChromeDocTitle.reset() method
+
+Resets the document title to it's initial value. (meaning the one present in the title meta at application load.)
+
+Signature:
+
+```typescript
+reset(): void;
+```
+Returns:
+
+`void`
+
diff --git a/docs/development/core/public/kibana-plugin-public.chromestart.doctitle.md b/docs/development/core/public/kibana-plugin-public.chromestart.doctitle.md
new file mode 100644
index 0000000000000..71eda64c24646
--- /dev/null
+++ b/docs/development/core/public/kibana-plugin-public.chromestart.doctitle.md
@@ -0,0 +1,13 @@
+
+
+[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [ChromeStart](./kibana-plugin-public.chromestart.md) > [docTitle](./kibana-plugin-public.chromestart.doctitle.md)
+
+## ChromeStart.docTitle property
+
+APIs for accessing and updating the document title.
+
+Signature:
+
+```typescript
+docTitle: ChromeDocTitle;
+```
diff --git a/docs/development/core/public/kibana-plugin-public.chromestart.md b/docs/development/core/public/kibana-plugin-public.chromestart.md
index bc41aa10cce8f..153e06d591404 100644
--- a/docs/development/core/public/kibana-plugin-public.chromestart.md
+++ b/docs/development/core/public/kibana-plugin-public.chromestart.md
@@ -16,6 +16,7 @@ export interface ChromeStart
| Property | Type | Description |
| --- | --- | --- |
+| [docTitle](./kibana-plugin-public.chromestart.doctitle.md) | ChromeDocTitle
| APIs for accessing and updating the document title. |
| [navControls](./kibana-plugin-public.chromestart.navcontrols.md) | ChromeNavControls
| [APIs](./kibana-plugin-public.chromenavcontrols.md) for registering new controls to be displayed in the navigation bar. |
| [navLinks](./kibana-plugin-public.chromestart.navlinks.md) | ChromeNavLinks
| [APIs](./kibana-plugin-public.chromenavlinks.md) for manipulating nav links. |
| [recentlyAccessed](./kibana-plugin-public.chromestart.recentlyaccessed.md) | ChromeRecentlyAccessed
| [APIs](./kibana-plugin-public.chromerecentlyaccessed.md) for recently accessed history. |
diff --git a/docs/development/core/public/kibana-plugin-public.httpservicebase.anonymouspaths.md b/docs/development/core/public/kibana-plugin-public.httpservicebase.anonymouspaths.md
new file mode 100644
index 0000000000000..e94757c5eb031
--- /dev/null
+++ b/docs/development/core/public/kibana-plugin-public.httpservicebase.anonymouspaths.md
@@ -0,0 +1,13 @@
+
+
+[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [HttpServiceBase](./kibana-plugin-public.httpservicebase.md) > [anonymousPaths](./kibana-plugin-public.httpservicebase.anonymouspaths.md)
+
+## HttpServiceBase.anonymousPaths property
+
+APIs for denoting certain paths for not requiring authentication
+
+Signature:
+
+```typescript
+anonymousPaths: IAnonymousPaths;
+```
diff --git a/docs/development/core/public/kibana-plugin-public.httpservicebase.md b/docs/development/core/public/kibana-plugin-public.httpservicebase.md
index a1eef3db42b7d..9ea77c95b343e 100644
--- a/docs/development/core/public/kibana-plugin-public.httpservicebase.md
+++ b/docs/development/core/public/kibana-plugin-public.httpservicebase.md
@@ -15,6 +15,7 @@ export interface HttpServiceBase
| Property | Type | Description |
| --- | --- | --- |
+| [anonymousPaths](./kibana-plugin-public.httpservicebase.anonymouspaths.md) | IAnonymousPaths
| APIs for denoting certain paths for not requiring authentication |
| [basePath](./kibana-plugin-public.httpservicebase.basepath.md) | IBasePath
| APIs for manipulating the basePath on URL segments. |
| [delete](./kibana-plugin-public.httpservicebase.delete.md) | HttpHandler
| Makes an HTTP request with the DELETE method. See [HttpHandler](./kibana-plugin-public.httphandler.md) for options. |
| [fetch](./kibana-plugin-public.httpservicebase.fetch.md) | HttpHandler
| Makes an HTTP request. Defaults to a GET request unless overriden. See [HttpHandler](./kibana-plugin-public.httphandler.md) for options. |
diff --git a/docs/development/core/public/kibana-plugin-public.ianonymouspaths.isanonymous.md b/docs/development/core/public/kibana-plugin-public.ianonymouspaths.isanonymous.md
new file mode 100644
index 0000000000000..d6be78e1e725b
--- /dev/null
+++ b/docs/development/core/public/kibana-plugin-public.ianonymouspaths.isanonymous.md
@@ -0,0 +1,24 @@
+
+
+[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [IAnonymousPaths](./kibana-plugin-public.ianonymouspaths.md) > [isAnonymous](./kibana-plugin-public.ianonymouspaths.isanonymous.md)
+
+## IAnonymousPaths.isAnonymous() method
+
+Determines whether the provided path doesn't require authentication. `path` should include the current basePath.
+
+Signature:
+
+```typescript
+isAnonymous(path: string): boolean;
+```
+
+## Parameters
+
+| Parameter | Type | Description |
+| --- | --- | --- |
+| path | string
| |
+
+Returns:
+
+`boolean`
+
diff --git a/docs/development/core/public/kibana-plugin-public.ianonymouspaths.md b/docs/development/core/public/kibana-plugin-public.ianonymouspaths.md
new file mode 100644
index 0000000000000..1290df28780cf
--- /dev/null
+++ b/docs/development/core/public/kibana-plugin-public.ianonymouspaths.md
@@ -0,0 +1,21 @@
+
+
+[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [IAnonymousPaths](./kibana-plugin-public.ianonymouspaths.md)
+
+## IAnonymousPaths interface
+
+APIs for denoting paths as not requiring authentication
+
+Signature:
+
+```typescript
+export interface IAnonymousPaths
+```
+
+## Methods
+
+| Method | Description |
+| --- | --- |
+| [isAnonymous(path)](./kibana-plugin-public.ianonymouspaths.isanonymous.md) | Determines whether the provided path doesn't require authentication. path
should include the current basePath. |
+| [register(path)](./kibana-plugin-public.ianonymouspaths.register.md) | Register path
as not requiring authentication. path
should not include the current basePath. |
+
diff --git a/docs/development/core/public/kibana-plugin-public.ianonymouspaths.register.md b/docs/development/core/public/kibana-plugin-public.ianonymouspaths.register.md
new file mode 100644
index 0000000000000..3ab9bf438aa16
--- /dev/null
+++ b/docs/development/core/public/kibana-plugin-public.ianonymouspaths.register.md
@@ -0,0 +1,24 @@
+
+
+[Home](./index.md) > [kibana-plugin-public](./kibana-plugin-public.md) > [IAnonymousPaths](./kibana-plugin-public.ianonymouspaths.md) > [register](./kibana-plugin-public.ianonymouspaths.register.md)
+
+## IAnonymousPaths.register() method
+
+Register `path` as not requiring authentication. `path` should not include the current basePath.
+
+Signature:
+
+```typescript
+register(path: string): void;
+```
+
+## Parameters
+
+| Parameter | Type | Description |
+| --- | --- | --- |
+| path | string
| |
+
+Returns:
+
+`void`
+
diff --git a/docs/development/core/public/kibana-plugin-public.md b/docs/development/core/public/kibana-plugin-public.md
index e787621c3aaf9..df0b963e2b627 100644
--- a/docs/development/core/public/kibana-plugin-public.md
+++ b/docs/development/core/public/kibana-plugin-public.md
@@ -32,6 +32,7 @@ The plugin integrates with the core system via lifecycle events: `setup`
| [Capabilities](./kibana-plugin-public.capabilities.md) | The read-only set of capabilities available for the current UI session. Capabilities are simple key-value pairs of (string, boolean), where the string denotes the capability ID, and the boolean is a flag indicating if the capability is enabled or disabled. |
| [ChromeBadge](./kibana-plugin-public.chromebadge.md) | |
| [ChromeBrand](./kibana-plugin-public.chromebrand.md) | |
+| [ChromeDocTitle](./kibana-plugin-public.chromedoctitle.md) | APIs for accessing and updating the document title. |
| [ChromeNavControl](./kibana-plugin-public.chromenavcontrol.md) | |
| [ChromeNavControls](./kibana-plugin-public.chromenavcontrols.md) | [APIs](./kibana-plugin-public.chromenavcontrols.md) for registering new controls to be displayed in the navigation bar. |
| [ChromeNavLink](./kibana-plugin-public.chromenavlink.md) | |
@@ -57,6 +58,7 @@ The plugin integrates with the core system via lifecycle events: `setup`
| [HttpResponse](./kibana-plugin-public.httpresponse.md) | |
| [HttpServiceBase](./kibana-plugin-public.httpservicebase.md) | |
| [I18nStart](./kibana-plugin-public.i18nstart.md) | I18nStart.Context is required by any localizable React component from @kbn/i18n and @elastic/eui packages and is supposed to be used as the topmost component for any i18n-compatible React tree. |
+| [IAnonymousPaths](./kibana-plugin-public.ianonymouspaths.md) | APIs for denoting paths as not requiring authentication |
| [IBasePath](./kibana-plugin-public.ibasepath.md) | APIs for manipulating the basePath on URL segments. |
| [IContextContainer](./kibana-plugin-public.icontextcontainer.md) | An object that handles registration of context providers and configuring handlers with context. |
| [IHttpFetchError](./kibana-plugin-public.ihttpfetcherror.md) | |
@@ -119,5 +121,5 @@ The plugin integrates with the core system via lifecycle events: `setup`
| [ToastInputFields](./kibana-plugin-public.toastinputfields.md) | Allowed fields for [ToastInput](./kibana-plugin-public.toastinput.md). |
| [ToastsSetup](./kibana-plugin-public.toastssetup.md) | [IToasts](./kibana-plugin-public.itoasts.md) |
| [ToastsStart](./kibana-plugin-public.toastsstart.md) | [IToasts](./kibana-plugin-public.itoasts.md) |
-| [UiSettingsClientContract](./kibana-plugin-public.uisettingsclientcontract.md) | [UiSettingsClient](./kibana-plugin-public.uisettingsclient.md) |
+| [UiSettingsClientContract](./kibana-plugin-public.uisettingsclientcontract.md) | Client-side client that provides access to the advanced settings stored in elasticsearch. The settings provide control over the behavior of the Kibana application. For example, a user can specify how to display numeric or date fields. Users can adjust the settings via Management UI. [UiSettingsClient](./kibana-plugin-public.uisettingsclient.md) |
diff --git a/docs/development/core/public/kibana-plugin-public.uisettingsclient.getall.md b/docs/development/core/public/kibana-plugin-public.uisettingsclient.getall.md
index 5eaf06e7dd682..06daf8e8151cd 100644
--- a/docs/development/core/public/kibana-plugin-public.uisettingsclient.getall.md
+++ b/docs/development/core/public/kibana-plugin-public.uisettingsclient.getall.md
@@ -9,9 +9,9 @@ Gets the metadata about all uiSettings, including the type, default value, and u
Signature:
```typescript
-getAll(): UiSettingsState;
+getAll(): Record>;
```
Returns:
-`UiSettingsState`
+`Record>`
diff --git a/docs/development/core/public/kibana-plugin-public.uisettingsclientcontract.md b/docs/development/core/public/kibana-plugin-public.uisettingsclientcontract.md
index 6eda1fd3274c6..7173386d88265 100644
--- a/docs/development/core/public/kibana-plugin-public.uisettingsclientcontract.md
+++ b/docs/development/core/public/kibana-plugin-public.uisettingsclientcontract.md
@@ -4,7 +4,7 @@
## UiSettingsClientContract type
-[UiSettingsClient](./kibana-plugin-public.uisettingsclient.md)
+Client-side client that provides access to the advanced settings stored in elasticsearch. The settings provide control over the behavior of the Kibana application. For example, a user can specify how to display numeric or date fields. Users can adjust the settings via Management UI. [UiSettingsClient](./kibana-plugin-public.uisettingsclient.md)
Signature:
diff --git a/docs/development/core/server/kibana-plugin-server.coresetup.md b/docs/development/core/server/kibana-plugin-server.coresetup.md
index a6dda69fd154e..c51459bc41a43 100644
--- a/docs/development/core/server/kibana-plugin-server.coresetup.md
+++ b/docs/development/core/server/kibana-plugin-server.coresetup.md
@@ -19,4 +19,5 @@ export interface CoreSetup
| [context](./kibana-plugin-server.coresetup.context.md) | ContextSetup
| [ContextSetup](./kibana-plugin-server.contextsetup.md) |
| [elasticsearch](./kibana-plugin-server.coresetup.elasticsearch.md) | ElasticsearchServiceSetup
| [ElasticsearchServiceSetup](./kibana-plugin-server.elasticsearchservicesetup.md) |
| [http](./kibana-plugin-server.coresetup.http.md) | HttpServiceSetup
| [HttpServiceSetup](./kibana-plugin-server.httpservicesetup.md) |
+| [uiSettings](./kibana-plugin-server.coresetup.uisettings.md) | UiSettingsServiceSetup
| [UiSettingsServiceSetup](./kibana-plugin-server.uisettingsservicesetup.md) |
diff --git a/docs/development/core/server/kibana-plugin-server.coresetup.uisettings.md b/docs/development/core/server/kibana-plugin-server.coresetup.uisettings.md
new file mode 100644
index 0000000000000..54120d7c3fa8d
--- /dev/null
+++ b/docs/development/core/server/kibana-plugin-server.coresetup.uisettings.md
@@ -0,0 +1,13 @@
+
+
+[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [CoreSetup](./kibana-plugin-server.coresetup.md) > [uiSettings](./kibana-plugin-server.coresetup.uisettings.md)
+
+## CoreSetup.uiSettings property
+
+[UiSettingsServiceSetup](./kibana-plugin-server.uisettingsservicesetup.md)
+
+Signature:
+
+```typescript
+uiSettings: UiSettingsServiceSetup;
+```
diff --git a/docs/development/core/server/kibana-plugin-server.iuisettingsclient.getdefaults.md b/docs/development/core/server/kibana-plugin-server.iuisettingsclient.getdefaults.md
deleted file mode 100644
index 29faa6d945b43..0000000000000
--- a/docs/development/core/server/kibana-plugin-server.iuisettingsclient.getdefaults.md
+++ /dev/null
@@ -1,13 +0,0 @@
-
-
-[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [IUiSettingsClient](./kibana-plugin-server.iuisettingsclient.md) > [getDefaults](./kibana-plugin-server.iuisettingsclient.getdefaults.md)
-
-## IUiSettingsClient.getDefaults property
-
-Returns uiSettings default values [UiSettingsParams](./kibana-plugin-server.uisettingsparams.md)
-
-Signature:
-
-```typescript
-getDefaults: () => Record;
-```
diff --git a/docs/development/core/server/kibana-plugin-server.iuisettingsclient.getregistered.md b/docs/development/core/server/kibana-plugin-server.iuisettingsclient.getregistered.md
new file mode 100644
index 0000000000000..16ae4c3dd8b36
--- /dev/null
+++ b/docs/development/core/server/kibana-plugin-server.iuisettingsclient.getregistered.md
@@ -0,0 +1,13 @@
+
+
+[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [IUiSettingsClient](./kibana-plugin-server.iuisettingsclient.md) > [getRegistered](./kibana-plugin-server.iuisettingsclient.getregistered.md)
+
+## IUiSettingsClient.getRegistered property
+
+Returns registered uiSettings values [UiSettingsParams](./kibana-plugin-server.uisettingsparams.md)
+
+Signature:
+
+```typescript
+getRegistered: () => Readonly>;
+```
diff --git a/docs/development/core/server/kibana-plugin-server.iuisettingsclient.getuserprovided.md b/docs/development/core/server/kibana-plugin-server.iuisettingsclient.getuserprovided.md
index 9a449b64ed5d0..134039cfa91f3 100644
--- a/docs/development/core/server/kibana-plugin-server.iuisettingsclient.getuserprovided.md
+++ b/docs/development/core/server/kibana-plugin-server.iuisettingsclient.getuserprovided.md
@@ -9,8 +9,5 @@ Retrieves a set of all uiSettings values set by the user.
Signature:
```typescript
-getUserProvided: () => Promise>;
+getUserProvided: () => Promise>>;
```
diff --git a/docs/development/core/server/kibana-plugin-server.iuisettingsclient.md b/docs/development/core/server/kibana-plugin-server.iuisettingsclient.md
index 142f33d27c385..a4697ddbbb85e 100644
--- a/docs/development/core/server/kibana-plugin-server.iuisettingsclient.md
+++ b/docs/development/core/server/kibana-plugin-server.iuisettingsclient.md
@@ -4,7 +4,7 @@
## IUiSettingsClient interface
-Service that provides access to the UiSettings stored in elasticsearch.
+Server-side client that provides access to the advanced settings stored in elasticsearch. The settings provide control over the behavior of the Kibana application. For example, a user can specify how to display numeric or date fields. Users can adjust the settings via Management UI.
Signature:
@@ -18,8 +18,8 @@ export interface IUiSettingsClient
| --- | --- | --- |
| [get](./kibana-plugin-server.iuisettingsclient.get.md) | <T extends SavedObjectAttribute = any>(key: string) => Promise<T>
| Retrieves uiSettings values set by the user with fallbacks to default values if not specified. |
| [getAll](./kibana-plugin-server.iuisettingsclient.getall.md) | <T extends SavedObjectAttribute = any>() => Promise<Record<string, T>>
| Retrieves a set of all uiSettings values set by the user with fallbacks to default values if not specified. |
-| [getDefaults](./kibana-plugin-server.iuisettingsclient.getdefaults.md) | () => Record<string, UiSettingsParams>
| Returns uiSettings default values [UiSettingsParams](./kibana-plugin-server.uisettingsparams.md) |
-| [getUserProvided](./kibana-plugin-server.iuisettingsclient.getuserprovided.md) | <T extends SavedObjectAttribute = any>() => Promise<Record<string, {
userValue?: T;
isOverridden?: boolean;
}>>
| Retrieves a set of all uiSettings values set by the user. |
+| [getRegistered](./kibana-plugin-server.iuisettingsclient.getregistered.md) | () => Readonly<Record<string, UiSettingsParams>>
| Returns registered uiSettings values [UiSettingsParams](./kibana-plugin-server.uisettingsparams.md) |
+| [getUserProvided](./kibana-plugin-server.iuisettingsclient.getuserprovided.md) | <T extends SavedObjectAttribute = any>() => Promise<Record<string, UserProvidedValues<T>>>
| Retrieves a set of all uiSettings values set by the user. |
| [isOverridden](./kibana-plugin-server.iuisettingsclient.isoverridden.md) | (key: string) => boolean
| Shows whether the uiSettings value set by the user. |
| [remove](./kibana-plugin-server.iuisettingsclient.remove.md) | (key: string) => Promise<void>
| Removes uiSettings value by key. |
| [removeMany](./kibana-plugin-server.iuisettingsclient.removemany.md) | (keys: string[]) => Promise<void>
| Removes multiple uiSettings values by keys. |
diff --git a/docs/development/core/server/kibana-plugin-server.md b/docs/development/core/server/kibana-plugin-server.md
index 2f81afacf4bb4..9907750b8742f 100644
--- a/docs/development/core/server/kibana-plugin-server.md
+++ b/docs/development/core/server/kibana-plugin-server.md
@@ -63,7 +63,7 @@ The plugin integrates with the core system via lifecycle events: `setup`
| [IKibanaSocket](./kibana-plugin-server.ikibanasocket.md) | A tiny abstraction for TCP socket. |
| [IndexSettingsDeprecationInfo](./kibana-plugin-server.indexsettingsdeprecationinfo.md) | |
| [IRouter](./kibana-plugin-server.irouter.md) | Registers route handlers for specified resource path and method. See [RouteConfig](./kibana-plugin-server.routeconfig.md) and [RequestHandler](./kibana-plugin-server.requesthandler.md) for more information about arguments to route registrations. |
-| [IUiSettingsClient](./kibana-plugin-server.iuisettingsclient.md) | Service that provides access to the UiSettings stored in elasticsearch. |
+| [IUiSettingsClient](./kibana-plugin-server.iuisettingsclient.md) | Server-side client that provides access to the advanced settings stored in elasticsearch. The settings provide control over the behavior of the Kibana application. For example, a user can specify how to display numeric or date fields. Users can adjust the settings via Management UI. |
| [KibanaRequestRoute](./kibana-plugin-server.kibanarequestroute.md) | Request specific route information exposed to a handler. |
| [LegacyRequest](./kibana-plugin-server.legacyrequest.md) | |
| [LegacyServiceSetupDeps](./kibana-plugin-server.legacyservicesetupdeps.md) | |
@@ -90,10 +90,12 @@ The plugin integrates with the core system via lifecycle events: `setup`
| [SavedObjectsBulkGetObject](./kibana-plugin-server.savedobjectsbulkgetobject.md) | |
| [SavedObjectsBulkResponse](./kibana-plugin-server.savedobjectsbulkresponse.md) | |
| [SavedObjectsBulkUpdateObject](./kibana-plugin-server.savedobjectsbulkupdateobject.md) | |
+| [SavedObjectsBulkUpdateOptions](./kibana-plugin-server.savedobjectsbulkupdateoptions.md) | |
| [SavedObjectsBulkUpdateResponse](./kibana-plugin-server.savedobjectsbulkupdateresponse.md) | |
| [SavedObjectsClientProviderOptions](./kibana-plugin-server.savedobjectsclientprovideroptions.md) | Options to control the creation of the Saved Objects Client. |
| [SavedObjectsClientWrapperOptions](./kibana-plugin-server.savedobjectsclientwrapperoptions.md) | Options passed to each SavedObjectsClientWrapperFactory to aid in creating the wrapper instance. |
| [SavedObjectsCreateOptions](./kibana-plugin-server.savedobjectscreateoptions.md) | |
+| [SavedObjectsDeleteOptions](./kibana-plugin-server.savedobjectsdeleteoptions.md) | |
| [SavedObjectsExportOptions](./kibana-plugin-server.savedobjectsexportoptions.md) | Options controlling the export operation. |
| [SavedObjectsExportResultDetails](./kibana-plugin-server.savedobjectsexportresultdetails.md) | Structure of the export result details entry |
| [SavedObjectsFindOptions](./kibana-plugin-server.savedobjectsfindoptions.md) | |
@@ -116,6 +118,8 @@ The plugin integrates with the core system via lifecycle events: `setup`
| [SessionStorageCookieOptions](./kibana-plugin-server.sessionstoragecookieoptions.md) | Configuration used to create HTTP session storage based on top of cookie mechanism. |
| [SessionStorageFactory](./kibana-plugin-server.sessionstoragefactory.md) | SessionStorage factory to bind one to an incoming request |
| [UiSettingsParams](./kibana-plugin-server.uisettingsparams.md) | UiSettings parameters defined by the plugins. |
+| [UiSettingsServiceSetup](./kibana-plugin-server.uisettingsservicesetup.md) | |
+| [UserProvidedValues](./kibana-plugin-server.userprovidedvalues.md) | Describes the values explicitly set by user. |
## Variables
@@ -149,6 +153,7 @@ The plugin integrates with the core system via lifecycle events: `setup`
| [LifecycleResponseFactory](./kibana-plugin-server.lifecycleresponsefactory.md) | Creates an object containing redirection or error response with error details, HTTP headers, and other data transmitted to the client. |
| [MIGRATION\_ASSISTANCE\_INDEX\_ACTION](./kibana-plugin-server.migration_assistance_index_action.md) | |
| [MIGRATION\_DEPRECATION\_LEVEL](./kibana-plugin-server.migration_deprecation_level.md) | |
+| [MutatingOperationRefreshSetting](./kibana-plugin-server.mutatingoperationrefreshsetting.md) | Elasticsearch Refresh setting for mutating operation |
| [OnPostAuthHandler](./kibana-plugin-server.onpostauthhandler.md) | See [OnPostAuthToolkit](./kibana-plugin-server.onpostauthtoolkit.md). |
| [OnPreAuthHandler](./kibana-plugin-server.onpreauthhandler.md) | See [OnPreAuthToolkit](./kibana-plugin-server.onpreauthtoolkit.md). |
| [PluginInitializer](./kibana-plugin-server.plugininitializer.md) | The plugin
export at the root of a plugin's server
directory should conform to this interface. |
diff --git a/docs/development/core/server/kibana-plugin-server.mutatingoperationrefreshsetting.md b/docs/development/core/server/kibana-plugin-server.mutatingoperationrefreshsetting.md
new file mode 100644
index 0000000000000..94c8fa8c22ef6
--- /dev/null
+++ b/docs/development/core/server/kibana-plugin-server.mutatingoperationrefreshsetting.md
@@ -0,0 +1,13 @@
+
+
+[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [MutatingOperationRefreshSetting](./kibana-plugin-server.mutatingoperationrefreshsetting.md)
+
+## MutatingOperationRefreshSetting type
+
+Elasticsearch Refresh setting for mutating operation
+
+Signature:
+
+```typescript
+export declare type MutatingOperationRefreshSetting = boolean | 'wait_for';
+```
diff --git a/docs/development/core/server/kibana-plugin-server.requesthandlercontext.core.md b/docs/development/core/server/kibana-plugin-server.requesthandlercontext.core.md
index e1ea358320b9a..2d8b27ecb6c67 100644
--- a/docs/development/core/server/kibana-plugin-server.requesthandlercontext.core.md
+++ b/docs/development/core/server/kibana-plugin-server.requesthandlercontext.core.md
@@ -15,5 +15,8 @@ core: {
dataClient: IScopedClusterClient;
adminClient: IScopedClusterClient;
};
+ uiSettings: {
+ client: IUiSettingsClient;
+ };
};
```
diff --git a/docs/development/core/server/kibana-plugin-server.requesthandlercontext.md b/docs/development/core/server/kibana-plugin-server.requesthandlercontext.md
index 37a40f98adef3..c9fc80596efa9 100644
--- a/docs/development/core/server/kibana-plugin-server.requesthandlercontext.md
+++ b/docs/development/core/server/kibana-plugin-server.requesthandlercontext.md
@@ -18,5 +18,5 @@ export interface RequestHandlerContext
| Property | Type | Description |
| --- | --- | --- |
-| [core](./kibana-plugin-server.requesthandlercontext.core.md) | {
savedObjects: {
client: SavedObjectsClientContract;
};
elasticsearch: {
dataClient: IScopedClusterClient;
adminClient: IScopedClusterClient;
};
}
| |
+| [core](./kibana-plugin-server.requesthandlercontext.core.md) | {
savedObjects: {
client: SavedObjectsClientContract;
};
elasticsearch: {
dataClient: IScopedClusterClient;
adminClient: IScopedClusterClient;
};
uiSettings: {
client: IUiSettingsClient;
};
}
| |
diff --git a/docs/development/core/server/kibana-plugin-server.savedobjectsbulkupdateoptions.md b/docs/development/core/server/kibana-plugin-server.savedobjectsbulkupdateoptions.md
new file mode 100644
index 0000000000000..920a6ca224df4
--- /dev/null
+++ b/docs/development/core/server/kibana-plugin-server.savedobjectsbulkupdateoptions.md
@@ -0,0 +1,19 @@
+
+
+[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [SavedObjectsBulkUpdateOptions](./kibana-plugin-server.savedobjectsbulkupdateoptions.md)
+
+## SavedObjectsBulkUpdateOptions interface
+
+
+Signature:
+
+```typescript
+export interface SavedObjectsBulkUpdateOptions extends SavedObjectsBaseOptions
+```
+
+## Properties
+
+| Property | Type | Description |
+| --- | --- | --- |
+| [refresh](./kibana-plugin-server.savedobjectsbulkupdateoptions.refresh.md) | MutatingOperationRefreshSetting
| The Elasticsearch Refresh setting for this operation |
+
diff --git a/docs/development/core/server/kibana-plugin-server.savedobjectsbulkupdateoptions.refresh.md b/docs/development/core/server/kibana-plugin-server.savedobjectsbulkupdateoptions.refresh.md
new file mode 100644
index 0000000000000..35e9e6483da10
--- /dev/null
+++ b/docs/development/core/server/kibana-plugin-server.savedobjectsbulkupdateoptions.refresh.md
@@ -0,0 +1,13 @@
+
+
+[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [SavedObjectsBulkUpdateOptions](./kibana-plugin-server.savedobjectsbulkupdateoptions.md) > [refresh](./kibana-plugin-server.savedobjectsbulkupdateoptions.refresh.md)
+
+## SavedObjectsBulkUpdateOptions.refresh property
+
+The Elasticsearch Refresh setting for this operation
+
+Signature:
+
+```typescript
+refresh?: MutatingOperationRefreshSetting;
+```
diff --git a/docs/development/core/server/kibana-plugin-server.savedobjectsclient.bulkupdate.md b/docs/development/core/server/kibana-plugin-server.savedobjectsclient.bulkupdate.md
index 107e71959f706..30db524ffa02c 100644
--- a/docs/development/core/server/kibana-plugin-server.savedobjectsclient.bulkupdate.md
+++ b/docs/development/core/server/kibana-plugin-server.savedobjectsclient.bulkupdate.md
@@ -9,7 +9,7 @@ Bulk Updates multiple SavedObject at once
Signature:
```typescript
-bulkUpdate(objects: Array>, options?: SavedObjectsBaseOptions): Promise>;
+bulkUpdate(objects: Array>, options?: SavedObjectsBulkUpdateOptions): Promise>;
```
## Parameters
@@ -17,7 +17,7 @@ bulkUpdate(objects: ArrayArray<SavedObjectsBulkUpdateObject<T>> | |
-| options | SavedObjectsBaseOptions
| |
+| options | SavedObjectsBulkUpdateOptions
| |
Returns:
diff --git a/docs/development/core/server/kibana-plugin-server.savedobjectsclient.delete.md b/docs/development/core/server/kibana-plugin-server.savedobjectsclient.delete.md
index 657f56d591e77..c20c7e886490a 100644
--- a/docs/development/core/server/kibana-plugin-server.savedobjectsclient.delete.md
+++ b/docs/development/core/server/kibana-plugin-server.savedobjectsclient.delete.md
@@ -9,7 +9,7 @@ Deletes a SavedObject
Signature:
```typescript
-delete(type: string, id: string, options?: SavedObjectsBaseOptions): Promise<{}>;
+delete(type: string, id: string, options?: SavedObjectsDeleteOptions): Promise<{}>;
```
## Parameters
@@ -18,7 +18,7 @@ delete(type: string, id: string, options?: SavedObjectsBaseOptions): Promise<{}>
| --- | --- | --- |
| type | string
| |
| id | string
| |
-| options | SavedObjectsBaseOptions
| |
+| options | SavedObjectsDeleteOptions
| |
Returns:
diff --git a/docs/development/core/server/kibana-plugin-server.savedobjectscreateoptions.md b/docs/development/core/server/kibana-plugin-server.savedobjectscreateoptions.md
index 16549e420ac01..e4ad636056915 100644
--- a/docs/development/core/server/kibana-plugin-server.savedobjectscreateoptions.md
+++ b/docs/development/core/server/kibana-plugin-server.savedobjectscreateoptions.md
@@ -19,4 +19,5 @@ export interface SavedObjectsCreateOptions extends SavedObjectsBaseOptions
| [migrationVersion](./kibana-plugin-server.savedobjectscreateoptions.migrationversion.md) | SavedObjectsMigrationVersion
| Information about the migrations that have been applied to this SavedObject. When Kibana starts up, KibanaMigrator detects outdated documents and migrates them based on this value. For each migration that has been applied, the plugin's name is used as a key and the latest migration version as the value. |
| [overwrite](./kibana-plugin-server.savedobjectscreateoptions.overwrite.md) | boolean
| Overwrite existing documents (defaults to false) |
| [references](./kibana-plugin-server.savedobjectscreateoptions.references.md) | SavedObjectReference[]
| |
+| [refresh](./kibana-plugin-server.savedobjectscreateoptions.refresh.md) | MutatingOperationRefreshSetting
| The Elasticsearch Refresh setting for this operation |
diff --git a/docs/development/core/server/kibana-plugin-server.savedobjectscreateoptions.refresh.md b/docs/development/core/server/kibana-plugin-server.savedobjectscreateoptions.refresh.md
new file mode 100644
index 0000000000000..785874a12c8c4
--- /dev/null
+++ b/docs/development/core/server/kibana-plugin-server.savedobjectscreateoptions.refresh.md
@@ -0,0 +1,13 @@
+
+
+[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [SavedObjectsCreateOptions](./kibana-plugin-server.savedobjectscreateoptions.md) > [refresh](./kibana-plugin-server.savedobjectscreateoptions.refresh.md)
+
+## SavedObjectsCreateOptions.refresh property
+
+The Elasticsearch Refresh setting for this operation
+
+Signature:
+
+```typescript
+refresh?: MutatingOperationRefreshSetting;
+```
diff --git a/docs/development/core/server/kibana-plugin-server.savedobjectsdeleteoptions.md b/docs/development/core/server/kibana-plugin-server.savedobjectsdeleteoptions.md
new file mode 100644
index 0000000000000..2c641ba5cc8d8
--- /dev/null
+++ b/docs/development/core/server/kibana-plugin-server.savedobjectsdeleteoptions.md
@@ -0,0 +1,19 @@
+
+
+[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [SavedObjectsDeleteOptions](./kibana-plugin-server.savedobjectsdeleteoptions.md)
+
+## SavedObjectsDeleteOptions interface
+
+
+Signature:
+
+```typescript
+export interface SavedObjectsDeleteOptions extends SavedObjectsBaseOptions
+```
+
+## Properties
+
+| Property | Type | Description |
+| --- | --- | --- |
+| [refresh](./kibana-plugin-server.savedobjectsdeleteoptions.refresh.md) | MutatingOperationRefreshSetting
| The Elasticsearch Refresh setting for this operation |
+
diff --git a/docs/development/core/server/kibana-plugin-server.savedobjectsdeleteoptions.refresh.md b/docs/development/core/server/kibana-plugin-server.savedobjectsdeleteoptions.refresh.md
new file mode 100644
index 0000000000000..782c52956f297
--- /dev/null
+++ b/docs/development/core/server/kibana-plugin-server.savedobjectsdeleteoptions.refresh.md
@@ -0,0 +1,13 @@
+
+
+[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [SavedObjectsDeleteOptions](./kibana-plugin-server.savedobjectsdeleteoptions.md) > [refresh](./kibana-plugin-server.savedobjectsdeleteoptions.refresh.md)
+
+## SavedObjectsDeleteOptions.refresh property
+
+The Elasticsearch Refresh setting for this operation
+
+Signature:
+
+```typescript
+refresh?: MutatingOperationRefreshSetting;
+```
diff --git a/docs/development/core/server/kibana-plugin-server.savedobjectsupdateoptions.md b/docs/development/core/server/kibana-plugin-server.savedobjectsupdateoptions.md
index 7fcd362e937a0..49e8946ad2826 100644
--- a/docs/development/core/server/kibana-plugin-server.savedobjectsupdateoptions.md
+++ b/docs/development/core/server/kibana-plugin-server.savedobjectsupdateoptions.md
@@ -16,5 +16,6 @@ export interface SavedObjectsUpdateOptions extends SavedObjectsBaseOptions
| Property | Type | Description |
| --- | --- | --- |
| [references](./kibana-plugin-server.savedobjectsupdateoptions.references.md) | SavedObjectReference[]
| A reference to another saved object. |
+| [refresh](./kibana-plugin-server.savedobjectsupdateoptions.refresh.md) | MutatingOperationRefreshSetting
| The Elasticsearch Refresh setting for this operation |
| [version](./kibana-plugin-server.savedobjectsupdateoptions.version.md) | string
| An opaque version number which changes on each successful write operation. Can be used for implementing optimistic concurrency control. |
diff --git a/docs/development/core/server/kibana-plugin-server.savedobjectsupdateoptions.refresh.md b/docs/development/core/server/kibana-plugin-server.savedobjectsupdateoptions.refresh.md
new file mode 100644
index 0000000000000..bb1142c242012
--- /dev/null
+++ b/docs/development/core/server/kibana-plugin-server.savedobjectsupdateoptions.refresh.md
@@ -0,0 +1,13 @@
+
+
+[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [SavedObjectsUpdateOptions](./kibana-plugin-server.savedobjectsupdateoptions.md) > [refresh](./kibana-plugin-server.savedobjectsupdateoptions.refresh.md)
+
+## SavedObjectsUpdateOptions.refresh property
+
+The Elasticsearch Refresh setting for this operation
+
+Signature:
+
+```typescript
+refresh?: MutatingOperationRefreshSetting;
+```
diff --git a/docs/development/core/server/kibana-plugin-server.uisettingsparams.category.md b/docs/development/core/server/kibana-plugin-server.uisettingsparams.category.md
index 47aedbfbf2810..6bf1b17dc947a 100644
--- a/docs/development/core/server/kibana-plugin-server.uisettingsparams.category.md
+++ b/docs/development/core/server/kibana-plugin-server.uisettingsparams.category.md
@@ -9,5 +9,5 @@ used to group the configured setting in the UI
Signature:
```typescript
-category: string[];
+category?: string[];
```
diff --git a/docs/development/core/server/kibana-plugin-server.uisettingsparams.description.md b/docs/development/core/server/kibana-plugin-server.uisettingsparams.description.md
index 8d8887285ae2e..6a203629f5425 100644
--- a/docs/development/core/server/kibana-plugin-server.uisettingsparams.description.md
+++ b/docs/development/core/server/kibana-plugin-server.uisettingsparams.description.md
@@ -9,5 +9,5 @@ description provided to a user in UI
Signature:
```typescript
-description: string;
+description?: string;
```
diff --git a/docs/development/core/server/kibana-plugin-server.uisettingsparams.md b/docs/development/core/server/kibana-plugin-server.uisettingsparams.md
index 275111c05eff9..a38499e8f37dd 100644
--- a/docs/development/core/server/kibana-plugin-server.uisettingsparams.md
+++ b/docs/development/core/server/kibana-plugin-server.uisettingsparams.md
@@ -20,7 +20,7 @@ export interface UiSettingsParams
| [description](./kibana-plugin-server.uisettingsparams.description.md) | string
| description provided to a user in UI |
| [name](./kibana-plugin-server.uisettingsparams.name.md) | string
| title in the UI |
| [optionLabels](./kibana-plugin-server.uisettingsparams.optionlabels.md) | Record<string, string>
| text labels for 'select' type UI element |
-| [options](./kibana-plugin-server.uisettingsparams.options.md) | string[]
| a range of valid values |
+| [options](./kibana-plugin-server.uisettingsparams.options.md) | string[]
| array of permitted values for this setting |
| [readonly](./kibana-plugin-server.uisettingsparams.readonly.md) | boolean
| a flag indicating that value cannot be changed |
| [requiresPageReload](./kibana-plugin-server.uisettingsparams.requirespagereload.md) | boolean
| a flag indicating whether new value applying requires page reloading |
| [type](./kibana-plugin-server.uisettingsparams.type.md) | UiSettingsType
| defines a type of UI element [UiSettingsType](./kibana-plugin-server.uisettingstype.md) |
diff --git a/docs/development/core/server/kibana-plugin-server.uisettingsparams.name.md b/docs/development/core/server/kibana-plugin-server.uisettingsparams.name.md
index 2b414eefffed2..07905ca7de20a 100644
--- a/docs/development/core/server/kibana-plugin-server.uisettingsparams.name.md
+++ b/docs/development/core/server/kibana-plugin-server.uisettingsparams.name.md
@@ -9,5 +9,5 @@ title in the UI
Signature:
```typescript
-name: string;
+name?: string;
```
diff --git a/docs/development/core/server/kibana-plugin-server.uisettingsparams.options.md b/docs/development/core/server/kibana-plugin-server.uisettingsparams.options.md
index 71eecdfabc4a0..2220feab74ffd 100644
--- a/docs/development/core/server/kibana-plugin-server.uisettingsparams.options.md
+++ b/docs/development/core/server/kibana-plugin-server.uisettingsparams.options.md
@@ -4,7 +4,7 @@
## UiSettingsParams.options property
-a range of valid values
+array of permitted values for this setting
Signature:
diff --git a/docs/development/core/server/kibana-plugin-server.uisettingsparams.value.md b/docs/development/core/server/kibana-plugin-server.uisettingsparams.value.md
index 455756899ecfc..397498ccf5c11 100644
--- a/docs/development/core/server/kibana-plugin-server.uisettingsparams.value.md
+++ b/docs/development/core/server/kibana-plugin-server.uisettingsparams.value.md
@@ -9,5 +9,5 @@ default value to fall back to if a user doesn't provide any
Signature:
```typescript
-value: SavedObjectAttribute;
+value?: SavedObjectAttribute;
```
diff --git a/docs/development/core/server/kibana-plugin-server.uisettingsservicesetup.md b/docs/development/core/server/kibana-plugin-server.uisettingsservicesetup.md
new file mode 100644
index 0000000000000..8dde78f633d88
--- /dev/null
+++ b/docs/development/core/server/kibana-plugin-server.uisettingsservicesetup.md
@@ -0,0 +1,19 @@
+
+
+[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [UiSettingsServiceSetup](./kibana-plugin-server.uisettingsservicesetup.md)
+
+## UiSettingsServiceSetup interface
+
+
+Signature:
+
+```typescript
+export interface UiSettingsServiceSetup
+```
+
+## Methods
+
+| Method | Description |
+| --- | --- |
+| [register(settings)](./kibana-plugin-server.uisettingsservicesetup.register.md) | Sets settings with default values for the uiSettings. |
+
diff --git a/docs/development/core/server/kibana-plugin-server.uisettingsservicesetup.register.md b/docs/development/core/server/kibana-plugin-server.uisettingsservicesetup.register.md
new file mode 100644
index 0000000000000..8091a7cec44aa
--- /dev/null
+++ b/docs/development/core/server/kibana-plugin-server.uisettingsservicesetup.register.md
@@ -0,0 +1,28 @@
+
+
+[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [UiSettingsServiceSetup](./kibana-plugin-server.uisettingsservicesetup.md) > [register](./kibana-plugin-server.uisettingsservicesetup.register.md)
+
+## UiSettingsServiceSetup.register() method
+
+Sets settings with default values for the uiSettings.
+
+Signature:
+
+```typescript
+register(settings: Record): void;
+```
+
+## Parameters
+
+| Parameter | Type | Description |
+| --- | --- | --- |
+| settings | Record<string, UiSettingsParams>
| |
+
+Returns:
+
+`void`
+
+## Example
+
+setup(core: CoreSetup){ core.uiSettings.register(\[{ foo: { name: i18n.translate('my foo settings'), value: true, description: 'add some awesomeness', }, }\]); }
+
diff --git a/docs/development/core/server/kibana-plugin-server.userprovidedvalues.isoverridden.md b/docs/development/core/server/kibana-plugin-server.userprovidedvalues.isoverridden.md
new file mode 100644
index 0000000000000..01e04b490595d
--- /dev/null
+++ b/docs/development/core/server/kibana-plugin-server.userprovidedvalues.isoverridden.md
@@ -0,0 +1,11 @@
+
+
+[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [UserProvidedValues](./kibana-plugin-server.userprovidedvalues.md) > [isOverridden](./kibana-plugin-server.userprovidedvalues.isoverridden.md)
+
+## UserProvidedValues.isOverridden property
+
+Signature:
+
+```typescript
+isOverridden?: boolean;
+```
diff --git a/docs/development/core/server/kibana-plugin-server.userprovidedvalues.md b/docs/development/core/server/kibana-plugin-server.userprovidedvalues.md
new file mode 100644
index 0000000000000..7b2114404d7f2
--- /dev/null
+++ b/docs/development/core/server/kibana-plugin-server.userprovidedvalues.md
@@ -0,0 +1,21 @@
+
+
+[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [UserProvidedValues](./kibana-plugin-server.userprovidedvalues.md)
+
+## UserProvidedValues interface
+
+Describes the values explicitly set by user.
+
+Signature:
+
+```typescript
+export interface UserProvidedValues
+```
+
+## Properties
+
+| Property | Type | Description |
+| --- | --- | --- |
+| [isOverridden](./kibana-plugin-server.userprovidedvalues.isoverridden.md) | boolean
| |
+| [userValue](./kibana-plugin-server.userprovidedvalues.uservalue.md) | T
| |
+
diff --git a/docs/development/core/server/kibana-plugin-server.userprovidedvalues.uservalue.md b/docs/development/core/server/kibana-plugin-server.userprovidedvalues.uservalue.md
new file mode 100644
index 0000000000000..59d25651b7697
--- /dev/null
+++ b/docs/development/core/server/kibana-plugin-server.userprovidedvalues.uservalue.md
@@ -0,0 +1,11 @@
+
+
+[Home](./index.md) > [kibana-plugin-server](./kibana-plugin-server.md) > [UserProvidedValues](./kibana-plugin-server.userprovidedvalues.md) > [userValue](./kibana-plugin-server.userprovidedvalues.uservalue.md)
+
+## UserProvidedValues.userValue property
+
+Signature:
+
+```typescript
+userValue?: T;
+```
diff --git a/docs/getting-started/tutorial-full-experience.asciidoc b/docs/getting-started/tutorial-full-experience.asciidoc
index 08f65b0a24091..eafbb7d8f7c91 100644
--- a/docs/getting-started/tutorial-full-experience.asciidoc
+++ b/docs/getting-started/tutorial-full-experience.asciidoc
@@ -183,7 +183,7 @@ At this point, you're ready to use the Elasticsearch {ref}/docs-bulk.html[bulk]
API to load the data sets:
[source,shell]
-curl -u elastic -H 'Content-Type: application/x-ndjson' -XPOST ':/bank/account/_bulk?pretty' --data-binary @accounts.json
+curl -u elastic -H 'Content-Type: application/x-ndjson' -XPOST ':/bank/_bulk?pretty' --data-binary @accounts.json
curl -u elastic -H 'Content-Type: application/x-ndjson' -XPOST ':/shakespeare/_bulk?pretty' --data-binary @shakespeare.json
curl -u elastic -H 'Content-Type: application/x-ndjson' -XPOST ':/_bulk?pretty' --data-binary @logs.jsonl
diff --git a/docs/images/code-blame.png b/docs/images/code-blame.png
deleted file mode 100644
index c04e1b12c58f5..0000000000000
Binary files a/docs/images/code-blame.png and /dev/null differ
diff --git a/docs/images/code-full-text-search.png b/docs/images/code-full-text-search.png
deleted file mode 100644
index 4d4d3d21a24f6..0000000000000
Binary files a/docs/images/code-full-text-search.png and /dev/null differ
diff --git a/docs/images/code-history.png b/docs/images/code-history.png
deleted file mode 100644
index 853fcc8fa6adc..0000000000000
Binary files a/docs/images/code-history.png and /dev/null differ
diff --git a/docs/images/code-import-repo.png b/docs/images/code-import-repo.png
deleted file mode 100644
index adc60614c1007..0000000000000
Binary files a/docs/images/code-import-repo.png and /dev/null differ
diff --git a/docs/images/code-lang-server-status.png b/docs/images/code-lang-server-status.png
deleted file mode 100644
index 3143a876f1c75..0000000000000
Binary files a/docs/images/code-lang-server-status.png and /dev/null differ
diff --git a/docs/images/code-lang-server-tab.png b/docs/images/code-lang-server-tab.png
deleted file mode 100644
index b25573f30d40b..0000000000000
Binary files a/docs/images/code-lang-server-tab.png and /dev/null differ
diff --git a/docs/images/code-quick-search.png b/docs/images/code-quick-search.png
deleted file mode 100644
index e6274b77dcbaa..0000000000000
Binary files a/docs/images/code-quick-search.png and /dev/null differ
diff --git a/docs/images/code-repo-management.png b/docs/images/code-repo-management.png
deleted file mode 100644
index 6e3fe5476b3be..0000000000000
Binary files a/docs/images/code-repo-management.png and /dev/null differ
diff --git a/docs/images/code-search-filter.png b/docs/images/code-search-filter.png
deleted file mode 100644
index f9b09ad2d71ec..0000000000000
Binary files a/docs/images/code-search-filter.png and /dev/null differ
diff --git a/docs/images/code-semantic-nav.png b/docs/images/code-semantic-nav.png
deleted file mode 100644
index 664225804ce22..0000000000000
Binary files a/docs/images/code-semantic-nav.png and /dev/null differ
diff --git a/docs/images/code-starter-root.png b/docs/images/code-starter-root.png
deleted file mode 100644
index a2e3a579fe2f2..0000000000000
Binary files a/docs/images/code-starter-root.png and /dev/null differ
diff --git a/docs/images/code-symbol-table.png b/docs/images/code-symbol-table.png
deleted file mode 100644
index d3bb4c6eef0c1..0000000000000
Binary files a/docs/images/code-symbol-table.png and /dev/null differ
diff --git a/docs/infrastructure/getting-started.asciidoc b/docs/infrastructure/getting-started.asciidoc
index 151a8e2928cf8..1c5645f5a6e4e 100644
--- a/docs/infrastructure/getting-started.asciidoc
+++ b/docs/infrastructure/getting-started.asciidoc
@@ -5,7 +5,7 @@
To get started with the Metrics app in Kibana, you need to start collecting metrics data for your infrastructure.
Kibana provides step-by-step instructions to help you add metrics data.
-The {infra-guide}[Infrastructure Monitoring Guide] is a good source for more detailed information and instructions.
+The {metrics-guide}[Metrics Monitoring Guide] is a good source for more detailed information and instructions.
[role="screenshot"]
image::infrastructure/images/metrics-add-data.png[Screenshot showing Add metric data to Kibana UI]
diff --git a/docs/logs/getting-started.asciidoc b/docs/logs/getting-started.asciidoc
index 1ed8798a4b87f..ca09bb34c0e56 100644
--- a/docs/logs/getting-started.asciidoc
+++ b/docs/logs/getting-started.asciidoc
@@ -5,7 +5,7 @@
To get started with the Logs app in Kibana, you need to start collecting logs data for your infrastructure.
Kibana provides step-by-step instructions to help you add logs data.
-The {infra-guide}[Infrastructure Monitoring Guide] is a good source for more detailed information and instructions.
+The {logs-guide}[Logs Monitoring Guide] is a good source for more detailed information and instructions.
[role="screenshot"]
image::logs/images/logs-add-data.png[Screenshot showing Add logging data in Kibana]
diff --git a/docs/management/snapshot-restore/images/create-policy-example.png b/docs/management/snapshot-restore/images/create-policy-example.png
new file mode 100755
index 0000000000000..e871c925f5fd5
Binary files /dev/null and b/docs/management/snapshot-restore/images/create-policy-example.png differ
diff --git a/docs/management/snapshot-restore/images/snapshot-retention.png b/docs/management/snapshot-restore/images/snapshot-retention.png
new file mode 100755
index 0000000000000..7b390357a21b6
Binary files /dev/null and b/docs/management/snapshot-restore/images/snapshot-retention.png differ
diff --git a/docs/management/snapshot-restore/index.asciidoc b/docs/management/snapshot-restore/index.asciidoc
index f309b2c17e0ed..f19aaa122675e 100644
--- a/docs/management/snapshot-restore/index.asciidoc
+++ b/docs/management/snapshot-restore/index.asciidoc
@@ -11,11 +11,11 @@ you can restore a snapshot from the repository.
You’ll find *Snapshot and Restore* under *Management > Elasticsearch*.
With this UI, you can:
-* <>
-* <>
-* <>
-* <>
-* <>
+* Register a repository for storing your snapshots
+* View a list of your snapshots and drill down into details
+* Restore data into your cluster from a snapshot
+* Create a policy to automate snapshot creation and deletion
+* Delete a snapshot to free storage space
[role="screenshot"]
image:management/snapshot-restore/images/snapshot_list.png["Snapshot list"]
@@ -27,28 +27,34 @@ more detailed information.
[float]
[[kib-snapshot-register-repository]]
=== Register a repository
+A repository is where your snapshots live. You must register a snapshot
+repository before you can perform snapshot and restore operations.
+
+If you don't have a repository, Kibana walks you through the process of
+registering one.
+{kib} supports three repository types
+out of the box: shared file system, read-only URL, and source-only.
+For more information on these repositories and their settings,
+see {ref}/modules-snapshots.html#snapshots-repositories[Repositories].
+To use other repositories, such as S3, see
+{ref}/modules-snapshots.html#_repository_plugins[Repository plugins].
-The *Repositories* view provides an overview of your repositories.
-Click a repository name to view its type, number of snapshots, and settings, and also to verify status.
+
+Once you create a repository, it is listed in the *Repositories*
+view.
+Click a repository name to view its type, number of snapshots, and settings,
+and to verify status.
[role="screenshot"]
image:management/snapshot-restore/images/repository_list.png["Repository list"]
-If you don't have a repository, you're prompted to register one.
-{es} supports three repository types
-out of the box: shared file system, read-only URL, and source-only.
-For more information on these repositories and their settings,
-see {ref}/modules-snapshots.html#snapshots-repositories[Repositories]. For an example,
-see <>.
-
-To use other repositories, such as S3, you can install plugins. See
-{ref}/modules-snapshots.html#_repository_plugins[Repository plugins].
[float]
[[kib-view-snapshot]]
=== View your snapshots
-The *Snapshots* view gives an overview of your snapshots. You can drill down
+A snapshot is a backup taken from a running {es} cluster. You'll find an overview of
+your snapshots in the *Snapshots* view, and you can drill down
into each snapshot for further investigation.
[role="screenshot"]
@@ -68,18 +74,25 @@ the new data.
[[kib-restore-snapshot]]
=== Restore a snapshot
-The *Restore* wizard walks you through the process of restoring a snapshot
-into a running cluster. To get started, go to the *Snapshots* view, find the
-snapshot, and click the restore icon in the *Actions* column.
+The information stored in a snapshot is not tied to a specific
+cluster or a cluster name. This enables you to
+restore a snapshot made from one cluster to another cluster. You might
+use the restore operation to:
-You’re presented
-options for the restore, including which
+* Recover data lost due to a failure
+* Migrate a current Elasticsearch cluster to a new version
+* Move data from one cluster to another cluster
+
+To get started, go to the *Snapshots* view, find the
+snapshot, and click the restore icon in the *Actions* column.
+The Restore wizard presents
+options for the restore operation, including which
indices to restore and whether to modify the index settings.
You can restore an existing index only if it’s closed and has the same
number of shards as the index in the snapshot.
Once you initiate the restore, you're navigated to the *Restore Status* view,
-where you can track the progress.
+where you can track the current state for each shard in the snapshot.
[role="screenshot"]
image:management/snapshot-restore/images/snapshot-restore.png["Snapshot details"]
@@ -89,23 +102,28 @@ image:management/snapshot-restore/images/snapshot-restore.png["Snapshot details"
[[kib-snapshot-policy]]
=== Create a snapshot lifecycle policy
-You can create policies to schedule automatic snapshots of your cluster.
-{ref}/snapshot-lifecycle-management-api.html[Snapshot lifecycle policies] are related
-to {ref}/index-lifecycle-management.html[index lifecycle policies].
-However, where an index lifecycle policy applies to a single index,
-a snapshot lifecycle policy can span multiple indices.
-
-For an overview of your policies, open the *Policies* view.
-You can drill down into each policy to examine its settings and last successful and failed run.
-
-If you don’t have any policies, use the *Create policy* wizard.
-You’ll define the snapshots and repository, when to take snapshots, and
-the settings, such as which indices the snapshot should contain.
+Use a {ref}/snapshot-lifecycle-management-api.html[snapshot lifecycle policy]
+to automate the creation and deletion
+of cluster snapshots. Taking automatic snapshots:
+
+* Ensures your {es} indices and clusters are backed up on a regular basis
+* Ensures a recent and relevant snapshot is available if a situation
+arises where a cluster needs to be recovered
+* Allows you to manage your snapshots in {kib}, instead of using a
+third-party tool
+
+If you don’t have any snapshot policies, follow the
+*Create policy* wizard. It walks you through defining
+when and where to take snapshots, the settings you want,
+and how long to retain snapshots.
[role="screenshot"]
-image:management/snapshot-restore/images/create-policy.png["Snapshot details"]
+image:management/snapshot-restore/images/snapshot-retention.png["Snapshot details"]
+
+An overview of your policies is on the *Policies* view.
+You can drill down into each policy to examine its settings and last successful and failed run.
-You can perform the following actions on a policy:
+You can perform the following actions on a snapshot policy:
* *Run* a policy immediately without waiting for the scheduled time.
This action is useful before an upgrade or before performing maintenance on indices.
@@ -113,6 +131,9 @@ This action is useful before an upgrade or before performing maintenance on indi
* *Delete* a policy to prevent any future snapshots from being taken.
This action does not cancel any currently ongoing snapshots or remove any previously taken snapshots.
+[role="screenshot"]
+image:management/snapshot-restore/images/create-policy.png["Snapshot details"]
+
[float]
[[kib-delete-snapshot]]
=== Delete a snapshot
@@ -123,16 +144,25 @@ Find the snapshot in the *Snapshots* view and click the trash icon in the
and then click *Delete snapshots*.
[[snapshot-repositories-example]]
-[float]
-=== Example: Register a shared file system repository
-This example shows how to register a shared file system repository
-and store snapshots.
+[role="xpack"]
+[[snapshot-restore-tutorial]]
+=== Tutorial: Snapshot and Restore
-[float]
-==== Register the repository location
-You must register the location of the repository in the `path.repo` setting on
+Ready to try *Snapshot and Restore*? In this tutorial, you'll learn to:
+
+* Register a repository
+* Add snapshots to the repository
+* Create a snapshot lifecycle policy
+* Restore a snapshot
+
+==== Before you begin
+
+This example shows you how to register a shared file system repository
+and store snapshots.
+Before you begin, you must register the location of the repository in the
+{ref}/modules-snapshots.html#_shared_file_system_repository[path.repo] setting on
your master and data nodes. You can do this in one of two ways:
* Edit your `elasticsearch.yml` to include the `path.repo` setting.
@@ -142,30 +172,26 @@ your master and data nodes. You can do this in one of two ways:
`bin/elasticsearch -E path.repo=/tmp/es-backups`
[float]
-==== Register the repository
+[[register-repo-example]]
+==== Register a repository
Use *Snapshot and Restore* to register the repository where your snapshots
will live.
. Go to *Management > Elasticsearch > Snapshot and Restore*.
-. Open the *Repositories* view.
-. Click *Register a repository*.
+. Click *Register a repository* in either the introductory message or *Repository view*.
. Enter a name for your repository, for example, `my_backup`.
-. Set *Repository type* to Shared file system.
+. Select *Shared file system*.
+
[role="screenshot"]
image:management/snapshot-restore/images/register_repo.png["Register repository"]
. Click *Next*.
-. In *Location*, enter the path to the snapshot repository, `/tmp/es-backups`.
-. In *Chunk size*, enter 100mb so that snapshot files are not bigger than that size.
-. Use the defaults for all other fields.
-. Click *Register*.
+. In *File system location*, enter the path to the snapshot repository, `/tmp/es-backups`.
+. In *Chunk size*, enter `100mb` so that snapshot files are not bigger than that size.
+. Use the defaults for all other fields, and then click *Register*.
+
Your new repository is listed on the *Repositories* view.
-+
-. Click the respository and inspect its details.
-+
The repository currently doesn’t have any snapshots.
@@ -174,19 +200,105 @@ The repository currently doesn’t have any snapshots.
Use the {ref}//modules-snapshots.html#snapshots-take-snapshot[snapshot API] to create a snapshot.
. Go to *Dev Tools > Console*.
-. Create the snapshot.
+. Create the snapshot:
++
+[source,js]
+PUT /_snapshot/my_backup/2019-04-25_snapshot?wait_for_completion=true
+
In this example, the snapshot name is `2019-04-25_snapshot`. You can also
use {ref}//date-math-index-names.html[date math expression] for the snapshot name.
+
[role="screenshot"]
image:management/snapshot-restore/images/create_snapshot.png["Create snapshot"]
-+
-. Open *Snapshot and Restore*.
+
+. Return to *Snapshot and Restore*.
+
Your new snapshot is available in the *Snapshots* view.
+[[create-policy-example]]
+==== Create a snapshot lifecycle policy
+
+Now you'll automate the creation and deletion of snapshots
+using the repository created in the previous example.
+
+. Open the *Policies* view.
+. Click *Create a policy*.
++
+[role="screenshot"]
+image:management/snapshot-restore/images/create-policy-example.png["Create policy wizard"]
+
+. As you walk through the wizard, enter the following values:
++
+|===
+|*Logistics* |
+
+|Policy name
+|`daily-snapshots`
+
+|Snapshot name
+|``
+
+|Schedule
+|Every day at 1:30 a.m.
+
+|Repository
+|`my_backup`
+
+|*Snapshot settings* |
+|Indices
+|Select the indices to back up. By default, all indices, including system indices, are backed up.
+|All other settings
+|Use the defaults.
+|*Snapshot retention* |
+
+|Expiration
+|`30 days`
+
+|Snapshots to retain
+|Minimum count: `5`, Maximum count: `50`
+|===
+
+. Review your input, and then click *Create policy*.
++
+Your new policy is listed in the *Policies* view, and you see a summary of its details.
+
+[[restore-snapshot-example]]
+==== Restore a snapshot
+Finally, you'll restore indices from an existing snapshot.
+
+. In the *Snapshots* view, find the snapshot you want to restore, for example `2019-04-25_snapshot`.
+. Click the restore icon in the *Actions* column.
+. As you walk through the wizard, enter the following values:
++
+|===
+|*Logistics* |
+
+|Indices
+|Toggle to choose specific indices to restore, or leave in place to restore all indices.
+
+|Rename indices
+|Toggle to give your restored indices new names, or leave in place to restore under original index names.
+
+|All other fields
+|Use the defaults.
+
+|*Index settings* |
+
+|Modify index settings
+|Toggle to overwrite index settings when they are restored,
+or leave in place to keep existing settings.
+
+|Reset index settings
+|Toggle to reset index settings back to the default when they are restored,
+or leave in place to keep existing settings.
+|===
+
+. Review your restore settings, and then click *Restore snapshot*.
++
+The operation loads for a few seconds,
+and then you’re navigated to *Restore Status*,
+where you can monitor the status of your restored indices.
diff --git a/docs/maps/heatmap-layer.asciidoc b/docs/maps/heatmap-layer.asciidoc
index 9d456c59b69ef..77b6d929a931c 100644
--- a/docs/maps/heatmap-layer.asciidoc
+++ b/docs/maps/heatmap-layer.asciidoc
@@ -13,6 +13,6 @@ You can create a heat map layer from the following data source:
Set *Show as* to *heat map*.
The index must contain at least one field mapped as {ref}/geo-point.html[geo_point].
-NOTE: Only count and sum metric aggregations are available with the grid aggregation source and heat map layers.
-Mean, median, min, and max are turned off because the heat map will blend nearby values.
+NOTE: Only count, sum, unique count metric aggregations are available with the grid aggregation source and heat map layers.
+Average, min, and max are turned off because the heat map will blend nearby values.
Blending two average values would make the cluster more prominent, even though it just might literally mean that these nearby areas are average.
diff --git a/docs/settings/code-settings.asciidoc b/docs/settings/code-settings.asciidoc
deleted file mode 100644
index 5dbcb9b3508b8..0000000000000
--- a/docs/settings/code-settings.asciidoc
+++ /dev/null
@@ -1,51 +0,0 @@
-[role="xpack"]
-[[code-settings-kibana]]
-=== Code Settings in Kibana
-++++
-Code settings
-++++
-
-Unless you are running multiple Kibana instances as a cluster, you do not need to change any settings to use *Code* by default. If you’d like to change any of the default values, copy and paste the relevant settings below into your `kibana.yml` configuration file.
-
-
-`xpack.code.updateRepoFrequencyMs`::
-Repo update frequency in milliseconds. Defaults to `300000`.
-
-`xpack.code.indexRepoFrequencyMs`::
-Repo index frequency in milliseconds. Defaults to `86400000`.
-
-`xpack.code.lsp.verbose`::
-Whether to show more verbose log for language servers. Defaults to `false`.
-
-`xpack.code.security.enableMavenImport`::
-Whether to support maven. Defaults to `true`.
-
-`xpack.code.security.enableGradleImport`::
-Whether to support gradle. Defaults to `false`.
-
-`xpack.code.security.installNodeDependency`::
-Whether to enable node dependency download. Defaults to `true`.
-
-`xpack.code.security.gitHostWhitelist`::
-Whitelist of hostnames for git clone address. Defaults to `[ 'github.com', 'gitlab.com', 'bitbucket.org', 'gitbox.apache.org', 'eclipse.org',]`.
-
-`xpack.code.security.gitProtocolWhitelist`::
-Whitelist of protocols for git clone address. Defaults to `[ 'https', 'git', 'ssh' ]`.
-
-`xpack.code.security.enableGitCertCheck`::
-Whether enable HTTPS certificate check when clone from HTTPS URL.
-
-`xpack.code.security.enableJavaSecurityManager`::
-Whether enable Java security manager for Java langserver. Defaults to `true`.
-
-`xpack.code.security.extraJavaRepositoryWhitelist`::
-Whitelist of extra repository to download dependencies for Java language. Defaults to `[]`.
-
-`xpack.code.maxWorkspace`::
-Maximal number of workspaces each language server allows to span. Defaults to `5`.
-
-`xpack.code.codeNodeUrl`::
-URL of the Code node. This config is only needed when multiple Kibana instances are set up as a cluster. Defaults to ``
-
-`xpack.code.verbose`::
-Set this config to `true` to log all events. Defaults to `false`
diff --git a/docs/setup/settings.asciidoc b/docs/setup/settings.asciidoc
index f02cf188d31ad..6e7f939a1d2ab 100644
--- a/docs/setup/settings.asciidoc
+++ b/docs/setup/settings.asciidoc
@@ -277,8 +277,8 @@ setting specifies the port to use.
`server.rewriteBasePath:`:: *Default: deprecated* Specifies whether Kibana should
rewrite requests that are prefixed with `server.basePath` or require that they
-are rewritten by your reverse proxy. In Kibana 6.3 and earlier, the default is
-`false`. In Kibana 7.x, the setting is deprecated. In Kibana 8.0 and later, the
+are rewritten by your reverse proxy. In Kibana 6.3 and earlier, the default is
+`false`. In Kibana 7.x, the setting is deprecated. In Kibana 8.0 and later, the
default is `true`.
`server.socketTimeout:`:: *Default: "120000"* The number of milliseconds to wait before closing an
@@ -327,7 +327,6 @@ Rollup user interface.
include::{docdir}/settings/apm-settings.asciidoc[]
-include::{docdir}/settings/code-settings.asciidoc[]
include::{docdir}/settings/dev-settings.asciidoc[]
include::{docdir}/settings/graph-settings.asciidoc[]
include::{docdir}/settings/infrastructure-ui-settings.asciidoc[]
diff --git a/docs/user/index.asciidoc b/docs/user/index.asciidoc
index 54817a6e8743d..4b29255c50a1d 100644
--- a/docs/user/index.asciidoc
+++ b/docs/user/index.asciidoc
@@ -20,8 +20,6 @@ include::extend.asciidoc[]
include::{kib-repo-dir}/maps/index.asciidoc[]
-include::{kib-repo-dir}/code/index.asciidoc[]
-
include::{kib-repo-dir}/infrastructure/index.asciidoc[]
include::{kib-repo-dir}/logs/index.asciidoc[]
diff --git a/docs/user/ml/index.asciidoc b/docs/user/ml/index.asciidoc
index f4802592f0e07..a5f14ed2cf944 100644
--- a/docs/user/ml/index.asciidoc
+++ b/docs/user/ml/index.asciidoc
@@ -18,7 +18,16 @@ image::user/ml/images/ml-data-visualizer-sample.jpg[Data Visualizer for sample f
experimental[] You can also upload a CSV, NDJSON, or log file (up to 100 MB in
size). The *Data Visualizer* identifies the file format and field mappings. You
-can then optionally import that data into an {es} index.
+can then optionally import that data into an {es} index.
+
+You need the following permissions to use the Data Visualizer with file upload:
+
+* cluster privileges: `monitor`, `manage_index_pipelines`
+* index privileges: `read`, `manage`, `index`
+
+For more information, see {ref}/security-privileges.html[Security privileges]
+and {ref}/built-in-roles.html[Built-in roles].
+
[float]
[[xpack-ml-anomalies]]
diff --git a/docs/user/security/api-keys/images/api-key-invalidate.png b/docs/user/security/api-keys/images/api-key-invalidate.png
new file mode 100755
index 0000000000000..c925679ab24bc
Binary files /dev/null and b/docs/user/security/api-keys/images/api-key-invalidate.png differ
diff --git a/docs/user/security/api-keys/images/api-keys.png b/docs/user/security/api-keys/images/api-keys.png
new file mode 100755
index 0000000000000..df74f245676d9
Binary files /dev/null and b/docs/user/security/api-keys/images/api-keys.png differ
diff --git a/docs/user/security/api-keys/index.asciidoc b/docs/user/security/api-keys/index.asciidoc
new file mode 100644
index 0000000000000..c00f58cf598e3
--- /dev/null
+++ b/docs/user/security/api-keys/index.asciidoc
@@ -0,0 +1,86 @@
+[role="xpack"]
+[[api-keys]]
+=== API Keys
+
+
+API keys enable you to create secondary credentials so that you can send
+requests on behalf of the user. Secondary credentials have
+the same or lower access rights.
+
+For example, if you extract data from an {es} cluster on a daily
+basis, you might create an API key tied to your credentials,
+configure it with minimum access,
+and then put the API credentials into a cron job.
+Or, you might create API keys to automate ingestion of new data from
+remote sources, without a live user interaction.
+
+You can create API keys from the {kib} Console. To view and invalidate
+API keys, use *Management > Security > API Keys*.
+
+[role="screenshot"]
+image:user/security/api-keys/images/api-keys.png["API Keys UI"]
+
+[float]
+[[api-keys-service]]
+=== {es} API key service
+
+The {es} API key service is automatically enabled when you configure
+{ref}/configuring-tls.html#tls-http[TLS on the HTTP interface].
+This ensures that clients are unable to send API keys in clear-text.
+
+When HTTPS connections are not enabled between {kib} and {es},
+you cannot create or manage API keys, and you get an error message.
+For more information, see the
+{ref}/security-api-create-api-key.html[{es} API key documentation],
+or contact your system administrator.
+
+[float]
+[[api-keys-security-privileges]]
+=== Security privileges
+
+You must have the `manage_security`, `manage_api_key`, or the `manage_own_api_key`
+cluster privileges to use API keys in {kib}. You can manage roles in
+*Management > Security > Roles*, or use the <>.
+
+
+[float]
+[[create-api-key]]
+=== Create an API key
+You can {ref}/security-api-create-api-key.html[create an API key] from
+the Kibana Console. For example:
+
+[source,js]
+POST /_security/api_key
+{
+ "name": "my_api_key",
+ "expiration": "1d"
+}
+
+This creates an API key with the name `my_api_key` that
+expires after one day. API key names must be globally unique.
+An expiration date is optional and follows {ref}/common-options.html#time-units[{es} time unit format].
+When an expiration is not provided, the API key does not expire.
+
+[float]
+[[view-api-keys]]
+=== View and invalidate API keys
+The *API Keys* UI lists your API keys, including the name, date created,
+and expiration date. If an API key expires, its status changes from `Active` to `Expired`.
+
+If you have `manage_security` or `manage_api_key` permissions,
+you can view the API keys of all users, and see which API key was
+created by which user in which realm.
+If you have only the `manage_own_api_key` permission, you see only a list of your own keys.
+
+You can invalidate API keys individually or in bulk.
+Invalidated keys are deleted in batch after seven days.
+
+[role="screenshot"]
+image:user/security/api-keys/images/api-key-invalidate.png["API Keys invalidate"]
+
+You cannot modify an API key. If you need additional privileges,
+you must create a new key with the desired configuration and invalidate the old key.
+
+
+
+
diff --git a/docs/user/security/index.asciidoc b/docs/user/security/index.asciidoc
index 7b7e38d610843..f57d1bcd3bc2a 100644
--- a/docs/user/security/index.asciidoc
+++ b/docs/user/security/index.asciidoc
@@ -36,3 +36,5 @@ cause Kibana's authorization to behave unexpectedly.
include::authorization/index.asciidoc[]
include::authorization/kibana-privileges.asciidoc[]
+include::api-keys/index.asciidoc[]
+
diff --git a/package.json b/package.json
index 101cee27aa28f..01067ab02cb55 100644
--- a/package.json
+++ b/package.json
@@ -85,7 +85,6 @@
"**/typescript": "3.5.3",
"**/graphql-toolkit/lodash": "^4.17.13",
"**/isomorphic-git/**/base64-js": "^1.2.1",
- "**/babel-plugin-inline-react-svg/svgo/js-yaml": "^3.13.1",
"**/image-diff/gm/debug": "^2.6.9"
},
"workspaces": {
@@ -107,10 +106,10 @@
"dependencies": {
"@babel/core": "^7.5.5",
"@babel/register": "^7.5.5",
- "@elastic/charts": "^13.5.4",
+ "@elastic/charts": "^13.5.9",
"@elastic/datemath": "5.0.2",
"@elastic/ems-client": "1.0.5",
- "@elastic/eui": "14.5.0",
+ "@elastic/eui": "14.7.0",
"@elastic/filesaver": "1.1.2",
"@elastic/good": "8.1.1-kibana2",
"@elastic/numeral": "2.3.3",
@@ -156,11 +155,11 @@
"custom-event-polyfill": "^0.3.0",
"d3": "3.5.17",
"d3-cloud": "1.2.5",
- "del": "^4.1.1",
+ "del": "^5.1.0",
"elasticsearch": "^16.4.0",
"elasticsearch-browser": "^16.4.0",
"encode-uri-query": "1.0.1",
- "execa": "^1.0.0",
+ "execa": "^3.2.0",
"expiry-js": "0.1.7",
"file-loader": "4.2.0",
"font-awesome": "4.7.0",
@@ -199,8 +198,8 @@
"markdown-it": "^8.4.1",
"mini-css-extract-plugin": "0.8.0",
"minimatch": "^3.0.4",
- "moment": "^2.20.1",
- "moment-timezone": "^0.5.14",
+ "moment": "^2.24.0",
+ "moment-timezone": "^0.5.27",
"mustache": "2.3.2",
"ngreact": "0.5.1",
"node-fetch": "1.7.3",
@@ -233,12 +232,10 @@
"request": "^2.88.0",
"reselect": "^3.0.1",
"resize-observer-polyfill": "^1.5.0",
- "rimraf": "2.7.1",
"rison-node": "1.0.2",
"rxjs": "^6.2.1",
"script-loader": "0.7.2",
"semver": "^5.5.0",
- "stream-stream": "^1.2.6",
"style-it": "^2.1.3",
"style-loader": "0.23.1",
"symbol-observable": "^1.2.0",
@@ -248,8 +245,6 @@
"tinygradient": "0.4.3",
"tinymath": "1.2.1",
"topojson-client": "3.0.0",
- "trunc-html": "1.1.2",
- "trunc-text": "1.0.2",
"tslib": "^1.9.3",
"type-detect": "^4.0.8",
"ui-select": "0.19.8",
@@ -303,7 +298,6 @@
"@types/elasticsearch": "^5.0.33",
"@types/enzyme": "^3.9.0",
"@types/eslint": "^6.1.2",
- "@types/execa": "^0.9.0",
"@types/fetch-mock": "^7.3.1",
"@types/getopts": "^2.0.1",
"@types/glob": "^7.1.1",
@@ -314,7 +308,6 @@
"@types/has-ansi": "^3.0.0",
"@types/history": "^4.7.3",
"@types/hoek": "^4.1.3",
- "@types/humps": "^1.1.2",
"@types/jest": "^24.0.18",
"@types/joi": "^13.4.2",
"@types/jquery": "^3.3.31",
@@ -327,7 +320,7 @@
"@types/markdown-it": "^0.0.7",
"@types/minimatch": "^2.0.29",
"@types/mocha": "^5.2.7",
- "@types/moment-timezone": "^0.5.8",
+ "@types/moment-timezone": "^0.5.12",
"@types/mustache": "^0.8.31",
"@types/node": "^10.12.27",
"@types/opn": "^5.1.0",
@@ -342,13 +335,13 @@
"@types/redux": "^3.6.31",
"@types/redux-actions": "^2.2.1",
"@types/request": "^2.48.2",
- "@types/rimraf": "^2.0.2",
"@types/selenium-webdriver": "^4.0.3",
"@types/semver": "^5.5.0",
"@types/sinon": "^7.0.13",
"@types/strip-ansi": "^3.0.0",
"@types/styled-components": "^3.0.2",
"@types/supertest": "^2.0.5",
+ "@types/supertest-as-promised": "^2.0.38",
"@types/type-detect": "^4.0.1",
"@types/uuid": "^3.4.4",
"@types/vinyl-fs": "^2.4.11",
diff --git a/packages/elastic-datemath/package.json b/packages/elastic-datemath/package.json
index 53c8459821147..57873d28d372d 100644
--- a/packages/elastic-datemath/package.json
+++ b/packages/elastic-datemath/package.json
@@ -14,12 +14,12 @@
"@babel/cli": "^7.5.5",
"@babel/preset-env": "^7.5.5",
"babel-plugin-add-module-exports": "^1.0.2",
- "moment": "^2.13.0"
+ "moment": "^2.24.0"
},
"dependencies": {
"tslib": "^1.9.3"
},
"peerDependencies": {
- "moment": "^2.13.0"
+ "moment": "^2.24.0"
}
}
diff --git a/packages/kbn-config-schema/package.json b/packages/kbn-config-schema/package.json
index cd5ae010f998b..4880fb4ebfdee 100644
--- a/packages/kbn-config-schema/package.json
+++ b/packages/kbn-config-schema/package.json
@@ -14,7 +14,7 @@
},
"peerDependencies": {
"joi": "^13.5.2",
- "moment": "^2.20.1",
+ "moment": "^2.24.0",
"type-detect": "^4.0.8"
}
}
diff --git a/packages/kbn-config-schema/src/errors/validation_error.ts b/packages/kbn-config-schema/src/errors/validation_error.ts
index 39aac67c208f5..d688d022da85c 100644
--- a/packages/kbn-config-schema/src/errors/validation_error.ts
+++ b/packages/kbn-config-schema/src/errors/validation_error.ts
@@ -20,17 +20,18 @@
import { SchemaError, SchemaTypeError, SchemaTypesError } from '.';
export class ValidationError extends SchemaError {
- public static extractMessage(error: SchemaTypeError, namespace?: string) {
+ private static extractMessage(error: SchemaTypeError, namespace?: string, level?: number) {
const path = typeof namespace === 'string' ? [namespace, ...error.path] : error.path;
let message = error.message;
if (error instanceof SchemaTypesError) {
+ const indentLevel = level || 0;
const childErrorMessages = error.errors.map(childError =>
- ValidationError.extractMessage(childError, namespace)
+ ValidationError.extractMessage(childError, namespace, indentLevel + 1)
);
message = `${message}\n${childErrorMessages
- .map(childErrorMessage => `- ${childErrorMessage}`)
+ .map(childErrorMessage => `${' '.repeat(indentLevel)}- ${childErrorMessage}`)
.join('\n')}`;
}
diff --git a/packages/kbn-config-schema/src/types/map_of_type.test.ts b/packages/kbn-config-schema/src/types/map_of_type.test.ts
index 1b72d39fcec26..6b9b700efdc3c 100644
--- a/packages/kbn-config-schema/src/types/map_of_type.test.ts
+++ b/packages/kbn-config-schema/src/types/map_of_type.test.ts
@@ -108,3 +108,23 @@ test('object within mapOf', () => {
expect(type.validate(value)).toEqual(expected);
});
+
+test('error preserves full path', () => {
+ const type = schema.object({
+ grandParentKey: schema.object({
+ parentKey: schema.mapOf(schema.string({ minLength: 2 }), schema.number()),
+ }),
+ });
+
+ expect(() =>
+ type.validate({ grandParentKey: { parentKey: { a: 'some-value' } } })
+ ).toThrowErrorMatchingInlineSnapshot(
+ `"[grandParentKey.parentKey.key(\\"a\\")]: value is [a] but it must have a minimum length of [2]."`
+ );
+
+ expect(() =>
+ type.validate({ grandParentKey: { parentKey: { ab: 'some-value' } } })
+ ).toThrowErrorMatchingInlineSnapshot(
+ `"[grandParentKey.parentKey.ab]: expected value of type [number] but got [string]"`
+ );
+});
diff --git a/packages/kbn-config-schema/src/types/map_type.ts b/packages/kbn-config-schema/src/types/map_type.ts
index 3acf14a69125e..c637eccb79571 100644
--- a/packages/kbn-config-schema/src/types/map_type.ts
+++ b/packages/kbn-config-schema/src/types/map_type.ts
@@ -50,7 +50,7 @@ export class MapOfType extends Type