Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revert "Set generation in empty sentinel config response" #8751

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ private void returnEmpty(JRTServerConfigRequest request) {
log.log(LogLevel.INFO, "Returning empty sentinel config for request from " + request.getClientHostName());
ConfigPayload emptyPayload = ConfigPayload.empty();
String configMd5 = ConfigUtils.getMd5(emptyPayload);
ConfigResponse config = SlimeConfigResponse.fromConfigPayload(emptyPayload, null, request.getRequestGeneration() + 1, false, configMd5);
ConfigResponse config = SlimeConfigResponse.fromConfigPayload(emptyPayload, null, 0, false, configMd5);
request.addOkResponse(request.payloadFromResponse(config), config.getGeneration(), false, config.getConfigMd5());
respond(request);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -96,8 +96,6 @@ public void testEmptySentinelConfigWhenAppDeletedOnHostedVespa() throws IOExcept
new ConfigPayloadApplier<>(builder).applyPayload(payload);
SentinelConfig config = new SentinelConfig(builder);
assertEquals(0, config.service().size());
// Test generation explicitly since it is not set set the usual way
assertTrue(clientReq.getNewGeneration() > clientReq.getRequestGeneration());
}
}

Expand Down