Skip to content

Commit 411c17c

Browse files
Nyholmfabpot
authored andcommitted
[RateLimiter] Moved classes implementing LimiterInterface to a new namespace
1 parent 917ebfa commit 411c17c

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

DependencyInjection/Configuration.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
use Symfony\Component\Messenger\MessageBusInterface;
3232
use Symfony\Component\Notifier\Notifier;
3333
use Symfony\Component\PropertyInfo\PropertyInfoExtractorInterface;
34-
use Symfony\Component\RateLimiter\TokenBucketLimiter;
34+
use Symfony\Component\RateLimiter\Policy\TokenBucketLimiter;
3535
use Symfony\Component\Serializer\Serializer;
3636
use Symfony\Component\Translation\Translator;
3737
use Symfony\Component\Validator\Validation;
@@ -1843,7 +1843,7 @@ private function addRateLimiterSection(ArrayNodeDefinition $rootNode)
18431843
->info('The service ID of a custom storage implementation, this precedes any configured "cache_pool"')
18441844
->defaultNull()
18451845
->end()
1846-
->enumNode('strategy')
1846+
->enumNode('policy')
18471847
->info('The rate limiting algorithm to use for this rate')
18481848
->isRequired()
18491849
->values(['fixed_window', 'token_bucket', 'sliding_window', 'no_limit'])
@@ -1853,10 +1853,10 @@ private function addRateLimiterSection(ArrayNodeDefinition $rootNode)
18531853
->isRequired()
18541854
->end()
18551855
->scalarNode('interval')
1856-
->info('Configures the fixed interval if "strategy" is set to "fixed_window" or "sliding_window". The value must be a number followed by "second", "minute", "hour", "day", "week" or "month" (or their plural equivalent).')
1856+
->info('Configures the fixed interval if "policy" is set to "fixed_window" or "sliding_window". The value must be a number followed by "second", "minute", "hour", "day", "week" or "month" (or their plural equivalent).')
18571857
->end()
18581858
->arrayNode('rate')
1859-
->info('Configures the fill rate if "strategy" is set to "token_bucket"')
1859+
->info('Configures the fill rate if "policy" is set to "token_bucket"')
18601860
->children()
18611861
->scalarNode('interval')
18621862
->info('Configures the rate interval. The value must be a number followed by "second", "minute", "hour", "day", "week" or "month" (or their plural equivalent).')

0 commit comments

Comments
 (0)