Eric Zhao
346e9b274e
Bump version to 1.6.1-SNAPSHOT
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
vor 5 Jahren
Eric Zhao
b1345f751f
Bump version to 1.6.0 (release)
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
vor 5 Jahren
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>
vor 5 Jahren
Eric Zhao
bb4fde58b8
Add appType property field in SentinelConfig
- The `appType` can be retrieved from `csp.sentinel.app.type` field. It's useful to identify the service type (e.g. API gateway).
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
vor 5 Jahren
Eric Zhao
c316211faf
Add loadInstanceList support for SpiLoader
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
vor 5 Jahren
yikangfeng
08611fae0f
Add exceptionsToIgnore configuration support in @SentinelResource annotation ( #683 )
vor 5 Jahren
zhaixiaoxiang
cb9335126c
test: Fix unstable test cases in OccupiableBucketLeapArrayTest ( #687 )
vor 5 Jahren
Eric Zhao
7d344dcb95
Improve AbstractTimeBasedTest in sentinel-core
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
vor 5 Jahren
Eric Zhao
79211f055c
Add @SpiOrder annotation and update SPI loader for loading SPI with highest precedence
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
vor 5 Jahren
jason
73f166e258
Make ClusterNodeTest.testGetOrCreateOriginNodeMultiThread stable
vor 5 Jahren
jason
16082a875c
Make WarmUpRateLimiterControllerTest stable
vor 5 Jahren
Paul Kenneth Kent
4cc25429d3
Add unit tests for com.alibaba.csp.sentinel.util ( #651 )
* Add unit test for com.alibaba.csp.sentinel.util.IdUtil
* Add unit tests for com.alibaba.csp.sentinel.util.StringUtil
vor 5 Jahren
Eric Zhao
0c3bf96678
Bump version to 1.6.0-SNAPSHOT
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
vor 5 Jahren
Eric Zhao
48286e0ff8
Bump version to 1.5.1 (release)
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
vor 5 Jahren
Eric Zhao
d5204bb6a4
Ensure Error caught in InitExecutor and do not exit when error occurs in LogBase ( #613 )
to avoid affecting normal logic of users
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
vor 5 Jahren
Eric Zhao
61c525076f
Improve SentinelResourceAspect and update test cases / document of annotation support
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
vor 5 Jahren
beston123
6e1dfb374c
Add exceptionsToTrace configuration support in @SentinelResource annotation ( #543 )
vor 5 Jahren
Eric Zhao
468327bdcd
Remove useless global NodeBuilder in Env class
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
vor 5 Jahren
Carpenter Lee
7feaf709fc
Fix deadlock bug in Env static initialization ( #610 )
Signed-off-by: Carpenter Lee <hooleeucas@163.com>
vor 5 Jahren
Bo Zhang
a3369378ad
Apply Alibaba p3c pmd plugin/rules and fix/ignore all violations of priority 1 ( #574 )
vor 5 Jahren
Eric Zhao
0d4c47b23e
Bump version to 1.5.1-SNAPSHOT
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
vor 5 Jahren
Eric Zhao
053f7172a3
Bump version to 1.5.0 (release)
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
vor 5 Jahren
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>
vor 5 Jahren
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>
vor 5 Jahren
Eric Zhao
4b1ccd93e2
Refactor Node interface: change return type of `xxxQps` method from long to double ( #564 )
- Update test cases (use assertEquals(e, a, delta) instead)
- Also add `totalPass` method in Node interface
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
vor 5 Jahren
Carpenter Lee
63d7c9d207
Revert "Add more overload methods in SphO and SphO" to avoid ambiguous method call
This reverts commit 35371c1
Signed-off-by: Carpenter Lee <hooleeucas@163.com>
vor 5 Jahren
Carpenter Lee
35371c1a3c
Add more overload methods in SphO and SphO
Signed-off-by: Carpenter Lee <hooleeucas@163.com>
vor 5 Jahren
Carpenter Lee
341b6426f0
Record total inbound traffic data in metric file ( #555 )
- Regard the total inbound as a "virtual node" with the name `__total_inbound_traffic__`
Signed-off-by: Carpenter Lee <hooleeucas@163.com>
vor 5 Jahren
Eric Zhao
4073053b3a
Update javadoc for core classes
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
vor 5 Jahren
Eric Zhao
775484ba61
Add try-with-resources support for Entry class ( #550 )
- `Entry` class now implements `AutoCloseable` so it supports try-with-resources (`close` method adapts to `exit`)
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
vor 5 Jahren
yikangfeng
9ec1985755
Fix SimpleDateFormat concurrent issue in CspFormatter of sentinel-core ( #548 )
vor 5 Jahren
Carpenter Lee
5279895581
Add highestCpuUsage in system rule.
Signed-off-by: Carpenter Lee <hooleeucas@163.com>
vor 5 Jahren
Eric Zhao
1ffce6b579
Fix test dependencies
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
vor 5 Jahren
Jason Joo
5d3ccb0863
Solve the issue that sleeping-based tests are not stable and optimize slow tests ( #546 )
vor 5 Jahren
ATAXGT
10d7c903cf
Optimize circuit breaking state transformation using CAS in DegradeRule ( #538 )
close → open: use `compareAndSet` to update for `cut` attribute (changed to an `AtomicBoolean`)
vor 5 Jahren
Carpenter Lee
5d2170282f
Add Sph.entryWithPriority() method to receive args
Signed-off-by: Carpenter Lee <hooleeucas@163.com>
vor 5 Jahren
mjaow
291742c171
Change default value of avgUsedTokens to zero to be more meaningful in DefaultController ( #460 )
vor 5 Jahren
Eric Zhao
5b260a9f75
Bump version to 1.5.0-SNAPSHOT
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
vor 5 Jahren
Eric Zhao
2e0fe23384
Bump version to 1.4.2 (release)
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
vor 5 Jahren
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>
vor 5 Jahren
mjaow
5c0fd5651a
Add volatile in double-checked locking field in ClusterBuilderSlot ( #466 )
vor 5 Jahren
Eric Zhao
35537a691e
Refinement for test cases
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
vor 5 Jahren
cdfive
22e8d85a8f
Add some unit test for StatisticNode, ClusterNode and DefaultNodeBuilder class ( #423 )
vor 5 Jahren
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
vor 5 Jahren
Eric Zhao
cd334406af
Code and javadoc refinement
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
vor 5 Jahren
luoxiangnan
f306a03090
HashMap init optimize when adding new ClusterNode to cluster node map ( #465 )
- reuse old map size to avoid rearrange and rehash the map
vor 5 Jahren
mjaow
2cf6e29e72
Fix zero-count divide overflow bug in RateLimiterController ( #461 )
vor 5 Jahren
mjaow
223ad252df
Remove duplicate comment in WarmUpController ( #464 )
vor 5 Jahren
mjaow
30907e4c9d
Fix error value type and rename variable in EntranceNode class ( #457 )
vor 5 Jahren
Eric Zhao
ba4fdcc638
Fixes #453 : Support tracing exception count for specific entry or context in Tracer
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
vor 5 Jahren