mjsax commented on code in PR #17198: URL: https://github.com/apache/kafka/pull/17198#discussion_r1830432679
########## streams/streams-scala/src/test/scala/org/apache/kafka/streams/scala/kstream/KStreamTest.scala: ########## @@ -478,27 +479,51 @@ class KStreamTest extends TestDriver { assertEquals("my-name", joinNode.name()) } -// @nowarn -// @Test -// def testSettingNameOnTransform(): Unit = { -// class TestTransformer extends Transformer[String, String, KeyValue[String, String]] { -// override def init(context: ProcessorContext): Unit = {} -// -// override def transform(key: String, value: String): KeyValue[String, String] = -// new KeyValue(s"$key-transformed", s"$value-transformed") -// -// override def close(): Unit = {} -// } -// val builder = new StreamsBuilder() -// val sourceTopic = "source" -// val sinkTopic = "sink" -// -// val stream = builder.stream[String, String](sourceTopic) -// stream -// .transform(() => new TestTransformer, Named.as("my-name")) -// .to(sinkTopic) -// -// val transformNode = builder.build().describe().subtopologies().asScala.head.nodes().asScala.toList(1) -// assertEquals("my-name", transformNode.name()) -// } + @Test + def testSettingNameOnTransform(): Unit = { + val processorSupplier: ProcessorSupplier[String, String, String, String] = + new api.ProcessorSupplier[String, String, String, String] { Review Comment: Not sure why IntelliJ shows an error... given that `TestProcessor` is `api.Processor` I would expect IntelliJ to figure out that the lambda is `api.ProcessorSupplier` and resolve to the new `process(...)` overload... In any case, the build did pass, so it seem ok. Also, the old `process()` will be removed soon, too: https://github.com/apache/kafka/pull/17190 -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: jira-unsubscr...@kafka.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org