Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for Kafka 2.6.0 #1769

Merged
merged 1 commit into from Aug 5, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Expand Up @@ -10,7 +10,7 @@ jobs:
fail-fast: false
matrix:
go-version: [1.14.x]
kafka-version: [2.4.1, 2.5.0]
kafka-version: [2.4.1, 2.6.0]
platform: [ubuntu-latest]

env:
Expand Down Expand Up @@ -41,7 +41,7 @@ jobs:

- name: Install dependencies
run: |
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.27.0
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.30.0
export REPOSITORY_ROOT=${GITHUB_WORKSPACE}
- name: Run test suite
Expand Down
4 changes: 3 additions & 1 deletion .golangci.yml
Expand Up @@ -66,10 +66,12 @@ linters:
- varcheck
- whitespace
# - goconst
# - gochecknoinits
- gochecknoinits

issues:
exclude:
- consider giving a name to these results
- include an explanation for nolint directive
- Potential Integer overflow made by strconv.Atoi result conversion to int16/32
- Use of weak random number generator
- TLS MinVersion too low
2 changes: 1 addition & 1 deletion README.md
Expand Up @@ -20,7 +20,7 @@ You might also want to look at the [Frequently Asked Questions](https://github.c
Sarama provides a "2 releases + 2 months" compatibility guarantee: we support
the two latest stable releases of Kafka and Go, and we provide a two month
grace period for older releases. This means we currently officially support
Go 1.12 through 1.14, and Kafka 2.3 through 2.5, although older releases are
Go 1.13 through 1.14, and Kafka 2.4 through 2.6, although older releases are
still likely to work.

Sarama follows semantic versioning and provides API stability via the gopkg.in service.
Expand Down
2 changes: 1 addition & 1 deletion functional_test.go
Expand Up @@ -119,7 +119,7 @@ func prepareDockerTestEnvironment(ctx context.Context, env *testEnvironment) err
// found here: https://docs.confluent.io/current/installation/versions-interoperability.html
var confluentPlatformVersion string
switch env.KafkaVersion {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Need to remember to bump confluentPlatformVersion to 5.6 once images from that are available I guess. Probably worth opening a backlog issue so we don’t forget.

I did also wonder if we should move to strimzi/kafka for our CI image

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see that we use a mix of confluent-oss and wurstmeister/kafka internally on CI. /cc @d1egoaz

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

either should work, 🤷 ideally, we should only use one flavour

case "2.5.0":
case "2.6.0":
confluentPlatformVersion = "5.5.0"
case "2.4.1":
confluentPlatformVersion = "5.4.2"
Expand Down
4 changes: 3 additions & 1 deletion utils.go
Expand Up @@ -161,6 +161,7 @@ var (
V2_3_0_0 = newKafkaVersion(2, 3, 0, 0)
V2_4_0_0 = newKafkaVersion(2, 4, 0, 0)
V2_5_0_0 = newKafkaVersion(2, 5, 0, 0)
V2_6_0_0 = newKafkaVersion(2, 6, 0, 0)

SupportedVersions = []KafkaVersion{
V0_8_2_0,
Expand All @@ -187,9 +188,10 @@ var (
V2_3_0_0,
V2_4_0_0,
V2_5_0_0,
V2_6_0_0,
}
MinVersion = V0_8_2_0
MaxVersion = V2_5_0_0
MaxVersion = V2_6_0_0
)

//ParseKafkaVersion parses and returns kafka version or error from a string
Expand Down