Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[7.12] sampling: use a data stream for sampled trace docs (#4707) #4820

Merged
merged 1 commit into from
Feb 19, 2021

Conversation

axw
Copy link
Member

@axw axw commented Feb 19, 2021

Backports the following commits to 7.12:

* beater: add Managed and Namespace to ServerParams

This enables x-pack/apm-server code to alter behaviour
based on whether APM Server is managed or not, and to
create data streams with the configured namespace.

* sampling: use a data stream for sampled trace docs

Update tail-based sampling to index into and search a
data stream. The data stream will be associated with an
ILM policy that takes care of rollover and deletion.

When running in Fleet-managed mode, apm-server will expect
the data stream and ILM policy to exist for the data stream
called `traces-sampled-<namespace>`. Servers participating
in tail-based sampling are required to be configured with
the same namespace.

When running in standalone mode, apm-server will attempt
to create an index template and ILM policy for a data
stream called `apm-sampled-traces`. This is added for
minimal support while we transition things to Fleet, and
is intended to be removed in a future release. The data
stream is not intended to adhere to the standard indexing
strategy.

* apmpackage: add traces-sampled-* data stream

Add a data stream for sampled trace documents,
along with an ILM policy which rolls over after
1h, and then deletes after 1h.

* systemtest: fetch most recent beats monitoring doc

When searching for beats monitoring docs, make sure
we get the most recent one by sorting on 'timestamp'.

* systemtest: update tail-based sampling test

Update test to rely on apm-server to create its
own data stream index template.

* Cross-reference sampling/pubsub and apmpackage
# Conflicts:
#	changelogs/head.asciidoc
#	systemtest/elasticsearch.go
@axw axw added the backport label Feb 19, 2021
@axw axw enabled auto-merge (squash) February 19, 2021 03:08
@apmmachine
Copy link
Contributor

apmmachine commented Feb 19, 2021

💚 Build Succeeded

the below badges are clickable and redirect to their specific view in the CI or DOCS
Pipeline View Test View Changes Artifacts preview

Expand to view the summary

Build stats

  • Build Cause: axw commented: jenkins run the tests please

  • Start Time: 2021-02-19T03:52:00.598+0000

  • Duration: 32 min 48 sec

  • Commit: 3738a74

Test stats 🧪

Test Results
Failed 0
Passed 4373
Skipped 126
Total 4499

Trends 🧪

Image of Build Times

Image of Tests

Steps errors 3

Expand to view the steps failures

Compress
  • Took 0 min 0 sec . View more details on here
  • Description: tar --exclude=coverage-files.tgz -czf coverage-files.tgz coverage
Compress
  • Took 0 min 0 sec . View more details on here
  • Description: tar --exclude=system-tests-linux-files.tgz -czf system-tests-linux-files.tgz system-tests
Test Sync
  • Took 4 min 51 sec . View more details on here
  • Description: ./.ci/scripts/sync.sh

@axw
Copy link
Member Author

axw commented Feb 19, 2021

jenkins run the tests please

@axw axw merged commit 9f0a6c7 into elastic:7.12 Feb 19, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants