Commit Graph

721 Commits

Author SHA1 Message Date
hth
bdbc356ce4
fix RaftConfig is always {} (#11648) 2024-01-17 15:27:49 +08:00
chenyiqin
1943825e4d
server don't send its abilities when client don't send its abilities (#11661) 2024-01-17 15:19:36 +08:00
nov.lzf
c70a86820d
config module coverage (#11592)
* coverage

* coverage

* coverage up tp 80% ,fix checkstyle pmd

* coverage up tp 80% ,fix checkstyle pmd

* fix checkstyle

* optmize grpc connection push

* testcase

* grp connection coverage
2024-01-08 14:25:15 +08:00
hth
ea94095f74
[ISSUES #9001]spi instanceIdGenerator and snowFlakeInstanceIdGenerator (#11561)
* spi instanceIdGenerator and snowFlakeInstanceIdGenerator

* Test fix

* fix InstanceId set

* Copyright fix
2024-01-05 17:53:56 +08:00
chenyiqin
6b0636dd5d
support metric for grpc server request (#11427)
* support metric for grpc server request

* change way to judge field

* optimize record
2023-12-29 14:08:50 +08:00
nov.lzf
ca9d55e264
fix config test case and remove useless code (#11521)
* 修复客户端cmsgc导致服务端推送积压直接内存oom问题

* 修复ut及bug

* 修复ut及bug,checkstyle

* 修复ut及bug

* 修复ut

* 修复覆盖率

* 修复测试用例

* 修复测试用例,覆盖率

* 修复测试用例,覆盖率,删除无用代码

* 修复测试用例,覆盖率,pmd&checkstyle

* fix test case
2023-12-18 13:42:28 +08:00
nov.lzf
06edd123f9
check server stream ready state to avoid bytebuffer back up in flow control pending write queue. (#11514)
* 修复客户端cmsgc导致服务端推送积压直接内存oom问题

* 修复ut及bug

* 修复ut及bug,checkstyle

* 修复ut

* 修复覆盖率

* checkstyle
2023-12-15 15:40:45 +08:00
chenyiqin
01a28ee3cd
Support metric for grpc server executor (#11428)
* support metric for grpc server executor

* remove unused field

* add copyright

* add ut
2023-12-06 13:12:20 +08:00
chenyiqin
18a4672dd9
Support metric for module connection (#11426)
* support metric for module connection

* fix pmd

* add ut
2023-12-05 10:16:41 +08:00
chenyiqin
2fd002c8d1
fix: connection count of current node is not accurate (#11417) 2023-12-05 09:41:03 +08:00
blake.qiu
93cc842c90
feat(#11393): support register or deregister persistent instance by grpc in 2.3.0 server and client. (#11430) 2023-11-27 19:47:20 +08:00
zhanghong
65917ec986
[ISSUE #11343]Fix NPE (#11385)
* fix NPE

* fix NPE
2023-11-17 17:11:26 +08:00
zhanghong
a935fa1092
[ISSUE #11343] Simplified validation logic (#11345)
* 优化节点显示,添加mode

* Simplified validation logic

* add license

* fix unit test

* add config,console,naming unit test and rename annotation

* add config,console,naming unit test and rename annotation

* fix EnvUtils test

* fix EnvUtils test

* fix ParamExtractorFilterTest

* fix ParamExtractorFilterTest

* fix ParamExtractorFilterTest

* fix ParamExtractorFilterTest

* fix ParamExtractorFilterTest
2023-11-15 15:25:00 +08:00
杨翊 SionYang
e77a0bbe0d
Develop refactor topn (#11352)
* Move topn to core module.

* StringTopNCounter replace TopnCounterMetricsContainer.java

* Use ServiceTopNCounter replace StringTopNCounterTest for naming.

* Use FixedSizePriorityQueue replace PriorityQueue to save memory.

* For PMD.
2023-11-09 17:19:27 +08:00
黄科铭
e7e3824aac
add startup conditions (#11305)
* add startup conditions

* user movkEnv
2023-11-01 11:20:50 +08:00
杨翊 SionYang
c4aac2b82f
Fill ut for common module (#11247)
* Do some refactor and add UT for common package.

* Do some refactor and add UT for common package.

* Do some refactor and add UT for common package.

* Fix UT.
2023-10-13 14:46:04 +08:00
chenyiqin
a5c0a60a1a
Fix npe when setup ack response in GrpcClient (#11210)
* fix npe when setup ack response in GrpcClient

* server sync response, avoid blocking setup ack response sent to server.

* remove setup response from client to server, change way of server pushing abilities by sendNoACK

* add UT for negotiation timeout

* fix checkstyle

* fix PMD error

* private check logical into ReceiveAbilityContext.

* fix indent
2023-10-13 09:48:06 +08:00
阿魁
d85e3f7f31
[ISSUE #11231]Optimize the handleSpringBinder method in PropertiesUtil. (#11240) 2023-10-11 09:23:31 +08:00
KomachiSion
4522cbcccb For checkstyle. 2023-09-28 10:49:10 +08:00
Daydreamer-ia
cb70aaf3c7 refactor AbilityControlManager with multiple ability mode. 2023-09-25 19:24:44 +08:00
Daydreamer-ia
6bce3bda7b add AbilityPostProcessor param to know abilities init detail, sdk client, server or cluster client 2023-09-25 14:44:47 +08:00
Daydreamer-ia
41a3f13a66 remove HandlerMapping.java and ability change call back 2023-09-25 14:33:20 +08:00
Daydreamer-ia
c565a2bdd5 extern abilities spi processor, refactor AbilityKey. 2023-09-25 14:17:18 +08:00
Daydreamer-ia
e5f54badb3 remove connectionId in SetupAckRequest, expose timeout param for capability negotiation, add uncommitted file 2023-09-24 22:14:06 +08:00
Daydreamer-ia
fc8549dc8f Merge remote-tracking branch 'origin/develop' into asoc2022_issue#8458
# Conflicts:
#	client/src/test/java/com/alibaba/nacos/client/naming/remote/gprc/redo/NamingGrpcRedoServiceTest.java
#	common/src/main/java/com/alibaba/nacos/common/remote/client/grpc/GrpcClient.java
2023-09-24 15:18:17 +08:00
杨翊 SionYang
51b6a443d3
Refactor control plugin (#11174)
* Refactor control plugin and add default implementation.

* Move auth default plugin into other modules.

* Fix control plugin config not effect problem.

* Fix UT error.
2023-09-22 16:59:25 +08:00
杨翊 SionYang
0c44dce0cc
Refactor control plugin (#11169)
* Refactor control plugin.

* For checkstyle.
2023-09-21 13:47:28 +08:00
阿魁
5c8def0d25
[ISSUE #11072]Enhance unit tests related to trace events. (#11105) 2023-09-14 09:38:48 +08:00
Guangdong Liu
27216603c2
(bugfix) check null when obtaining the RpcClient. (#11042)
* fix-11028

* fix-11028

* fix-11028
2023-09-06 17:08:22 +08:00
Sunrisea
828acd3b2b
For #10734,补全参数检验日志记录,将返回的状态码修改为400 (#11073) 2023-09-01 11:41:23 +08:00
贾璞
937dbd59a2
[#11035] (PR-1/4) core module, trim (#11055) 2023-08-31 10:43:43 +08:00
blake.qiu
afe0035bb4
fix(#11032): adjust comment for RpcAckCallbackSynchronizer. (#11033) 2023-08-29 15:58:07 +08:00
Sunrisea
6c9c6957b8
[ISSUE #10734]Move the param check logic of grpc handler into the AbstractRequestFilter (#10972)
* For #10734,将grpc接口的参数请求移动到AbstractRequestFilter中实现

* For #10734,补充测试用例

* For #10734,fix code style

* For #10734,fix code style

* For #10734,fix test bug
2023-08-21 10:15:03 +08:00
ZhangShenao
65bad77274
Fix word spelling in ConnectionManager (#10966)
* Fix word spelling in `ConnectionManager`

* fix word
2023-08-17 10:42:52 +08:00
杨翊 SionYang
c4ddf1842f
Refactor Grpc Server, add transportFilter and ServerInterceptor exten… (#10970)
* Refactor Grpc Server, add transportFilter and ServerInterceptor extension.

* skip bad PMD rule.
2023-08-15 16:32:51 +08:00
Sunrisea
d756cdc6de
[ISSUE #10734] Optimize the param check implementation logic (#10955)
* For #10734,优化实现逻辑,提高扩展性,为动态变更限流规则预留接口

* For #10734,优化实现逻辑,提高扩展性,为动态变更参数校验规则预留接口
2023-08-14 14:55:49 +08:00
阿魁
fb5cfddb74
fix(distro): fix issue#10880. (#10881) 2023-08-01 15:36:12 +08:00
Sunrisea
8adca685f6
[ISSUE #10734] Refactor the ParamChecker and ParamExtractor (#10775)
* For #10734,refactor the paramextractor and ParamChecker

* For #10734,alter the rules of ParamCheck

* For #10734,alter the rules of ParamCheck

* For #10734,fix bug

* For #10734,fix bug and alter the ParamCheckRules.java

* For #10734,fix code style

* For #10734,fix the param check rules

* For #10734,implement the server param check config

* For #10734,optimize the logic

* For #10734,optimize the logic

* For #10734,optimize the logic
2023-07-19 16:34:03 +08:00
chenyiqin
318892d08d
Add the handle to overload connection (#10783)
* add the handle to overload connection

* fast return
2023-07-17 11:01:47 +08:00
杨翊 SionYang
9069730a04
Refactor grpc tls (#10759)
* Move Tls negotiator to GrpcSdkServer.

* use protocol negotiator builder replace directly create.

* use SPI load negotiator and set tls as default negotiator.

* Remove tlsconfig in BaseRpcServer.

* Add some ut.

* For checkstyle.
2023-07-11 19:10:00 +08:00
Sunrisea
cae21e2dcd
[ISSUE #10734] Implement grpc server interceptor and grpc param extractors (#10745)
* For #10734,Implement grpc server interceptor and grpc param extractors

* For #10734,add unit test for grpc server interceptor and grpc param extractors

* For #10734,alter the test case

* For #10734,delete the ConnectionSetupRequestParamExtractor
2023-07-10 14:43:51 +08:00
maoling
e7fbbc1301
improvements for leave node api and UI (#10748) 2023-07-10 13:39:22 +08:00
Sunrisea
ba8e0e2dff
[ISSUE #10734] Implemented the parameter validation utility class (#10737)
* For #10734,Refactor the AbstractConfigRequest ,move common properties from its subclasses to the parent class,to reduce the number of corresponding parameter extractors by .

* For #10734,add ParamCheckRules,ParamCheckUtils, add  ParamExtractor interface and the abstract classes HttpParamExtractor and RpcParamExtractor, implement the corresponding Manager.

* For #10734,fix codestyle

* For #10734,fix codestyle , move extractor and extractorManager to core directory

* For #10734,fix codestyle

* For #10734,fix dependency of common module

* For #10734,fix codestyle and copyright

* For #10734,fix pom codestyle and copyright

* For #10734,fix pom codestyle and copyright

* For #10734,fix  copyright

* For #10734,fix  copyright

* For #10734,fix bug caused by refactor of AbstractConfigRequest ,add ut test of ParamExtractorManager

* For #10734,fix bug caused by refactor of AbstractConfigRequest

---------

Co-authored-by: zhuoguang <sunrisea@B-Q6UQMD6R-0222.local>
2023-07-07 11:06:00 +08:00
Daydreamer-ia
d4e9b836d2 fix checkstyle and fix bug 2023-06-22 17:08:04 +08:00
Daydreamer-ia
fc3bb2f42c Merge branch 'develop' into asoc#8458.t
# Conflicts:
#	client/src/main/java/com/alibaba/nacos/client/config/impl/ClientWorker.java
#	common/src/main/java/com/alibaba/nacos/common/remote/client/ConnectionEventListener.java
#	common/src/main/java/com/alibaba/nacos/common/remote/client/RpcClient.java
#	common/src/main/java/com/alibaba/nacos/common/remote/client/grpc/GrpcClient.java
#	common/src/test/java/com/alibaba/nacos/common/remote/client/grpc/GrpcClientTest.java
#	core/src/main/java/com/alibaba/nacos/core/cluster/ServerMemberManager.java
#	core/src/main/java/com/alibaba/nacos/core/remote/grpc/GrpcBiStreamRequestAcceptor.java
#	core/src/main/java/com/alibaba/nacos/core/remote/grpc/GrpcRequestAcceptor.java
2023-06-22 15:33:05 +08:00
nov.lzf
0ba772658d
replace nacos cache with guava cache (#10674)
* replace nacos cache with
guava cache tt fix memory leak

* checkstyle
2023-06-20 13:34:20 +08:00
zhanghong
38f461eb12
[ISSUE #10583]修复权限 (#10587)
* 修复权限

* 修改为console

* 修改为console
2023-06-05 17:21:05 +08:00
nov.lzf
505c90b96d
uniform config lastmodified ts & refactor config disk storage. (#10533)
* uniform cache timestamp

* uniform cache timestamp

* uniform cache timestamp

* uniform cache timestamp

* checkstyle & pmd

* revert application properties

* remove duplicate code

* checkstyle and pmd

* bug fix
2023-05-26 09:53:25 +08:00
杨翊 SionYang
cf59d62260
HessianSerializer add whitelist. (#10542) (#10546)
* HessianSerializer add whitelist. (#10542)

* HessianSerializer add whitelist.

* Handle exception in onApply and onRequest to save the stateMachine.

* Add new ut for HessianSerializer

* Fix unit test.

* For checkstyle.
2023-05-26 09:31:55 +08:00
nov.lzf
51903edd82
add out date connection active detection,expel it when client no response. (#10509)
* add out date connection active detection,expel it when client no response.

* add out date connection active detection,expel it when client no response.
2023-05-19 10:20:37 +08:00