Commit 0a0d449
[Ratelimit Processor] Instrument the ratelimiter service with telemetry metrics (#562)
* first effort to instrument
Signed-off-by: Andreas Gkizas <[email protected]>
* adding initial implementation for metrics provider in ratelimiter
Signed-off-by: Andreas Gkizas <[email protected]>
* updating test to read projectid from metadata
Signed-off-by: Andreas Gkizas <[email protected]>
* license update
Signed-off-by: Andreas Gkizas <[email protected]>
* update with correct attributes as fucntions
Signed-off-by: Andreas Gkizas <[email protected]>
* changing Meter namespace
Signed-off-by: Andreas Gkizas <[email protected]>
* make goproto
Signed-off-by: Andreas Gkizas <[email protected]>
* run with metadata
Signed-off-by: Andreas Gkizas <[email protected]>
* run with metadata and remove unneeded funcsions
Signed-off-by: Andreas Gkizas <[email protected]>
* make go generate
Signed-off-by: Andreas Gkizas <[email protected]>
* make lint
Signed-off-by: Andreas Gkizas <[email protected]>
* adding err for projectID
Signed-off-by: Andreas Gkizas <[email protected]>
* license update
Signed-off-by: Andreas Gkizas <[email protected]>
* remove files
Signed-off-by: Andreas Gkizas <[email protected]>
* fixing tests
Signed-off-by: Andreas Gkizas <[email protected]>
* make fmt
Signed-off-by: Andreas Gkizas <[email protected]>
* make default projectID empty
Signed-off-by: Andreas Gkizas <[email protected]>
* make gogenerate
Signed-off-by: Andreas Gkizas <[email protected]>
* make gogenerate
Signed-off-by: Andreas Gkizas <[email protected]>
* Update processor/ratelimitprocessor/gubernator.go
Co-authored-by: Vignesh Shanmugam <[email protected]>
* abstract the metadata function and use WithErrorReason
Signed-off-by: Andreas Gkizas <[email protected]>
* Update processor/ratelimitprocessor/gubernator.go
Co-authored-by: kaiyan-sheng <[email protected]>
* Update processor/ratelimitprocessor/gubernator.go
Co-authored-by: kaiyan-sheng <[email protected]>
* moving to common function and changed labels
Signed-off-by: Andreas Gkizas <[email protected]>
* adding to local and also duraton metric
Signed-off-by: Andreas Gkizas <[email protected]>
* fix reason values and rerun make generate
* Add limit_threshold and throttle_behavior attrs
* run make license-update
* add test for limit threshold
* fix CodeGen and error message
* downgrade mdatagen to v0.124.0 to avoid missing import in generated file
* change mdatagen to v0.123.0
* remove project_id attr
* return errTooManyRequests when throttling
* Add goimports to fix the generated files
* add go install for goimports
* remove processor_id and reason field
* remove reason field when throttled in local.go
* fix errors
Signed-off-by: Andreas Gkizas <[email protected]>
* fix errors
Signed-off-by: Andreas Gkizas <[email protected]>
* fix errors
Signed-off-by: Andreas Gkizas <[email protected]>
* fix test
* move `metadata.NewTelemetryBuilder` to factory.go
* fix tests
* fix local_test.go
* remove attributes
* generate new documentation.md
* adding test with AssertEqualRatelimitRequests
Signed-off-by: Andreas Gkizas <[email protected]>
* add comment for the goimports workaround
---------
Signed-off-by: Andreas Gkizas <[email protected]>
Co-authored-by: Vignesh Shanmugam <[email protected]>
Co-authored-by: kaiyan-sheng <[email protected]>1 parent a2d4b06 commit 0a0d449
File tree
33 files changed
+743
-48
lines changed- .github/workflows
- connector/elasticapmconnector
- extension
- apmconfigextension
- beatsauthextension
- configintegrationextension
- fileintegrationextension
- internal/tools
- processor
- elasticinframetricsprocessor
- elastictraceprocessor
- integrationprocessor
- lsmintervalprocessor
- ratelimitprocessor
- internal
- metadatatest
- metadata
- telemetry
- receiver
- elasticapmreceiver
- integrationreceiver
- loadgenreceiver
33 files changed
+743
-48
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
162 | 162 | | |
163 | 163 | | |
164 | 164 | | |
165 | | - | |
| 165 | + | |
166 | 166 | | |
167 | 167 | | |
168 | 168 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
65 | 65 | | |
66 | 66 | | |
67 | 67 | | |
| 68 | + | |
| 69 | + | |
68 | 70 | | |
69 | 71 | | |
70 | 72 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
75 | 75 | | |
76 | 76 | | |
77 | 77 | | |
| 78 | + | |
78 | 79 | | |
79 | 80 | | |
80 | 81 | | |
| |||
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 2 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 2 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
| 14 | + | |
14 | 15 | | |
15 | 16 | | |
16 | 17 | | |
| |||
236 | 237 | | |
237 | 238 | | |
238 | 239 | | |
239 | | - | |
240 | 240 | | |
241 | 241 | | |
242 | 242 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
| 36 | + | |
36 | 37 | | |
37 | 38 | | |
0 commit comments