Eric Zhao
82578e1fdf
Refactor and improve fallback support for @SentinelResource annotation ( #693 )
- Refactor the semantics and logic for blockHandler and fallback
- Add `fallbackClass` support for fallback in global classes
- Add `defaultFallback` support
- Update test cases and demo
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 5 roky
Eric Zhao
5f713bd404
Update toString() method of ParamFlowRule
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 5 roky
Eric Zhao
e9719d32ec
Refactor flow algorithm for parameter flow control and support more traffic shaping mode ( #677 )
* support burst count, statistic interval per rule and throttling mode.
* Add fields in ParamFlowRule to support burst count, throttle, statistic interval per rule.
* Deprecate HotParamLeapArray and use token bucket algorithm directly.
před 5 roky
yikangfeng
08611fae0f
Add exceptionsToIgnore configuration support in @SentinelResource annotation ( #683 )
před 5 roky
Eric Zhao
df27e3ef9d
Code refactor and refinement for FileInJarReadableDataSource
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 5 roky
nick.ding
882a06007d
Add FileInJarReadableDataSource to support reading config file in jar ( #646 )
před 5 roky
Eric Zhao
29f22e370b
Fix the NPE bug when passing null args to SphU.entry() and paramIdx is negative ( #642 )
- Also rearrangement of some code
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 5 roky
Eric Zhao
0c3bf96678
Bump version to 1.6.0-SNAPSHOT
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 5 roky
Eric Zhao
48286e0ff8
Bump version to 1.5.1 (release)
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 5 roky
Eric Zhao
53a4e16144
Fix bug for completing entry with parameters in SentinelResourceAspect
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 5 roky
zhousiliang163
12c67d4770
Improve ZookeeperDataSource to deal with bad connection when initializing ( #597 )
před 5 roky
Eric Zhao
61c525076f
Improve SentinelResourceAspect and update test cases / document of annotation support
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 5 roky
beston123
6e1dfb374c
Add exceptionsToTrace configuration support in @SentinelResource annotation ( #543 )
před 5 roky
Eric Zhao
f60394c651
Add test cases for sentinel-annotation-aspectj ( #581 )
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 5 roky
lawrence wu
9051a6be96
Improve field naming in ApolloDataSource ( #593 )
před 5 roky
Bo Zhang
a3369378ad
Apply Alibaba p3c pmd plugin/rules and fix/ignore all violations of priority 1 ( #574 )
před 5 roky
Eric Zhao
0d4c47b23e
Bump version to 1.5.1-SNAPSHOT
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 5 roky
Eric Zhao
053f7172a3
Bump version to 1.5.0 (release)
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 5 roky
Eric Zhao
1741da0bab
Automatically de-duplicate rules when loading rules ( #571 )
* De-duplicate rules automatically when loading rules
* Update rule managers
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 5 roky
Eric Zhao
044cdbb1bf
Add occupy mechanism for future buckets of sliding window to support "prioritized requests final pass" ( #568 )
* Rename: MetricsLeapArray -> BucketLeapArray
* Add implementation for `FutureBucketLeapArray`, a kind of `BucketLeapArray` that only reserves for future buckets, which is used for calculating occupied future tokens.
* Add OccupiableBucketLeapArray that combines common BucketLeapArray with FutureBucketLeapArray. The rollingNumberInSecond in StatisticNode now uses OccupiableBucketLeapArray by default.
* Add OccupySupport interface. Node now implements OccupySupport interface.
* Add occupy-related methods in Metric and ArrayMetric.
* Handle prioritized requests in default traffic shaping controller.
* Update default occupyTimeout to 500ms
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 5 roky
Neptune
7367da6936
Upgrade apollo-client to 1.3.0 and add support for removing listener in sentinel-datasource-apollo ( #562 )
- Add to unsubscribe config change event
před 5 roky
Carpenter Lee
b8e295a138
Convert negative paramIdx of ParamFlowRule in ParamFlowSlot
Signed-off-by: Carpenter Lee <hooleeucas@163.com>
před 5 roky
Carpenter Lee
80797ae85e
Allow negative paramIndex as reversed-order in ParamFlowRule ( #549 )
* Allow negative paramIndex in ParamFlowRule
Signed-off-by: Carpenter Lee <hooleeucas@163.com>
před 5 roky
Eric Zhao
1ffce6b579
Fix test dependencies
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 5 roky
逅弈
59d923ebc1
Add an ApiCommandHandler to list all available commands and description ( #491 )
* Add a ApiCommandHandler which fetch all registered CommandHandlers so that user can get all available CommandHandlers by request /api
* Add a customized CommandHandler demo
před 5 roky
qinggeng
ec0883d22e
Add AuthInfo parameter in the constructor of ZooKeeperDataSource to support ACL ( #508 )
před 5 roky
Eric Zhao
5b260a9f75
Bump version to 1.5.0-SNAPSHOT
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 5 roky
Eric Zhao
2e0fe23384
Bump version to 1.4.2 (release)
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 5 roky
Eric Zhao
020a63fdb5
Bug fix: NPE when adding event count in ParamMapBucket ( #494 )
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 5 roky
Eric Zhao
412e1ece47
Carry the triggered rule in subclasses of BlockException ( #469 )
* Extract getRule in BlockException and refine override methods in subclasses
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 5 roky
yanlinly
1368154000
Update Nacos SDK version to 0.8 and update Nacos namespace demo ( #474 )
před 5 roky
Eric Zhao
bac35ac100
Add back thread count metric type support for parameter flow control
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 5 roky
Andres Almiray
e893dd8c64
Make build faster by reducing fixed waiting time in tests ( #449 )
- Apply awaitility to core tests
- Cache maven local repo in Travis
před 5 roky
Eric Zhao
3109ac4bef
Remove slf4j dependency in sentinel-annotation-aspectj
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 5 roky
Eric Zhao
d4d85dbc7c
Bump version to 1.4.2-SNAPSHOT
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 5 roky
Eric Zhao
225d81ed93
Bump version to 1.4.1
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 5 roky
Eric Zhao
832d6e425d
Update document to meet Markdown lint
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 6 roky
format
4592c45741
Upgrade nacos-client version and construct NacosDataSource by Properties ( #348 )
* Polish #272 : upgrade nacos-client version and create a new constructor for NacosDataSource to support namespace, endpoint, ak, sk and so on
* check properties in NacosDataSource
před 6 roky
Eric Zhao
f046194d6b
Add sampleCount and windowInterval item to cluster config of flow rule and param rule
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 6 roky
Eric Zhao
a2b91a9030
Refactor the constructor and units of LeapArray and related statistic class
- The constructor now accept `sampleCount` and `windowIntervalMs` so that it can match the two basic properties
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 6 roky
Eric Zhao
8096b22eb1
Add cluster embedded mode handling logic for parameter flow checker
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 6 roky
Eric Zhao
9916dad403
Bump version to 1.4.1-SNAPSHOT
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 6 roky
Eric Zhao
c7b5653249
Bump version to 1.4.0
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 6 roky
Eric Zhao
a5819e092d
Add HTTP command for modifying global state and client config
- Add several command handlers
- Update cluster state manager
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 6 roky
Eric Zhao
9a69104f79
Refactor param flow checker to support embedded server mode
- Add exception item extracting method in ParamFlowRule
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 6 roky
Eric Zhao
1043648fbc
Update parameter flow rule to adapt to cluster mode and extract rule util class
- Update ParamFlowRule to support cluster mode
- Add `ParamFlowClusterConfig` to provide cluster mode items for the rule
- Update ParamFlowChecker to support cluster flow mode
- Extract ParamFlowRuleUtil class
- Change type of `flowId` from Integer to Long
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 6 roky
Eric Zhao
f539b5b827
Update parameter flow rule to adapt to cluster mode and extract rule util class
- Update ParamFlowRule to support cluster mode
- Add `ParamFlowClusterConfig` to provide cluster mode items for the rule
- Update ParamFlowChecker to support cluster flow mode
- Extract ParamFlowRuleUtil class
- Change type of `flowId` from Integer to Long
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 6 roky
Eric Zhao
09ba7f081b
Resolves #256 : Support parameters in entry of Sentinel annotation support
- To enable parameter flow control in Sentinel annotation support
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 6 roky
Eric Zhao
2237727a11
Add prioritized entry support in ProcessorSlot and SphU ( #255 )
- Refactor the slot interface to support prioritized entry
- Add `entryWithPriority` in SphU
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 6 roky
Eric Zhao
f8bc6f631a
Code and javadoc refinement
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
před 6 roky