You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by "mberndt123 (via GitHub)" <gi...@apache.org> on 2024/01/20 17:59:09 UTC
[PR] streams-scala: remove collections-compat dependency when on Scala 2.13 [kafka]
mberndt123 opened a new pull request, #15239:
URL: https://github.com/apache/kafka/pull/15239
Hey there,
The motivation for this PR is that we're trying to migrate our codebase to Scala 3. Since Scala 3 is able to consume Scala 2.13 libraries, we can use the Scala 2.13 version of kafka-streams-scala, but that pulls in the scala-collections-compat_2.13 library as a dependency. Another one of our dependencies pulls in scala-collections-compat_3, and you can't have both on the classpath at the same time. Luckily this library is actually not required at all when compiling with Scala 2.13, so that dependency should just be removed.
--
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-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] streams-scala: remove collections-compat dependency when on Scala 2.13 [kafka]
Posted by "divijvaidya (via GitHub)" <gi...@apache.org>.
divijvaidya merged PR #15239:
URL: https://github.com/apache/kafka/pull/15239
--
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-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] streams-scala: remove collections-compat dependency when on Scala 2.13 [kafka]
Posted by "mberndt123 (via GitHub)" <gi...@apache.org>.
mberndt123 commented on PR #15239:
URL: https://github.com/apache/kafka/pull/15239#issuecomment-1932541985
> Do we want to remove it from streams only or also for core?
I've tried that and thought it worked because of a silly mistake that I made. But `core` actually needs it, so it needs to stay.
--
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-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] streams-scala: remove collections-compat dependency when on Scala 2.13 [kafka]
Posted by "jlprat (via GitHub)" <gi...@apache.org>.
jlprat commented on PR #15239:
URL: https://github.com/apache/kafka/pull/15239#issuecomment-1935630910
https://issues.apache.org/jira/browse/KAFKA-12895?focusedCommentId=17365016&page=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-17365016
This could be done when KIP-751 is done.
--
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-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] streams-scala: remove collections-compat dependency when on Scala 2.13 [kafka]
Posted by "mberndt123 (via GitHub)" <gi...@apache.org>.
mberndt123 commented on PR #15239:
URL: https://github.com/apache/kafka/pull/15239#issuecomment-1910629710
@divijvaidya
Thank you for your comments, please take another look.
--
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-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] streams-scala: remove collections-compat dependency when on Scala 2.13 [kafka]
Posted by "divijvaidya (via GitHub)" <gi...@apache.org>.
divijvaidya commented on code in PR #15239:
URL: https://github.com/apache/kafka/pull/15239#discussion_r1463080761
##########
build.gradle:
##########
@@ -2286,8 +2286,9 @@ project(':streams:streams-scala') {
api project(':streams')
api libs.scalaLibrary
- api libs.scalaCollectionCompat
-
+ if ( versions.baseScala == '2.12' ) {
+ api libs.scalaCollectionCompat
Review Comment:
Can you please add a comment here explaining the reason for this removal of dependency, basically, capture what you wrote in PR here. It helps the readers of the code understand why certain actions were taken.
--
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-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] streams-scala: remove collections-compat dependency when on Scala 2.13 [kafka]
Posted by "jlprat (via GitHub)" <gi...@apache.org>.
jlprat commented on PR #15239:
URL: https://github.com/apache/kafka/pull/15239#issuecomment-1935623714
> I've tried that and thought it worked because of a silly mistake that I made. But core actually needs it, so it needs to stay.
Correct, `core` needs the `compat` library as it works for both 2.12 and 2.13. Once 2.12 support is removed (in 4.0) we can refactor the 2.13 core and remove the `compat` library.
--
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-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org