protected Map<String, String> getLabelsWithName(String name) { return labels.withName(name).toMap(); }
protected Map<String, String> getSelectorLabels() { return labels.withName(name).strimziLabels().toMap(); }
protected Map<String, String> getLabelsWithName(String name, Map<String, String> userLabels) { return labels.withName(name).withUserLabels(userLabels).toMap(); }
public Future<ReconcileResult<Pod>> deletePod(String namespace, String name) { Labels labels = Labels.fromMap(null).withName(name); String podName = podOperations.list(namespace, labels).get(0).getMetadata().getName(); return podOperations.reconcile(namespace, podName, null); }
private final Future<CompositeFuture> deleteKafka(Reconciliation reconciliation) { String namespace = reconciliation.namespace(); String name = reconciliation.name(); String kafkaSsName = KafkaCluster.kafkaClusterName(name); Labels pvcSelector = Labels.forCluster(name).withKind(Kafka.RESOURCE_KIND).withName(kafkaSsName); return deletePersistentVolumeClaim(namespace, pvcSelector); }
private final Future<CompositeFuture> deleteZk(Reconciliation reconciliation) { String namespace = reconciliation.namespace(); String name = reconciliation.name(); String zkSsName = ZookeeperCluster.zookeeperClusterName(name); Labels pvcSelector = Labels.forCluster(name).withKind(Kafka.RESOURCE_KIND).withName(zkSsName); return deletePersistentVolumeClaim(namespace, pvcSelector); }
Labels.forCluster(ssLabels.get(Labels.STRIMZI_CLUSTER_LABEL)) .withKind(ssLabels.get(Labels.STRIMZI_KIND_LABEL)) .withName(name); List<PersistentVolumeClaim> pvcs = pvcOperations.list(namespace, pvcSelector); List<Future> result = new ArrayList<>();