Skip to content

Commit

Permalink
server don't send its abilities when client don't send its abilities (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
Daydreamer-ia authored Jan 17, 2024
1 parent a7d1c35 commit 1943825
Showing 1 changed file with 9 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -138,10 +138,15 @@ public void onNext(Payload payload) {
}
} else {
try {
// finish register, tell client has set up successfully
// async response without client ack
connection.sendRequestNoAck(new SetupAckRequest(NacosAbilityManagerHolder.getInstance()
.getCurrentNodeAbilities(AbilityMode.SERVER)));
// server sends abilities only when:
// 1. client sends setUpRequest with its abilities table
// 2. client sends setUpRequest with empty table
if (setUpRequest.getAbilityTable() != null) {
// finish register, tell client has set up successfully
// async response without client ack
connection.sendRequestNoAck(new SetupAckRequest(NacosAbilityManagerHolder.getInstance()
.getCurrentNodeAbilities(AbilityMode.SERVER)));
}
} catch (Exception e) {
// nothing to do

Expand Down

0 comments on commit 1943825

Please sign in to comment.