Skip to content

Commit

Permalink
Merge branch 'master' of github.com:elastic/kibana into dev/state-man…
Browse files Browse the repository at this point in the history
…agement-docs
  • Loading branch information
Dosant committed May 28, 2020
2 parents e962368 + 57345e0 commit c0cbd0e
Show file tree
Hide file tree
Showing 509 changed files with 12,385 additions and 6,181 deletions.
57 changes: 13 additions & 44 deletions .ci/end2end.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,7 @@ pipeline {
environment {
BASE_DIR = 'src/github.com/elastic/kibana'
HOME = "${env.WORKSPACE}"
APM_ITS = 'apm-integration-testing'
CYPRESS_DIR = 'x-pack/plugins/apm/e2e'
E2E_DIR = 'x-pack/plugins/apm/e2e'
PIPELINE_LOG_LEVEL = 'DEBUG'
}
options {
Expand Down Expand Up @@ -43,32 +42,6 @@ pipeline {
env.APM_UPDATED = isGitRegionMatch(patterns: regexps)
}
}
dir("${APM_ITS}"){
git changelog: false,
credentialsId: 'f6c7695a-671e-4f4f-a331-acdce44ff9ba',
poll: false,
url: "git@github.com:elastic/${APM_ITS}.git"
}
}
}
stage('Start services') {
options { skipDefaultCheckout() }
when {
anyOf {
expression { return params.FORCE }
expression { return env.APM_UPDATED != "false" }
}
}
steps {
notifyStatus('Starting services', 'PENDING')
dir("${APM_ITS}"){
sh './scripts/compose.py start master --no-kibana'
}
}
post {
unsuccessful {
notifyStatus('Environmental issue', 'FAILURE')
}
}
}
stage('Prepare Kibana') {
Expand All @@ -85,7 +58,7 @@ pipeline {
steps {
notifyStatus('Preparing kibana', 'PENDING')
dir("${BASE_DIR}"){
sh script: "${CYPRESS_DIR}/ci/prepare-kibana.sh"
sh "${E2E_DIR}/ci/prepare-kibana.sh"
}
}
post {
Expand All @@ -105,24 +78,20 @@ pipeline {
steps{
notifyStatus('Running smoke tests', 'PENDING')
dir("${BASE_DIR}"){
sh '''
jobs -l
docker build --tag cypress --build-arg NODE_VERSION=$(cat .node-version) ${CYPRESS_DIR}/ci
docker run --rm -t --user "$(id -u):$(id -g)" \
-v `pwd`:/app --network="host" \
--name cypress cypress'''
sh "${E2E_DIR}/ci/run-e2e.sh"
}
}
post {
always {
dir("${BASE_DIR}"){
archiveArtifacts(allowEmptyArchive: false, artifacts: "${CYPRESS_DIR}/**/screenshots/**,${CYPRESS_DIR}/**/videos/**,${CYPRESS_DIR}/**/test-results/*e2e-tests.xml")
junit(allowEmptyResults: true, testResults: "${CYPRESS_DIR}/**/test-results/*e2e-tests.xml")
}
dir("${APM_ITS}"){
sh 'docker-compose logs > apm-its.log || true'
sh 'docker-compose down -v || true'
archiveArtifacts(allowEmptyArchive: false, artifacts: 'apm-its.log')
dir("${BASE_DIR}/${E2E_DIR}"){
archiveArtifacts(allowEmptyArchive: false, artifacts: 'cypress/screenshots/**,cypress/videos/**,cypress/test-results/*e2e-tests.xml')
junit(allowEmptyResults: true, testResults: 'cypress/test-results/*e2e-tests.xml')
dir('tmp/apm-integration-testing'){
sh 'docker-compose logs > apm-its-docker.log || true'
sh 'docker-compose down -v || true'
archiveArtifacts(allowEmptyArchive: true, artifacts: 'apm-its-docker.log')
}
archiveArtifacts(allowEmptyArchive: true, artifacts: 'tmp/*.log')
}
}
unsuccessful {
Expand All @@ -137,7 +106,7 @@ pipeline {
post {
always {
dir("${BASE_DIR}"){
archiveArtifacts(allowEmptyArchive: true, artifacts: "${CYPRESS_DIR}/ingest-data.log,kibana.log")
archiveArtifacts(allowEmptyArchive: true, artifacts: "${E2E_DIR}/kibana.log")
}
}
}
Expand Down
4 changes: 2 additions & 2 deletions .ci/es-snapshots/Jenkinsfile_verify_es
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ def SNAPSHOT_MANIFEST = "https://storage.googleapis.com/kibana-ci-es-snapshots-d
kibanaPipeline(timeoutMinutes: 150) {
catchErrors {
slackNotifications.onFailure(
title: ":broken_heart: *<${env.BUILD_URL}|[${SNAPSHOT_VERSION}] ES Snapshot Verification Failure>*",
message: ":broken_heart: [${SNAPSHOT_VERSION}] ES Snapshot Verification Failure",
title: "*<${env.BUILD_URL}|[${SNAPSHOT_VERSION}] ES Snapshot Verification Failure>*",
message: "[${SNAPSHOT_VERSION}] ES Snapshot Verification Failure",
) {
retryable.enable(2)
withEnv(["ES_SNAPSHOT_MANIFEST=${SNAPSHOT_MANIFEST}"]) {
Expand Down
1 change: 1 addition & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
/.es
/build
/built_assets
/config/apm.dev.js
/data
/html_docs
/optimize
Expand Down
1 change: 1 addition & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,7 @@
/config/kibana.yml @elastic/kibana-platform
/x-pack/plugins/features/ @elastic/kibana-platform
/x-pack/plugins/licensing/ @elastic/kibana-platform
/x-pack/plugins/cloud/ @elastic/kibana-platform
/packages/kbn-config-schema/ @elastic/kibana-platform
/src/legacy/server/config/ @elastic/kibana-platform
/src/legacy/server/http/ @elastic/kibana-platform
Expand Down
2 changes: 1 addition & 1 deletion config/kibana.yml
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@
# Specifies the path where Kibana creates the process ID file.
#pid.file: /var/run/kibana.pid

# Enables you specify a file where Kibana stores log output.
# Enables you to specify a file where Kibana stores log output.
#logging.dest: stdout

# Set the value of this setting to true to suppress all logging output.
Expand Down
2 changes: 1 addition & 1 deletion docs/api/saved-objects/bulk_get.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ experimental[] Retrieve multiple {kib} saved objects by ID.
==== Response body

`saved_objects`::
(array) Top-level property the contains objects that represent the response for each of the requested objects. The order of the objects in the response is identical to the order of the objects in the request.
(array) Top-level property containing objects that represent the response for each of the requested objects. The order of the objects in the response is identical to the order of the objects in the request.

Saved objects that are unable to persist are replaced with an error object.

Expand Down
22 changes: 12 additions & 10 deletions docs/apm/api.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,12 @@ Some APM app features are provided via a REST API:
* <<agent-config-api>>
* <<apm-annotation-api>>

[float]
[[apm-api-example]]
=== Using the APIs

Users interacting with APM APIs must have <<apm-app-api-user,sufficient privileges>>.
In addition, there are request headers to be aware of, like `kbn-xsrf: true`, and `Content-Type: applicaton/json`.
Here's an example CURL request that adds an annotation to the APM app:

[source,curl]
Expand All @@ -32,16 +38,8 @@ curl -X POST \
}'
----

For more information, the Kibana <<api,REST API reference>> provides information on how to use Kibana APIs,
like required request headers and authentication options.

// AGENT CONFIG API
// GET --> Feature (APM) Read
// CREATE/EDIT/DELETE --> Feature (APM) All

// ANNOTATION API
// Feature (APM) All
// Index: `observability-annotations`. Privileges: `create_index`, `create_doc`, `manage`, and `read`.
The Kibana <<api,REST API reference>> provides additional information on how to use Kibana APIs,
required request headers, and token-based authentication options.

////
*******************************************************
Expand All @@ -61,6 +59,8 @@ The following Agent configuration APIs are available:
* <<apm-list-config>> to list all Agent configurations.
* <<apm-search-config>> to search for an Agent configuration.

See <<apm-app-api-config-manager>> for information on the privileges required to use this API endpoint.

////
*******************************************************
////
Expand Down Expand Up @@ -327,6 +327,8 @@ The following APIs are available:
By default, annotations are stored in a newly created `observability-annotations` index.
The name of this index can be changed in your `config.yml` by editing `xpack.observability.annotations.index`.

See <<apm-app-api-annotation-manager>> for information on the privileges required to use this API endpoint.

////
*******************************************************
////
Expand Down
Loading

0 comments on commit c0cbd0e

Please sign in to comment.