Skip to content

Commit 812c3f8

Browse files
authored
Update Strimzi Go API to 0.5.0 and Kroxy to 0.16.0 (#12)
Signed-off-by: Jakub Scholz <www@scholzj.com>
1 parent e67e63d commit 812c3f8

File tree

11 files changed

+188
-214
lines changed

11 files changed

+188
-214
lines changed

README.md

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -7,23 +7,23 @@ _**Expose** your **Kafka** cluster outside your Minikube, Kind, or Docker Deskto
77
## What is Keksposé?
88

99
[Strimzi](https://strimzi.io) makes it easy to run [Apache Kafka](https://kafka.apache.org/) on Kubernetes.
10-
But using the Kafka cluster from applications running outside of your Kubernetes cluster can be [challenging](https://strimzi.io/blog/2019/04/17/accessing-kafka-part-1/).
10+
But using the Kafka cluster from applications running outside your Kubernetes cluster can be [challenging](https://strimzi.io/blog/2019/04/17/accessing-kafka-part-1/).
1111
Strimzi tries to make it as easy as possible and supports several different ways how to _expose_ the Kafka cluster:
1212
* Using Load Balancers
1313
* Using Node Ports
1414
* Using the Kubernetes Nginx Ingress controller
1515

1616
When running in production-grade Kubernetes environments, these usually work fine.
17-
But when using a local Kubernetes cluster such as Minikube, Kind or Docker Desktop, these mechanisms are often not well-supported:
17+
But when using a local Kubernetes cluster such as Minikube, Kind, or Docker Desktop, these mechanisms are often not well-supported:
1818
* The local clusters often lack proper support for load balancers
1919
* They often run inside additional virtual machines or containers and use complex networking so that node ports do not work out of the box
2020
* While Ingress usually works, the installation of the right Ingress controller and its configuration is often complicated
2121

2222
One of the ways how applications are often exposed from local clusters is using port forwarding with `kubectl port-foward`.
2323
But using port forwarding with Apache Kafka is not so simple because of its custom discovery protocol.
24-
You need to forward ports for each brokers in the Kafka cluster.
24+
You need to forward ports for each broker in the Kafka cluster.
2525
And you need to make sure your advertised hosts and ports are correctly configured to the local address.
26-
Keksposé makes it possible to use port forwarding with Apache Kafka with the help of [Kroxylicious](https://kroxylicious.io/) project that provides Kafka proxying capabilities.
26+
Keksposé makes it possible to use port forwarding with Apache Kafka with the help of the [Kroxylicious](https://kroxylicious.io/) project that provides Kafka proxying capabilities.
2727

2828
## How does it work?
2929

@@ -62,7 +62,7 @@ That allows it to provide native binaries to make it easier to run Keksposé.
6262

6363
### Installation
6464

65-
You can download one of the release binaries from one of the release and use it.
65+
You can download one of the release binaries from one of the releases and use it.
6666

6767
### Configuration
6868

@@ -78,24 +78,24 @@ Keksposé supports several parameters that can be used to configure it:
7878
| `--starting-port` / `-p` | The starting port number. This port number will be used for the bootstrap connection and will be used as the basis to calculate the per-broker ports. | `50000` |
7979
| `--kekspose-name` / `-k` | Name that will be used for the Keksposé ConfigMap and Pod. | `kekspose` |
8080
| `--timeout` / `-t` | Timeout for how long to wait for the Proxy Pod to become ready. In milliseconds. | `300000` |
81-
| `--proxy-image` / `-i` | Container image used for the proxy (must be based on a compatible Kroxylicious container image) | `ghcr.io/scholzj/kekspose:kroxylicious-0.13.0` |
81+
| `--proxy-image` / `-i` | Container image used for the proxy (must be based on a compatible Kroxylicious container image) | `ghcr.io/scholzj/kekspose:kroxylicious-0.16.0` |
8282

83-
If you are using the Keksposé binary, you can just pass the options from the command line.
83+
If you are using the Keksposé binary, you can pass the options from the command line.
8484

8585
## Frequently Asked Questions
8686

8787
### Does Keksposé support Kafka clusters with authentication?
8888

8989
Keksposé requires a listener without TLS encryption.
90-
But it supports Kafka clusters with SASL based authentication such as SCRAM-SHA or OAuth.
90+
But it supports Kafka clusters with SASL-based authentication, such as SCRAM-SHA or OAuth.
9191

9292
### What happens when I scale my Kafka cluster?
9393

9494
You might need to restart Keksposé after scaling up your Kafka cluster or changing the IDs of the Apache Kafka nodes.
9595

9696
### Does Keksposé support KRaft-based Apache Kafka clusters?
9797

98-
Keksposé supports Kraft-based Apache Kafka cluster.
98+
Keksposé supports a Kraft-based Apache Kafka cluster.
9999
However, it exposes the broker nodes only.
100100

101101
### What access rights do I need to run Keksposé?
@@ -107,13 +107,13 @@ Running Keksposé requires the following access rights to your Kubernetes cluste
107107

108108
### Does Keksposé work only with local Kubernetes clusters?
109109

110-
Keksposé was designed with focus on local Kubernetes environments such as Minikube, Kind, or Docker Desktop.
110+
Keksposé was designed with a focus on local Kubernetes environments such as Minikube, Kind, or Docker Desktop.
111111
But it can be used with any Kubernetes cluster regardless of how and where you run it.
112112

113113
### Can the same Kafka cluster be exposed to multiple users in parallel?
114114

115-
Any user that has access to the Kubernetes cluster and the necessary rights can expose it.
116-
But in order to be able to expose the Kafka cluster, Keksposé has to deploy the proxy into the Kubernetes cluster.
115+
Any user who has access to the Kubernetes cluster and the necessary rights can expose it.
116+
But to be able to expose the Kafka cluster, Keksposé has to deploy the proxy into the Kubernetes cluster.
117117
So if the same cluster should be exposed in parallel to multiple users, it is important that they each use their own value for the `--kekspose-name` option to make sure each user has a custom proxy instance.
118118

119119
### What does the name Keksposé mean?

cmd/root.go

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,10 @@ limitations under the License.
1717
package cmd
1818

1919
import (
20-
kekspose2 "github.com/scholzj/kekspose/pkg/kekspose"
2120
"os"
2221

22+
kekspose2 "github.com/scholzj/kekspose/pkg/kekspose"
23+
2324
"github.com/spf13/cobra"
2425
)
2526

@@ -75,7 +76,7 @@ func init() {
7576
rootCmd.Flags().StringVarP(&clusterName, "cluster-name", "c", "my-cluster", "Name of the Kafka cluster.")
7677
rootCmd.Flags().StringVarP(&listenerName, "listener-name", "l", "", "Name of the listener that should be exposed.")
7778
rootCmd.Flags().StringVarP(&keksposeName, "kekspose-name", "k", "kekspose", "Name that will be used for the Keksposé ConfigMap and Pod.")
78-
rootCmd.Flags().StringVarP(&proxyImage, "proxy-image", "i", "ghcr.io/scholzj/kekspose:kroxylicious-0.13.0", "Container image used for the proxy (must be based on a compatible Kroxylicious container image).")
79+
rootCmd.Flags().StringVarP(&proxyImage, "proxy-image", "i", "ghcr.io/scholzj/kekspose:kroxylicious-0.16.0", "Container image used for the proxy (must be based on a compatible Kroxylicious container image).")
7980
rootCmd.Flags().Uint16VarP(&startingPort, "starting-port", "p", 50000, "The starting port number. This port number will be used for the bootstrap connection and will be used as the basis to calculate the per-broker ports.")
8081
rootCmd.Flags().Uint32VarP(&timeout, "timeout", "t", 300000, "Timeout for how long to wait for the Proxy Pod to become ready. In milliseconds.")
8182
}

cmd/version.go

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1313
See the License for the specific language governing permissions and
1414
limitations under the License.
1515
*/
16+
1617
package cmd
1718

1819
import (
@@ -41,14 +42,4 @@ var versionCmd = &cobra.Command{
4142

4243
func init() {
4344
rootCmd.AddCommand(versionCmd)
44-
45-
// Here you will define your flags and configuration settings.
46-
47-
// Cobra supports Persistent Flags which will work for this command
48-
// and all subcommands, e.g.:
49-
// versionCmd.PersistentFlags().String("foo", "", "A help for foo")
50-
51-
// Cobra supports local flags which will only run when this command
52-
// is called directly, e.g.:
53-
// versionCmd.Flags().BoolP("toggle", "t", false, "Help message for toggle")
5445
}

go.mod

Lines changed: 41 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -3,57 +3,64 @@ module github.com/scholzj/kekspose
33
go 1.24.0
44

55
require (
6-
github.com/scholzj/strimzi-go v0.3.0
7-
github.com/spf13/cobra v1.9.1
8-
github.com/stretchr/testify v1.10.0
9-
k8s.io/api v0.33.0
10-
k8s.io/apimachinery v0.33.0
11-
k8s.io/client-go v0.33.0
6+
github.com/scholzj/strimzi-go v0.5.0
7+
github.com/spf13/cobra v1.10.1
8+
github.com/stretchr/testify v1.11.1
9+
k8s.io/api v0.34.1
10+
k8s.io/apimachinery v0.34.1
11+
k8s.io/client-go v0.34.1
1212
)
1313

1414
require (
1515
github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect
16-
github.com/emicklei/go-restful/v3 v3.12.2 // indirect
17-
github.com/fxamacker/cbor/v2 v2.8.0 // indirect
18-
github.com/go-logr/logr v1.4.2 // indirect
19-
github.com/go-openapi/jsonpointer v0.21.1 // indirect
20-
github.com/go-openapi/jsonreference v0.21.0 // indirect
21-
github.com/go-openapi/swag v0.23.1 // indirect
16+
github.com/emicklei/go-restful/v3 v3.13.0 // indirect
17+
github.com/fxamacker/cbor/v2 v2.9.0 // indirect
18+
github.com/go-logr/logr v1.4.3 // indirect
19+
github.com/go-openapi/jsonpointer v0.22.1 // indirect
20+
github.com/go-openapi/jsonreference v0.21.2 // indirect
21+
github.com/go-openapi/swag v0.25.1 // indirect
22+
github.com/go-openapi/swag/cmdutils v0.25.1 // indirect
23+
github.com/go-openapi/swag/conv v0.25.1 // indirect
24+
github.com/go-openapi/swag/fileutils v0.25.1 // indirect
25+
github.com/go-openapi/swag/jsonname v0.25.1 // indirect
26+
github.com/go-openapi/swag/jsonutils v0.25.1 // indirect
27+
github.com/go-openapi/swag/loading v0.25.1 // indirect
28+
github.com/go-openapi/swag/mangling v0.25.1 // indirect
29+
github.com/go-openapi/swag/netutils v0.25.1 // indirect
30+
github.com/go-openapi/swag/stringutils v0.25.1 // indirect
31+
github.com/go-openapi/swag/typeutils v0.25.1 // indirect
32+
github.com/go-openapi/swag/yamlutils v0.25.1 // indirect
2233
github.com/gogo/protobuf v1.3.2 // indirect
23-
github.com/golang/protobuf v1.5.4 // indirect
24-
github.com/google/gnostic-models v0.6.9 // indirect
25-
github.com/google/go-cmp v0.7.0 // indirect
26-
github.com/google/gofuzz v1.2.0 // indirect
34+
github.com/google/gnostic-models v0.7.0 // indirect
2735
github.com/google/uuid v1.6.0 // indirect
2836
github.com/gorilla/websocket v1.5.4-0.20250319132907-e064f32e3674 // indirect
2937
github.com/inconshreveable/mousetrap v1.1.0 // indirect
30-
github.com/josharian/intern v1.0.0 // indirect
3138
github.com/json-iterator/go v1.1.12 // indirect
32-
github.com/mailru/easyjson v0.9.0 // indirect
3339
github.com/moby/spdystream v0.5.0 // indirect
3440
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
35-
github.com/modern-go/reflect2 v1.0.2 // indirect
41+
github.com/modern-go/reflect2 v1.0.3-0.20250322232337-35a7c28c31ee // indirect
3642
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect
3743
github.com/mxk/go-flowrate v0.0.0-20140419014527-cca7078d478f // indirect
38-
github.com/pkg/errors v0.9.1 // indirect
3944
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect
40-
github.com/spf13/pflag v1.0.6 // indirect
45+
github.com/spf13/pflag v1.0.10 // indirect
4146
github.com/x448/float16 v0.8.4 // indirect
42-
golang.org/x/net v0.40.0 // indirect
43-
golang.org/x/oauth2 v0.30.0 // indirect
44-
golang.org/x/sys v0.33.0 // indirect
45-
golang.org/x/term v0.32.0 // indirect
46-
golang.org/x/text v0.25.0 // indirect
47-
golang.org/x/time v0.11.0 // indirect
48-
google.golang.org/protobuf v1.36.6 // indirect
49-
gopkg.in/evanphx/json-patch.v4 v4.12.0 // indirect
47+
go.yaml.in/yaml/v2 v2.4.3 // indirect
48+
go.yaml.in/yaml/v3 v3.0.4 // indirect
49+
golang.org/x/net v0.46.0 // indirect
50+
golang.org/x/oauth2 v0.32.0 // indirect
51+
golang.org/x/sys v0.37.0 // indirect
52+
golang.org/x/term v0.36.0 // indirect
53+
golang.org/x/text v0.30.0 // indirect
54+
golang.org/x/time v0.14.0 // indirect
55+
google.golang.org/protobuf v1.36.10 // indirect
56+
gopkg.in/evanphx/json-patch.v4 v4.13.0 // indirect
5057
gopkg.in/inf.v0 v0.9.1 // indirect
5158
gopkg.in/yaml.v3 v3.0.1 // indirect
5259
k8s.io/klog/v2 v2.130.1 // indirect
53-
k8s.io/kube-openapi v0.0.0-20250318190949-c8a335a9a2ff // indirect
54-
k8s.io/utils v0.0.0-20250502105355-0f33e8f1c979 // indirect
55-
sigs.k8s.io/json v0.0.0-20241014173422-cfa47c3a1cc8 // indirect
60+
k8s.io/kube-openapi v0.0.0-20250910181357-589584f1c912 // indirect
61+
k8s.io/utils v0.0.0-20251002143259-bc988d571ff4 // indirect
62+
sigs.k8s.io/json v0.0.0-20250730193827-2d320260d730 // indirect
5663
sigs.k8s.io/randfill v1.0.0 // indirect
57-
sigs.k8s.io/structured-merge-diff/v4 v4.7.0 // indirect
58-
sigs.k8s.io/yaml v1.4.0 // indirect
64+
sigs.k8s.io/structured-merge-diff/v6 v6.3.0 // indirect
65+
sigs.k8s.io/yaml v1.6.0 // indirect
5966
)

0 commit comments

Comments
 (0)