-
Notifications
You must be signed in to change notification settings - Fork 1.2k
upgrade kafka client library to 2.8.2 #5400
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
Changes from 4 commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,8 +17,8 @@ | |
|
||
package org.apache.openwhisk.core.monitoring.metrics | ||
|
||
import akka.kafka.testkit.scaladsl.{EmbeddedKafkaLike, ScalatestKafkaSpec} | ||
import net.manub.embeddedkafka.EmbeddedKafka | ||
import akka.kafka.testkit.scaladsl.ScalatestKafkaSpec | ||
import io.github.embeddedkafka.{EmbeddedKafka, EmbeddedKafkaConfig} | ||
import org.scalatest._ | ||
import org.scalatest.concurrent.{Eventually, IntegrationPatience, ScalaFutures} | ||
|
||
|
@@ -30,11 +30,25 @@ abstract class KafkaSpecBase | |
with ScalaFutures | ||
with FlatSpecLike | ||
with EmbeddedKafka | ||
with EmbeddedKafkaLike | ||
with IntegrationPatience | ||
with Eventually | ||
with EventsTestHelper { this: Suite => | ||
implicit val timeoutConfig: PatienceConfig = PatienceConfig(1.minute) | ||
implicit val timeoutConfig: PatienceConfig = PatienceConfig(5.minute) | ||
override val sleepAfterProduce: FiniteDuration = 10.seconds | ||
override protected val topicCreationTimeout = 60.seconds | ||
override protected val topicCreationTimeout = 120.seconds | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I am just curious if this is to apply different timeouts for topic creation and publishing timeout or if there was any case that topic creation takes more than 60s. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I've reverted the timeout changes I think it was just leftover from me trying to get the tests to work, but still think the topic creation needs to be the same timeout as produce timeout rather than the default of the test library which is 10s. also I've added the cve's to the description. for bug fixes it would be hard to cover here rather than just pointing to the kafka release notes between 2.4.0 and 2.8.2. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks! |
||
override protected val producerPublishTimeout: FiniteDuration = 60.seconds | ||
|
||
lazy implicit val embeddedKafkaConfig: EmbeddedKafkaConfig = EmbeddedKafkaConfig(kafkaPort, zooKeeperPort) | ||
|
||
override def bootstrapServers = s"localhost:${embeddedKafkaConfig.kafkaPort}" | ||
|
||
override def setUp(): Unit = { | ||
EmbeddedKafka.start()(embeddedKafkaConfig) | ||
super.setUp() | ||
} | ||
|
||
override def cleanUp(): Unit = { | ||
super.cleanUp() | ||
EmbeddedKafka.stop() | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
embedded kafka for the tests doesn't have a release for 2.8.2, but works against any 2.8.x version of the kafka client.