This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@IsolatedTest | |
void testCruiseControlChangesToProposalReadyWhenRestartedWhileRebalancing() { | |
TestStorage testStorage = new TestStorage(ResourceManager.getTestContext()); | |
resourceManager.createResourceWithWait( | |
NodePoolsConverter.convertNodePoolsIfNeeded( | |
KafkaNodePoolTemplates.brokerPool(Environment.TEST_SUITE_NAMESPACE, testStorage.getBrokerPoolName(), testStorage.getClusterName(), 3).build(), | |
KafkaNodePoolTemplates.controllerPool(Environment.TEST_SUITE_NAMESPACE, testStorage.getControllerPoolName(), testStorage.getClusterName(), 1).build() | |
) | |
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@IsolatedTest | |
void testCruiseControlChangesToProposalReadyWhenRestartedWhileRebalancing() { | |
TestStorage testStorage = new TestStorage(ResourceManager.getTestContext()); | |
resourceManager.createResourceWithWait( | |
NodePoolsConverter.convertNodePoolsIfNeeded( | |
KafkaNodePoolTemplates.brokerPool(clusterOperator.getDeploymentNamespace(), testStorage.getBrokerPoolName(), testStorage.getClusterName(), 3).build(), | |
KafkaNodePoolTemplates.controllerPool(clusterOperator.getDeploymentNamespace(), testStorage.getControllerPoolName(), testStorage.getClusterName(), 1).build() | |
) | |
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
HOST BROKER RACK LOGDIR DISK_CAP(MB) DISK(MB)/_(%)_ CORE_NUM CPU(%) NW_IN_CAP(KB/s) LEADER_NW_IN(KB/s) FOLLOWER_NW_IN(KB/s) NW_OUT_CAP(KB/s) NW_OUT(KB/s) PNW_OUT(KB/s) LEADERS/REPLICAS | |
127.0.0.1, 0,127.0.0.1, 307200.000, 0.144/00.00, 1, 0.544, 10000.000, 0.057, 0.049, 10000.000, 0.378, 0.611, 32/65 | |
/var/lib/kafka/data-0/kafka-log0, DEAD/ DEAD, 15/33 | |
/var/lib/kafka/data-1/kafka-log0, 0.045/00.00, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Current load: | |
HOST BROKER RACK LOGDIR DISK_CAP(MB) DISK(MB)/_(%)_ CORE_NUM CPU(%) NW_IN_CAP(KB/s) LEADER_NW_IN(KB/s) FOLLOWER_NW_IN(KB/s) NW_OUT_CAP(KB/s) NW_OUT(KB/s) PNW_OUT(KB/s) LEADERS/REPLICAS | |
127.0.0.1, 0,127.0.0.1, 409600.000, 0.361/00.00, 1, 0.453, 10000.000, 0.074, 0.068, 10000.000, 0.310, 1.043, 44/112 | |
/var/lib/kafka/data-0/kafka-log0, DEAD/ DEAD, 11/28 | |
/var/lib/kafka/data-1/kafka-log0, 0.050/00.00, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Copyright Strimzi authors. | |
* License: Apache License 2.0 (see the file LICENSE or http://apache.org/licenses/LICENSE-2.0.html). | |
*/ | |
package io.strimzi.operator.cluster.operator.assembly; | |
import io.fabric8.kubernetes.api.model.ConfigMap; | |
import io.fabric8.kubernetes.api.model.PersistentVolumeClaim; | |
import io.fabric8.kubernetes.api.model.PersistentVolumeClaimBuilder; | |
import io.fabric8.kubernetes.api.model.Secret; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package io.strimzi.operator.cluster.operator.resource; | |
import io.fabric8.kubernetes.api.model.Quantity; | |
import io.fabric8.kubernetes.api.model.ResourceRequirementsBuilder; | |
import io.fabric8.kubernetes.api.model.Secret; | |
import io.strimzi.api.kafka.model.kafka.Kafka; | |
import io.strimzi.api.kafka.model.kafka.KafkaBuilder; | |
import io.strimzi.api.kafka.model.kafka.KafkaResources; | |
import io.strimzi.api.kafka.model.kafka.KafkaStatus; | |
import io.strimzi.api.kafka.model.kafka.PersistentClaimStorageBuilder; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
srawat@srawat-mac drain-cleaner % make all | |
echo "Packaging project ..." | |
Packaging project ... | |
mvn -Pnative "-Dquarkus.native.container-build=true" package | |
[INFO] Scanning for projects... | |
[INFO] | |
[INFO] ------------------< io.strimzi:strimzi-drain-cleaner >------------------ | |
[INFO] Building strimzi-drain-cleaner 0.2.0 | |
[INFO] --------------------------------[ jar ]--------------------------------- | |
[INFO] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import com.fasterxml.jackson.annotation.JsonInclude; | |
import com.fasterxml.jackson.annotation.JsonProperty; | |
import com.fasterxml.jackson.annotation.JsonPropertyOrder; | |
import com.fasterxml.jackson.annotation.JsonTypeInfo; | |
import com.fasterxml.jackson.databind.JsonNode; | |
import com.fasterxml.jackson.databind.ObjectMapper; | |
import com.fasterxml.jackson.databind.node.ArrayNode; | |
import com.fasterxml.jackson.databind.node.JsonNodeFactory; | |
import com.fasterxml.jackson.databind.node.ObjectNode; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Test | |
public void testScaleDownWithPartitionReplicasAndEnabledBrokerCheck(VertxTestContext context) { | |
Kafka patchKafka = new KafkaBuilder(KAFKA) | |
.editMetadata() | |
.addToAnnotations(Map.of(ANNO_STRIMZI_IO_BYPASS_BROKER_SCALEDOWN_CHECK, "false")) | |
.endMetadata() | |
.build(); | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function canReachDestination(trackLength, spells, k) { | |
let currentSpeed = 0; | |
let timeTaken = 0; | |
for (const spell of spells) { | |
currentSpeed = Math.min(k, spell); // Set the current speed to either k or the spell's speed, whichever is smaller | |
timeTaken += 1; | |
const remainingDistance = trackLength - timeTaken * currentSpeed; | |
if (remainingDistance <= 0) { | |
return true; |
NewerOlder