Kafka
  1. Kafka
  2. KAFKA-981

Unable to pull Kafka binaries with Ivy

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 0.8.0
    • Fix Version/s: None
    • Component/s: packaging
    • Labels:
      None

      Description

      I am trying to pull the published Kafka binary with a simple Ivy file.

      <dependency org="org.apache.kafka" name="kafka_2.9.2" rev="0.8.0-beta1" conf="default->default"/>

      I get the following exception: [ivy:resolve] problem occurred while resolving dependency: org.apache.kafka#kafka_2.9.2;0.8.0-beta1

      {default=[default]}

      with main: java.lang.IllegalArgumentException: null name not allowed

      1. ivy.xml
        0.3 kB
        David Arthur
      2. ant.log
        16 kB
        David Arthur

        Activity

        Hide
        Joe Stein added a comment -
        Show
        Joe Stein added a comment - See KAFKA-1018
        Hide
        Joe Stein added a comment -

        Next release, yes

        Show
        Joe Stein added a comment - Next release, yes
        Hide
        Paul Doran added a comment -

        Just started investigating Kafka and hit the invalid Maven Central pom as well. I've used the Apache repo in my Gradle build and it works fine.

        When will this get fixed in Maven Central? With the next release?

        Thanks!

        Show
        Paul Doran added a comment - Just started investigating Kafka and hit the invalid Maven Central pom as well. I've used the Apache repo in my Gradle build and it works fine. When will this get fixed in Maven Central? With the next release? Thanks!
        Hide
        David Arthur added a comment -

        Bump. We really should get the invalid pom out of Maven Central, it's affecting a lot of people. I'm not 100% sure, but I think once a release has been signed/published it is immutable. We probably need to delete beta1 and create beta2

        Thoughts?

        Show
        David Arthur added a comment - Bump. We really should get the invalid pom out of Maven Central, it's affecting a lot of people. I'm not 100% sure, but I think once a release has been signed/published it is immutable. We probably need to delete beta1 and create beta2 Thoughts?
        Hide
        David Arthur added a comment -

        Joe Stein, ah yes - that pesky "released versions are immutable" thing. Changing Ivy to pull from Apache's repo did the trick.

        BTW, I debugged and stepped through Ivy during that error and it was failing on the bad part of the XML (the ivy <dependency/> elements). So it was definitely caused by the invalid pom.xml.

        Now I'm getting failure to resolve "com.sun.jdmk" nonsense, but I can deal with that.

        Should there be a beta2 release to fix this issue in Maven central?

        Show
        David Arthur added a comment - Joe Stein , ah yes - that pesky "released versions are immutable" thing. Changing Ivy to pull from Apache's repo did the trick. BTW, I debugged and stepped through Ivy during that error and it was failing on the bad part of the XML (the ivy <dependency/> elements). So it was definitely caused by the invalid pom.xml. Now I'm getting failure to resolve "com.sun.jdmk" nonsense, but I can deal with that. Should there be a beta2 release to fix this issue in Maven central?
        Hide
        Joe Stein added a comment -

        The first dependency section you see is only from maven central http://repo1.maven.org/maven2/org/apache/kafka/kafka_2.9.2/0.8.0-beta1/kafka_2.9.2-0.8.0-beta1.pom its not there in https://repository.apache.org/content/repositories/releases/org/apache/kafka/kafka_2.9.2/0.8.0-beta1/kafka_2.9.2-0.8.0-beta1.pom which I believe is due to me posting the release more than once with making pom changes that did not bump the version in order to get things to work and through https://issues.apache.org/jira/browse/KAFKA-974

        I don't know if that is what is causing the error but looking at the source here https://svn.apache.org/repos/asf/ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/id/ModuleId.java that error is because the name of the module is coming in as null, which is odd.

        Can you try to override the repository to use https://repository.apache.org/content/repositories/releases instead to see if it works as expected it has resolved other issues folks have brought up.

        Show
        Joe Stein added a comment - The first dependency section you see is only from maven central http://repo1.maven.org/maven2/org/apache/kafka/kafka_2.9.2/0.8.0-beta1/kafka_2.9.2-0.8.0-beta1.pom its not there in https://repository.apache.org/content/repositories/releases/org/apache/kafka/kafka_2.9.2/0.8.0-beta1/kafka_2.9.2-0.8.0-beta1.pom which I believe is due to me posting the release more than once with making pom changes that did not bump the version in order to get things to work and through https://issues.apache.org/jira/browse/KAFKA-974 I don't know if that is what is causing the error but looking at the source here https://svn.apache.org/repos/asf/ant/ivy/core/trunk/src/java/org/apache/ivy/core/module/id/ModuleId.java that error is because the name of the module is coming in as null, which is odd. Can you try to override the repository to use https://repository.apache.org/content/repositories/releases instead to see if it works as expected it has resolved other issues folks have brought up.
        Hide
        David Arthur added a comment -

        Looking closer at the pom.xml, I see two <dependencies> sections. One of which looks like a copy/paste error from ivy.xml, the other looks like normal Maven pom dependencies. See https://gist.github.com/mumrah/6059092#file-pom-xml-L25 for what I'm talking about.

        Show
        David Arthur added a comment - Looking closer at the pom.xml, I see two <dependencies> sections. One of which looks like a copy/paste error from ivy.xml, the other looks like normal Maven pom dependencies. See https://gist.github.com/mumrah/6059092#file-pom-xml-L25 for what I'm talking about.
        Hide
        Jay Kreps added a comment -

        Joe any idea what this might be?

        Show
        Jay Kreps added a comment - Joe any idea what this might be?
        Hide
        David Arthur added a comment -

        For a full example, try cloning this repository and running "ant ivy"

        https://github.com/mumrah/trihug-kafka-demo

        I encountered this error when setting up this demo

        Show
        David Arthur added a comment - For a full example, try cloning this repository and running "ant ivy" https://github.com/mumrah/trihug-kafka-demo I encountered this error when setting up this demo
        Hide
        David Arthur added a comment -

        Also should note this is Ivy 2.3.0

        Show
        David Arthur added a comment - Also should note this is Ivy 2.3.0
        Hide
        David Arthur added a comment -

        Ivy descriptor file I used

        Show
        David Arthur added a comment - Ivy descriptor file I used
        Hide
        David Arthur added a comment -

        stdout log from Ant showing full exception

        Show
        David Arthur added a comment - stdout log from Ant showing full exception

          People

          • Assignee:
            Joe Stein
            Reporter:
            David Arthur
          • Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development