Skip to content

Instantly share code, notes, and snippets.

View converge's full-sized avatar

John Vanzuita converge

View GitHub Profile
Name: 23c4c041-03f8-421c-a31a-b057c0ba65a1
Namespace: <...>
Labels: kafka.eventing.knative.dev/metadata.kind=kafkasource
Annotations: internal.kafka.eventing.knative.dev/lastModifier: system:serviceaccount:knative-eventing:kafka-controller
API Version: internal.kafka.eventing.knative.dev/v1alpha1
Kind: ConsumerGroup
Metadata:
Creation Timestamp: 2024-02-09T15:45:30Z
Finalizers:
consumergroups.internal.kafka.eventing.knative.dev
{
"level": "info",
"ts": "2024-02-09T13:25:13.818Z",
"logger": "kafka-broker-controller",
"caller": "statefulset/autoscaler.go:136",
"msg": "Triggering scale down",
"commit": "e6b0021-dirty",
"knative.dev/pod": "kafka-controller-7cf5bb5cbd-tcsbt",
"component": "autoscaler",
"isLeader": true
piVersion: v1
items:
- apiVersion: keda.sh/v1alpha1
kind: ScaledObject
metadata:
annotations:
autoscaling.knative.dev/class: keda.autoscaling.knative.dev
scaledobject.keda.sh/transfer-hpa-ownership: "true"
creationTimestamp: "2024-02-09T13:07:20Z"
finalizers:
package main
import (
"context"
"fmt"
"sync"
"time"
)
func main() {
./hack/run.sh build-tests
/Users/converge/workspace/knative/eventing-kafka-broker/test/../vendor/knative.dev/hack/library.sh: line 28: KNATIVE_TESTS_PROJECT: readonly variable
/Users/converge/workspace/knative/eventing-kafka-broker/test/../vendor/knative.dev/hack/library.sh: line 39: IS_PROW: readonly variable
/Users/converge/workspace/knative/eventing-kafka-broker/test/../vendor/knative.dev/hack/library.sh: line 54: REPO_NAME: readonly variable
/Users/converge/workspace/knative/eventing-kafka-broker/test/../vendor/knative.dev/hack/library.sh: line 58: IS_LINUX: readonly variable
/Users/converge/workspace/knative/eventing-kafka-broker/test/../vendor/knative.dev/hack/library.sh: line 59: IS_OSX: readonly variable
/Users/converge/workspace/knative/eventing-kafka-broker/test/../vendor/knative.dev/hack/library.sh: line 60: IS_WINDOWS: readonly variable
/Users/converge/workspace/knative/eventing-kafka-broker/test/../vendor/knative.dev/hack/library.sh: line 62:
#!/bin/bash
# Replace 'your-namespace' with the actual namespace
namespace="keda"
# List of pods to check
pod_list=("keda-admission-9c44fd597-wtkcm")
while true; do
all_running=true # Flag to track if all pods are running
/*
This is a k6 test script that imports the xk6-kafka and
tests Kafka by sending 200 Avro messages per iteration
without any associated key.
*/
import {
Writer,
SchemaRegistry,
apiVersion: keda.sh/v1alpha1
kind: ScaledObject
metadata:
name: kafka-scaledobject
# namespace: my-events
annotations:
scaledobject.keda.sh/transfer-hpa-ownership: "true" # Optional. Use to transfer an existing HPA ownership to this ScaledObject
# autoscaling.keda.sh/paused-replicas: "0"
spec:
advanced: # Optional. Section to specify advanced options
package testing
import (
"context"
"fmt"
corev1 "k8s.io/api/core/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/apis/meta/v1/unstructured"
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachinery/pkg/runtime/schema"
/*
Copyright 2019 The Knative Authors
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software