MINOR: Check for active controller in UpdateFeatures request processing logic
Reviewers: Jun Rao
@@ -3133,6 +3133,8 @@ class KafkaApis(val requestChannel: RequestChannel,
if (!authorize(request.context, ALTER, CLUSTER, CLUSTER_NAME)) {
sendResponseCallback(Left(new ApiError(Errors.CLUSTER_AUTHORIZATION_FAILED)))
+ } else if (!controller.isActive) {
+ sendResponseCallback(Left(new ApiError(Errors.NOT_CONTROLLER)))
} else if (!config.isFeatureVersioningSupported) {
sendResponseCallback(Left(new ApiError(Errors.INVALID_REQUEST, "Feature versioning system is disabled.")))
} else {
