Skip to content

Commit cee861e

Browse files
bmorelli25graphaelli
authored andcommitted
docs: v2 6.5 additions and changes (#1530)
* docs: rework apm overview * docs: move events and add distributed tracing * docs: add v2 docs * Update example files for official docs. (#2) * docs: add redirects file * docs: add agent server compatibility
1 parent c3742d2 commit cee861e

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

53 files changed

+2399
-1594
lines changed

Makefile

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -46,16 +46,14 @@ go-generate:
4646

4747
.PHONY: create-docs
4848
create-docs:
49-
@mkdir -p docs/data/intake-api/generated/{error,transaction,metricset,sourcemap}
50-
@cp testdata/error/payload.json docs/data/intake-api/generated/error/
51-
@cp testdata/error/rum.json docs/data/intake-api/generated/error/
52-
@cp testdata/error/minimal_payload_exception.json docs/data/intake-api/generated/error/
53-
@cp testdata/error/minimal_payload_log.json docs/data/intake-api/generated/error/
54-
@cp testdata/metricset/payload.json docs/data/intake-api/generated/metricset/
55-
@cp testdata/transaction/payload.json docs/data/intake-api/generated/transaction/
56-
@cp testdata/transaction/minimal_payload.json docs/data/intake-api/generated/transaction/
57-
@cp testdata/transaction/minimal_span.json docs/data/intake-api/generated/transaction/
49+
@mkdir -p docs/data/intake-api/generated/sourcemap
50+
@cp testdata/intake-v2/events.ndjson docs/data/intake-api/generated/
5851
@cp testdata/sourcemap/bundle.js.map docs/data/intake-api/generated/sourcemap/
52+
@mkdir -p docs/data/elasticsearch/generated/
53+
@cp processor/stream/approved-es-documents/testV2IntakeIntegrationErrors.approved.json docs/data/elasticsearch/generated/errors.json
54+
@cp processor/stream/approved-es-documents/testV2IntakeIntegrationTransactions.approved.json docs/data/elasticsearch/generated/transactions.json
55+
@cp processor/stream/approved-es-documents/testV2IntakeIntegrationSpans.approved.json docs/data/elasticsearch/generated/spans.json
56+
@cp processor/stream/approved-es-documents/testV2IntakeIntegrationMetricsets.approved.json docs/data/elasticsearch/generated/metricsets.json
5957

6058
# Start manual testing environment with agents
6159
start-env:

docs/common-problems.asciidoc

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,8 @@ Particularly, if you are using Docker, ensure to bind to the right interface (fo
3636

3737

3838

39-
If you see requests coming trough the APM Server but they are not accepted (response code other than `202`), consider
40-
the response code to narrow down the possible causes (see sections bellow).
39+
If you see requests coming through the APM Server but they are not accepted (response code other than `202`), consider
40+
the response code to narrow down the possible causes (see sections below).
4141

4242
Another reason for data not showing up is that the agent is not auto-instrumenting something you were expecting, check
4343
the {apm-agents-ref}/index.html[agent documentation] for details on what is automatically instrumented.
@@ -46,7 +46,7 @@ the {apm-agents-ref}/index.html[agent documentation] for details on what is auto
4646
[float]
4747
=== HTTP 400: Data decoding error / Data validation error
4848

49-
The most likely cause for this is that you are using non compatible versions of agent and APM Server.
49+
The most likely cause for this is that you are using incompatible versions of agent and APM Server.
5050
For instance, APM Server 6.2.0 changed the Intake API spec and requires a minimum version of each agent.
5151

5252
[[unauthorized]]
@@ -103,7 +103,7 @@ You have a few options to solve this problem:
103103
=== HTTP 503: Request timed out waiting to be processed
104104

105105
This happens when APM Server exceeds the maximum number of requests that it can process concurrently.
106-
This limit is determined by the `apm-server.concurrent_requests` configuration parameter.
106+
This limit is determined by the `apm-server.concurrent_requests` configuration parameter deprecated[6.5].
107107

108108
To alleviate this problem,
109109
you can try to:
@@ -157,20 +157,20 @@ To resolve this problem, try one of these solutions:
157157
* Create a DNS entry for the hostname mapping it to the server's IP.
158158
* Create an entry in `/etc/hosts` for the hostname. Or on Windows add an entry to
159159
`C:\Windows\System32\drivers\etc\hosts`.
160-
* Re-create the server certificate and add a SubjectAltName (SAN) for the IP address of the server. This make the
160+
* Re-create the server certificate and add a SubjectAltName (SAN) for the IP address of the server. This makes the
161161
server's certificate valid for both the hostname and the IP address.
162162

163163
[float]
164164
[[getsockopt-no-route-to-host]]
165165
===== getsockopt: no route to host
166166

167-
This is not a SSL problem. It's a networking problem. Make sure the two hosts can communicate.
167+
This is not an SSL problem. It's a networking problem. Make sure the two hosts can communicate.
168168

169169
[float]
170170
[[getsockopt-connection-refused]]
171171
===== getsockopt: connection refused
172172

173-
This is not a SSL problem. Make sure that Logstash is running and that there is no firewall blocking the traffic.
173+
This is not an SSL problem. Make sure that Logstash is running and that there is no firewall blocking the traffic.
174174

175175
[float]
176176
[[target-machine-refused-connection]]

docs/configuration-process.asciidoc

Lines changed: 51 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,8 @@ max_procs: 4
1717
----
1818

1919
[float]
20-
=== Configuration options `apm-server.*`
20+
[[configuration-apm-server]]
21+
=== Configuration options: `apm-server.*`
2122

2223
[[host]]
2324
[float]
@@ -26,24 +27,12 @@ Defines the host and port the server is listening on.
2627
Use "unix:/path/to.sock" to listen on a unix domain socket.
2728
Defaults to 'localhost:8200'.
2829

29-
[[max_unzipped_size]]
30-
[float]
31-
==== `max_unzipped_size`
32-
Maximum permitted size of an unzipped request accepted by the server to be processed (in Bytes).
33-
Defaults to 31457280 Bytes (30 MB).
34-
3530
[[max_header_size]]
3631
[float]
3732
==== `max_header_size`
3833
Maximum permitted size of a request's header accepted by the server to be processed (in Bytes).
3934
Defaults to 1048576 Bytes (1 MB).
4035

41-
[[max_request_queue_time]]
42-
[float]
43-
==== `max_request_queue_time`
44-
Maximum duration a request will be queued before being read.
45-
Defaults to 2 seconds.
46-
4736
[[read_timeout]]
4837
[float]
4938
==== `read_timeout`
@@ -62,32 +51,64 @@ Defaults to 30 seconds.
6251
Maximum duration in seconds before releasing resources when shutting down the server.
6352
Defaults to 5 seconds.
6453

54+
[float]
55+
[[configuration-v1-api]]
56+
=== Configuration options: v1 Intake API deprecated[6.5]
57+
58+
Version 6.5 of the APM Server introduced a new intake API. You can learn more about this change in the <<intake-api-changes-65, intake API changes>> documentation.
59+
60+
If you do not upgrade your APM Agent, you'll continue to use the deprecated v1 intake API endpoint, and thus, the following configuration options.
61+
62+
[[max_unzipped_size]]
63+
[float]
64+
==== `max_unzipped_size` deprecated[6.5]
65+
Maximum permitted size of an unzipped request accepted by the server to be processed (in Bytes).
66+
Defaults to 31457280 Bytes (30 MB).
67+
68+
[[max_request_queue_time]]
69+
[float]
70+
==== `max_request_queue_time` deprecated[6.5]
71+
Maximum duration a request will be queued before being read.
72+
Defaults to 2 seconds.
73+
6574
[[concurrent_requests]]
6675
[float]
67-
==== `concurrent_request`
76+
==== `concurrent_request` deprecated[6.5]
6877
Maximum number of requests the server can process concurrently.
6978
Read more about how to tune data ingestion by <<adjust-concurrent-requests, adjusting concurrent_requests>>.
7079
Default value is 5.
7180

81+
[float]
82+
[[configuration-v2-api]]
83+
=== Configuration options: v2 Intake API
84+
85+
Version 6.5 of the APM Server introduced a new intake API. You can learn more about this change in the <<intake-api-changes-65, intake API changes>> documentation.
86+
87+
The following configuration options only affect users that have upgraded their agent to take advantage of the new v2 intake API.
88+
89+
[[max_event_size]]
90+
[float]
91+
==== `max_event_size`
92+
Maximum permitted size of an event accepted by the server to be processed (in Bytes).
93+
Defaults to 307200 Bytes.
94+
95+
[float]
96+
[[configuration-other]]
97+
=== Configuration options: general
98+
7299
[[max_connections]]
73100
[float]
74101
==== `max_connections`
75102
Maximum number of TCP connections to accept simultaneously.
76103
Default value is 0, which means _unlimited_.
77104

78-
[[instrumentation.enabled]]
79-
[float]
80-
==== `instrumentation.enabled`
81-
Enables self instrumentation of the APM Server itself.
82-
Disabled by default.
83-
84105
[[config-secret-token]]
85106
[float]
86107
==== `secret_token`
87108
Authorization token for sending data to the APM server.
88109
If a token is set, the agents must send it in the following format:
89110
Authorization: Bearer <secret-token>.
90-
The token is not used for RUM endpoints. By default no authorization token is set.
111+
The token is not used for RUM endpoints. By default, no authorization token is set.
91112

92113
It is recommended to use an authorization token in combination with SSL enabled.
93114
Read more about <<securing-apm-server, Securing APM Server>> and the <<secret-token, secret token>>.
@@ -111,6 +132,12 @@ Disabled by default.
111132
Configure the url to expose expvar.
112133
Defaults to `debug/vars`.
113134

135+
[[instrumentation.enabled]]
136+
[float]
137+
==== `instrumentation.enabled`
138+
Enables self instrumentation of the APM Server itself.
139+
Disabled by default.
140+
114141
[[metrics.enabled]]
115142
[float]
116143
==== `metrics`
@@ -129,9 +156,9 @@ Defaults to false.
129156
Overwrites existing pipeline definitions in Elasticsearch. Defaults to true.
130157

131158
[float]
132-
=== Configuration options `queue.mem.*`
159+
=== Configuration options: `queue.mem.*`
133160
Data is buffered in a memory queue before it is published to the configured output.
134-
`queue.mem.*` settings modify the queue behaviour.
161+
`queue.mem.*` settings modify the queue behavior.
135162

136163
[[mem.events]]
137164
[float]
@@ -155,7 +182,7 @@ if the number of events stored in the queue is < _min_flush_events_.
155182
Default value is 1 second.
156183

157184
[float]
158-
=== Configuration options `max_procs`
185+
=== Configuration options: `max_procs`
159186

160187
[[max_procs]]
161188
[float]

docs/configuration-rum.asciidoc

Lines changed: 51 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ apm-server.rum.source_mapping.index_pattern: "apm-*-sourcemap*"
1717
----
1818

1919
[float]
20-
=== Configuration options
20+
=== Configuration
2121

2222
[[rum-enable]]
2323
[float]
@@ -26,35 +26,74 @@ For enabling RUM support, set the `apm-server.rum.enabled` to `true`.
2626
By default this is disabled.
2727

2828
[float]
29-
==== `rate_limit`
29+
[[configuration-rum-v1]]
30+
=== Configuration options: v1 RUM endpoint deprecated[6.5]
31+
32+
Version 6.5 of the APM Server introduced a new intake API. You can learn more about this change in the <<intake-api-changes-65, intake API changes>> documentation.
33+
34+
If you do not upgrade your APM Agent, you'll continue to use the deprecated v1 RUM intake API endpoint, and thus, the following configuration options.
35+
36+
[float]
37+
==== `rate_limit` deprecated[6.5]
3038
Rate limit per second and IP address for requests sent to the RUM endpoint.
3139
If the rate limit is hit, the APM Server will return an HTTP status code `429`.
3240
The rate limit cannot be disabled. Ensure to have it set to a number suiting your requirements.
3341
Default value is set to 10.
3442

43+
[float]
44+
[[configuration-rum-v2]]
45+
=== Configuration options: v2 RUM endpoint
46+
47+
Version 6.5 of the APM Server introduced a new intake API. You can learn more about this change in the <<intake-api-changes-65, intake API changes>> documentation.
48+
49+
The following configuration options only affect users that have upgraded their agent to take advantage of the new v2 intake API.
50+
51+
[float]
52+
==== `event_rate.limit`
53+
Defines the maximum amount of events allowed to be sent to the APM Server v2 RUM endpoint per ip per second.
54+
Defaults to 300.
55+
56+
[float]
57+
==== `event_rate.lru_size`
58+
An LRU cache is used to keep a rate limit per IP for the most recently seen IPs.
59+
This setting defines the number of unique IPs that can be tracked in the cache.
60+
Sites with many concurrent clients should consider increasing this limit.
61+
Defaults to 1000.
62+
63+
[float]
64+
[[configuration-rum-general]]
65+
=== Configuration options: general
66+
3567
[float]
3668
==== `allow_origins`
37-
Comma separated list of permitted origins for RUM supprt.
69+
Comma separated list of permitted origins for RUM support.
3870
User-agents send an Origin header that will be validated against this list.
3971
This is done automatically by modern browsers as part of the https://www.w3.org/TR/cors/[CORS specification].
40-
An origin is made of a protocol scheme, host and port, without the url path.
72+
An origin is made of a protocol scheme, host and port, without the URL path.
4173
Default value is set to `['*']`, which allows everything.
4274

4375
[float]
4476
==== `library_pattern`
45-
Regexp to be matched against a stacktrace frame's `file_name` and `abs_path` attributes.
46-
If the regexp matches, the stacktrace frame is considered to be a library frame.
47-
When source mapping is applied the `error.culprit` is set to reflect the _function_ and the _filename_
48-
of the first not library frame.
77+
RegExp to be matched against a stacktrace frame's `file_name` and `abs_path` attributes.
78+
If the RegExp matches, the stacktrace frame is considered to be a library frame.
79+
When source mapping is applied, the `error.culprit` is set to reflect the _function_ and the _filename_
80+
of the first non library frame.
4981
This aims to provide an entry point for identifying issues.
5082
Default value is `"node_modules|bower_components|~"`.
5183

5284
[float]
5385
==== `exclude_from_grouping`
54-
Regexp to be matched against a stacktrace frame's `file_name`.
55-
If the regexp matches, the stacktrace frame is excluded from being used for calculating error groups.
86+
RegExp to be matched against a stacktrace frame's `file_name`.
87+
If the RegExp matches, the stacktrace frame is excluded from being used for calculating error groups.
5688
The default pattern excludes stacktrace frames that have a filename starting with `/webpack`.
5789

90+
[[config-sourcemapping-elasticsearch]]
91+
[float]
92+
==== `source_mapping.elasticsearch`
93+
Configure the Elasticsearch source map retrieval location, taking the same options as <<elasticsearch-output,output.elasticsearch>>.
94+
This must be set when using an output other than Elasticsearch, and that output is writing to Elasticsearch.
95+
Otherwise leave this section empty.
96+
5897
[[rum-sourcemap-cache]]
5998
[float]
6099
==== `source_mapping.cache.expiration`
@@ -64,15 +103,7 @@ Source maps are fetched from Elasticsearch and then kept in an in-memory cache f
64103
Values configured without a time unit are treated as seconds.
65104
Default value is 5 minutes.
66105

67-
[[config-sourcemapping-elasticsearch]]
68-
[float]
69-
==== `source_mapping.elasticsearch`
70-
Configure the Elasticsearch source map retrieval location, taking the same options as <<elasticsearch-output,output.elasticsearch>>.
71-
This must be set when using an output other than Elasticsearch, and that output is writing to Elasticsearch.
72-
Othewise leave this section empty.
73-
74106
[float]
75107
==== `source_mapping.index_pattern`
76-
Source maps are stored in a seperate index `apm-%{[beat.version]}-sourcemap` by default.
77-
If changed, a matching index pattern needs to be specified here.
78-
108+
Source maps are stored in a separate index `apm-%{[beat.version]}-sourcemap` by default.
109+
If changed, a matching index pattern needs to be specified here.

docs/configuring-ingest.asciidoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ Automatic pipeline registration requires `output.elasticsearch` to be enabled an
2626
as well as having the required Elasticsearch plugins installed.
2727

2828
APM Server default pipelines require you to have the Ingest user agent plugin installed.
29-
If pipelines are enabeld but required plugins are missing,
29+
If pipelines are enabled but required plugins are missing,
3030
the APM Server will not be able to properly connect to the Elasticsearch output.
3131
Find the default pipeline configuration at `ingest/pipeline/definition.json` of your APM Server
3232
installation's home directory.

docs/configuring-output-after.asciidoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,4 +24,4 @@ fields: {project: "myproject", instance-id: "574734885120952459"}
2424
------------------------------------------------------------------------------
2525

2626
To store the custom fields as top-level fields, set the `fields_under_root` option to true.
27-
This is not recommended as backwards compatibility can not be ensured as new fields are added to APM documents.
27+
This is not recommended as when new fields are added to APM documents backward compatibility cannot be ensured.

docs/data-ingestion.asciidoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ Increasing `queue.mem.events` can significantly affect APM Server memory usage.
4848

4949
[[adjust-concurrent-requests]]
5050
[float]
51-
=== Adjust concurrent requests
51+
=== Adjust concurrent requests deprecated[6.5]
5252
APM Server has a limit to how many requests can be processed concurrently.
5353
This limit is determined by the `apm-server.concurrent_requests` setting.
5454
Increasing this value will improve throughput, but it can significantly affect APM Server memory usage.

0 commit comments

Comments
 (0)