Commit Graph

182 Commits

Author SHA1 Message Date
LearningGp eb3a9b099a
Bump version to 1.8.9 (#3566)
* chore: update release configuration

* Bump version to 1.8.9
2025-10-16 20:26:58 +08:00
XenoAmess 7e17ae7c0d
chore: refine pom (#3560) 2025-09-30 15:08:50 +08:00
mawen ca596457b0
refactor: remove repeat check code (#3501) 2025-08-19 19:27:34 +08:00
LearningGp 5473ad7b3e
fix(README.md): Fix MD059 issue (#3539) 2025-08-07 15:38:27 +08:00
LearningGp 3892514c53 Bump version to 1.8.8 2024-06-04 16:05:34 +08:00
dependabot[bot] 773a715827
build(deps-dev): Bump org.springframework:spring-context (#3404)
Bumps [org.springframework:spring-context](https://github.com/spring-projects/spring-framework) from 5.1.5.RELEASE to 5.2.21.RELEASE.
- [Release notes](https://github.com/spring-projects/spring-framework/releases)
- [Commits](https://github.com/spring-projects/spring-framework/compare/v5.1.5.RELEASE...v5.2.21.RELEASE)

---
updated-dependencies:
- dependency-name: org.springframework:spring-context
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-29 20:39:59 +08:00
dependabot[bot] cf81be1bb0
build(deps): Bump com.fasterxml.jackson.core:jackson-databind (#3342)
Bumps [com.fasterxml.jackson.core:jackson-databind](https://github.com/FasterXML/jackson) from 2.13.0 to 2.13.4.2.
- [Commits](https://github.com/FasterXML/jackson/commits)

---
updated-dependencies:
- dependency-name: com.fasterxml.jackson.core:jackson-databind
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-29 20:32:58 +08:00
dowenliu-xyz 568e2df296
Fix reflection exceptions caused by having identically named fallback/blockHandler with different parameter types (#3395) 2024-05-29 20:26:30 +08:00
dependabot[bot] bb813ddff3
build(deps-dev): Bump org.springframework:spring-expression (#3375)
Bumps [org.springframework:spring-expression](https://github.com/spring-projects/spring-framework) from 5.1.8.RELEASE to 5.2.24.RELEASE.
- [Release notes](https://github.com/spring-projects/spring-framework/releases)
- [Commits](https://github.com/spring-projects/spring-framework/compare/v5.1.8.RELEASE...v5.2.24.RELEASE)

---
updated-dependencies:
- dependency-name: org.springframework:spring-expression
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-27 21:02:44 +08:00
Robert Lu cd02b1dc8d
fix flaky tests and fix passDefaultLocalCheck (#3367)
* fix test case SentinelDubboConsumerFilterTest#testDegradeSync

* When test is run slow, count bucket will count on next time span, causing failed test.

* dos2unix ParamFlowDefaultCheckerTest.java

* fix testParamFlowDefaultCheckSingleValueCheckQpsMultipleThreads by rule.setDurationInSec(2)

* set threshold as count in 2 seconds to prevent the failure of the unit test when the unit test runs longer than 1 second.

* fix quarkus test by set /txt sleep 300

* If /txt sleep 500 ms, in testSentinelJaxRsQuarkusAdapter, may cause 2 request intervals of more than 1 s, which cause rate limit policy is not effective.

* fix testDegradeAsync

* When test is run slow, count bucket will count on next time span, causing failed test.

* use testcontainers to fix testConsulDataSourceWhenInit

* Project embedded-consul has been deprecated in favour of org.testcontainers:consul
* use consul testcontainers to fix testConsulDataSourceWhenInit, which means docker is required to run tests.
```
Error:  com.alibaba.csp.sentinel.datasource.consul.ConsulDataSourceTest.testConsulDataSourceWhenInit -- Time elapsed: 34.47 s <<< ERROR!
  com.pszymczyk.consul.EmbeddedConsulException: Could not start Consul process in 30 seconds
  	at java.base/jdk.internal.reflect.DirectConstructorHandleAccessor.newInstance(DirectConstructorHandleAccessor.java:62)
  	at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:502)
  	at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:486)
  	at org.codehaus.groovy.reflection.CachedConstructor.invoke(CachedConstructor.java:72)
 ```

* introduce intermediate node to avoid ABA problem
2024-04-17 10:25:25 +08:00
Robert Lu befdc56885
fix flaky tests (#3364)
* fix ParamFlowPartialIntegrationTest

mock TimeUtil to avoid time changed, and bucket moved to next.

* remove csp.sentinel.log.output.type

remove sysprop csp.sentinel.log.output.type in TimeUtilTest,
to avoid a few outputs.

* try fix testConcurrentAcquireAndRelease

* remove stdout

remove sout in ParamFlowThrottleRateLimitingCheckerTest,
to avoid a few outputs.

* ConcurrentClusterFlowCheckerTest,djust the flowId to prevent conflicts

* CurrentConcurrencyManagerTest,adjust the flowId to prevent conflicts

* update year
2024-03-25 10:09:16 +08:00
Robert Lu ae6ebb49d0
Move document-lint from circleci to github-actions (#3345)
Move document-lint from circleci to github-actions.
Adjust document according to markdownlint-cli rules.
2024-02-21 17:05:29 +08:00
Robert Lu 8fef1b5eee
Support jdk17 (#3339)
Adjust the test logic, use jdk17 to build, 8, 11, 17 to run
2024-02-20 18:58:52 +08:00
LearningGp f3fd4e6187 Bump version to 1.8.7 2023-12-28 19:32:10 +08:00
LearningGp 665fb541a7 Bump version to 1.8.7-SNAPSHOT 2023-12-28 17:48:44 +08:00
quguai c4ed9a3aba Resource rules (flow/degrade/param/authority) support regex matching (#3251) 2023-12-27 20:44:06 +08:00
karl-sy 2e18c3e916 metric: Add Prometheus exporter module for Sentinel metrics (#3173) 2023-12-27 20:43:41 +08:00
langshiquan 74f7d184cf Add SSL support for sentinel-datasource-redis (#3045) 2023-12-27 20:40:27 +08:00
pandaapo 20a6a63e0c Upgrade curator-recipes to 5.1.0 to fix API change for ZooKeeper data-source (#2963)
* Fix issue to upgrade curator-recipes and related API.
* Resolve test failure: ClassNotFoundException of ZooKeeperAdmin.
* Remove unused property in pom.
2023-12-27 20:40:26 +08:00
pandaapo 44080bc886 Fix potential connection leak bug when closing NacosDataSource (#2962) 2023-12-27 20:40:26 +08:00
ZhangYan 9db0c70cbb Fix thread-blocked problem of EtcdDataSource (#2991)
* fix thread blocked problem of etcd watcher

in the previous version of EtcdDataSource, when the flowRules defined in the etcd change and trigger etcd watcher, there will be a following error:
2022-12-07 14:36:03.592 [vertx-blocked-thread-checker] WARN io.vertx.core.impl.BlockedThreadChecker [?:?] -  Thread Thread[vert.x-eventloop-thread-0,5,main] has been blocked for 2336 ms, time limit is 2000 ms
2022-12-07 14:36:04.592 [vertx-blocked-thread-checker] WARN io.vertx.core.impl.BlockedThreadChecker [?:?] -  Thread Thread[vert.x-eventloop-thread-0,5,main] has been blocked for 3337 ms, time limit is 2000 ms
2022-12-07 14:36:05.592 [vertx-blocked-thread-checker] WARN io.vertx.core.impl.BlockedThreadChecker [?:?] -  Thread Thread[vert.x-eventloop-thread-0,5,main] has been blocked for 4337 ms, time limit is 2000 ms
2022-12-07 14:36:06.595 [vertx-blocked-thread-checker] WARN io.vertx.core.impl.BlockedThreadChecker [?:?] -  Thread Thread[vert.x-eventloop-thread-0,5,main] has been blocked for 5337 ms, time limit is 2000 ms
io.vertx.core.VertxException: Thread blocked
 at sun.misc.Unsafe.park(Native Method)
 at java.util.concurrent.locks.LockSupport.park(LockSupport.java:175)
 at java.util.concurrent.CompletableFuture$Signaller.block(CompletableFuture.java:1707)
 at java.util.concurrent.ForkJoinPool.managedBlock(ForkJoinPool.java:3334)
 at java.util.concurrent.CompletableFuture.waitingGet(CompletableFuture.java:1742)
 at java.util.concurrent.CompletableFuture.get(CompletableFuture.java:1908)
 at com.htsc.fst.saas.infrastructure.component.EtcdDataSource.readSource(EtcdDataSource.java:92)
 at com.htsc.fst.saas.infrastructure.component.EtcdDataSource.readSource(EtcdDataSource.java:23)
 at com.alibaba.csp.sentinel.datasource.AbstractDataSource.loadConfig(AbstractDataSource.java:44)
 at com.htsc.fst.saas.infrastructure.component.EtcdDataSource.lambda$initWatcher$0(EtcdDataSource.java:74)
 at com.htsc.fst.saas.infrastructure.component.EtcdDataSource$$Lambda$480/1375681611.accept(Unknown Source)
 at io.etcd.jetcd.Watch$1.onNext(Watch.java:183)
 at io.etcd.jetcd.impl.WatchImpl$WatcherImpl.onNext(WatchImpl.java:310)
 at io.etcd.jetcd.impl.WatchImpl$WatcherImpl$$Lambda$488/2088661957.handle(Unknown Source

I guess the reason is : when the watcher hold etcd Client, you can't use etcd Client in the Watch's consumer function. 
Besides the problem above, use getKeyValue() in the watchEvent can reduce once invoke with etcd server to getting the latest flowRules :)

* Update EtcdDataSource.java

Add charset adaptation -- accept the suggestion from @LProDreamAll
2023-12-27 20:40:26 +08:00
quguai 59a32994cd Fix the bug that error occurs in JMX metrics exporter when resource name contains '*' (#2992) 2023-12-27 20:40:26 +08:00
garroshh 1483669aaf Update metrics name for better monitor selection in JMX MetricBeanWriter extension (#2976) 2023-12-27 20:40:26 +08:00
Eric Zhao dd1ba2725e Bump version to 1.8.6
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
2022-10-25 16:57:18 +08:00
Eric Zhao 84df19b2c5 Bump version to 1.8.6-SNAPSHOT
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
2022-09-15 09:50:36 +08:00
Eric Zhao 24ac1be442 Bump version to 1.8.5 and update README.md
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
2022-08-08 21:29:40 +08:00
benyamin2014 0bd27fb80a
Auto-extract value from ParamFlowArgument when blocked in ParamFlowSlot (#2776)
* Assign actual value with the result of paramFlowKey method
2022-08-08 11:20:42 +08:00
Eric Zhao 9b7786259e Bump version to 1.8.5-SNAPSHOT
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
2022-08-08 09:52:51 +08:00
zuohl 374481c9d4
Replace deprecated API for Lettuce in sentinel-datasource-redis (#2704) 2022-05-10 09:59:20 +08:00
Eric Zhao 16e1bb8fe8 Bump version to 1.8.4
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
2022-04-12 10:14:53 +08:00
程露 33d14fc12e
doc: Add README.md for sentinel-metric-exporter module (#2550)
* add the reademe file to module `sentinel-metric-exporter`
* format the md file
* [ISSUE #2545] update the screenshot.
2022-01-25 17:22:30 +08:00
程露 2df682dad2
build(deps): Upgrade nacos-client to 1.4.2 for sentinel-datasource-nacos (#2477)
* [ISSUE #2425] upgrade the Nacos client version to 1.4.2.
* [ISSUE #2425] remove the unused code and import.
2022-01-10 20:34:14 +08:00
Eric Zhao 8724a7c0a1 Bump version to 1.8.4-SNAPSHOT
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
2022-01-01 11:00:04 +08:00
Eric Zhao 6135ff290a Bump version to 1.8.3
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
2021-12-31 14:46:52 +08:00
Eric Zhao 51b21921f5 Bump version to 1.8.3-SNAPSHOT
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
2021-12-22 14:48:43 +08:00
brotherlu-xcq 25651de09a
Add metric exporter extension for exporting Sentinel metrics via JMX (#2275)
* Expose the MetricItem AS MBean
2021-09-15 10:03:09 +08:00
Zhiguo.Chen 436a88562e
Add ACL token support for Consul data-source (#2307)
Co-authored-by: Zhiguo.Chen <chenzhiguo@jd.com>
2021-07-27 18:37:08 +08:00
Eric Zhao 4498de480f Bump version to 1.8.2
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
2021-07-05 19:59:44 +08:00
wuwen 627b319bb4
dependency: Remove duplicate aspectjrt dependency in annotation-aspectj module (#2234)
* aspectjweaver already contains aspectjrt
2021-06-18 17:52:54 +08:00
wuwen f972b103db
Support private blockHandler/fallback method for @SentinelResource annotation (#2163) 2021-06-07 14:18:39 +08:00
wutingjia 9a612508ff Make all backend thread pools daemon (#2181)
* feat:make command center thread daemon
* feat:make all NamedThreadFactory thread daemon
2021-06-04 13:33:46 +08:00
liqiangz 3e438b3dba
Support Redis cluster mode in Redis data-source extension (#1751) 2021-03-09 09:59:33 +08:00
Yan Haonan 4aaf8e9093
Remove unused HotParameterLeapArray in param flow control module (#2070) 2021-03-08 10:52:25 +08:00
ss-superman dfce6ebba4
Remove redundant code in SentinelResourceAspect (#2016) 2021-02-07 15:24:19 +08:00
Eric Zhao fca70646ad Bump version to 1.8.2-SNAPSHOT
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
2021-02-04 16:45:40 +08:00
Eric Zhao ae214b5244 Bump version to 1.8.1
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
2021-02-04 15:30:44 +08:00
Eric Zhao be2715d814 Update source/target JDK version to 1.8 and update documents
Signed-off-by: Eric Zhao <sczyh16@gmail.com>
2021-02-04 10:21:40 +08:00
cdfive 62efb78d4e
Refactor SpiLoader and enhance SPI mechanism (#1383)
* Add `@Spi` annotation as the general annotation for SPI definition.
* Add isDefault in @Spi, add loadDefaultInstance and improve loadFirstInstanceOrDefault method, improve test cases
* Add SpiLoaderException class for thrown when something goes wrong while loading Provider
* Rearrange packages of base SPI mechanism

NOTE: this PR contains breaking changes regarding API.
2021-01-27 09:45:56 +08:00
brothelul 70b457bdc8
Fix potential NPE bug when updating ParamFlowRule before the resource has been requested once (#1901) 2020-12-18 11:20:38 +08:00
odidev 8c4f251922
CI: Polish dependencies for ARM64 and add ARM64 job to Travis CI (#1765)
1. Added ARM64 architecture in .travis.yml
2. Updated 'embedded-consul' version to 2.2.0, 'consul-api' version to 1.4.5 for ARM64 support.
3. Updated grpc.version for 'io.grpc:protoc-gen-grpc-java' to 1.30.2, for ARM64 support.

Signed-off-by: odidev <odidev@puresoftware.com>
2020-11-09 14:40:58 +08:00