-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add ability to adjust static sampling probabilities per operation (#827)
- Loading branch information
1 parent
cf242c3
commit 9d05fad
Showing
5 changed files
with
128 additions
and
3 deletions.
There are no files selected for viewing
42 changes: 42 additions & 0 deletions
42
plugin/sampling/strategystore/static/fixtures/operation_strategies.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
{ | ||
"default_strategy": { | ||
"type": "probabilistic", | ||
"param": 0.5 | ||
}, | ||
"service_strategies": [ | ||
{ | ||
"service": "foo", | ||
"type": "probabilistic", | ||
"param": 0.8, | ||
"operation_strategies": [ | ||
{ | ||
"operation": "op1", | ||
"type": "probabilistic", | ||
"param": 0.2 | ||
}, | ||
{ | ||
"operation": "op2", | ||
"type": "ratelimiting", | ||
"param": 10 | ||
} | ||
] | ||
}, | ||
{ | ||
"service": "bar", | ||
"type": "ratelimiting", | ||
"param": 5, | ||
"operation_strategies": [ | ||
{ | ||
"operation": "op3", | ||
"type": "probabilistic", | ||
"param": 0.3 | ||
}, | ||
{ | ||
"operation": "op4", | ||
"type": "ratelimiting", | ||
"param": 100 | ||
} | ||
] | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters