Home | About | Sematext search-lucene.com search-hadoop.com
 Search Hadoop and all its subprojects:

Switch to Threaded View
Kafka >> mail # user >> Kafka 0.8 Maven and IntelliJ


Copy link to this message
-
Re: Kafka 0.8 Maven and IntelliJ
Does anybody on the Kafka team have any insight into this issue? I'm
stuck, so any help is very much appreciated.

Thanks!

Florin

On 8/7/13 12:07 AM, "Florin Trofin" <[EMAIL PROTECTED]> wrote:

>An update on this issue: I still can't build the 0.8 branch using Maven.
>My automated build system uses Maven, so I need to get this working. Here
>are my steps:
>
>- Get the latest version of 0.8:
>
>> git clone https://git-wip-us.apache.org/repos/asf/kafka.git kafka
>> cd kafka
>> git checkout -b 0.8 remotes/origin/0.8
>> git fetch
>
>- Generate POM from sbt:
>
>> cd kafka
>> ./sbt update
>> ./sbt make-pom
>
>- Rename POM and copy to correct location???
>
>> cd core
>> cp target/scala-2.8.0/kafka_2.8.0-0.8.0-beta1.pom pom.xml
>> mvn package
>
>At this point I get build errors because of log4j:
>
>[INFO] Building kafka
>[INFO]    task-segment: [package]
>[INFO]
>------------------------------------------------------------------------
>[INFO] [remote-resources:process {execution: default}]
>Downloading:
>https://oss.sonatype.org/content/groups/public/org/scalatest//com/sun/jdmk
>/jmxtools/1.2.1/jmxtools-1.2.1.jar
>Downloading:
>https://oss.sonatype.org/content/groups/public/org/scalatest//com/sun/jmx/
>jmxri/1.2.1/jmxri-1.2.1.jar
>[INFO] Unable to find resource 'com.sun.jdmk:jmxtools:jar:1.2.1' in
>repository SonaTypeScalaTestrepo
>(https://oss.sonatype.org/content/groups/public/org/scalatest/)
>Downloading:
>https://maven-repository.dev.java.net/nonav/repository/com.sun.jdmk/jars/j
>mxtools-1.2.1.jar
>[INFO] Unable to find resource 'com.sun.jmx:jmxri:jar:1.2.1' in
>repository SonaTypeScalaTestrepo
>(https://oss.sonatype.org/content/groups/public/org/scalatest/)
>Downloading:
>https://maven-repository.dev.java.net/nonav/repository/com.sun.jmx/jars/jm
>xri-1.2.1.jar
>[WARNING] Unable to get resource 'com.sun.jmx:jmxri:jar:1.2.1' from
>repository java.net
>(https://maven-repository.dev.java.net/nonav/repository): Error
>transferring file: maven-repository.dev.java.net
>[WARNING] Unable to get resource 'com.sun.jdmk:jmxtools:jar:1.2.1' from
>repository java.net
>(https://maven-repository.dev.java.net/nonav/repository): Error
>transferring file: maven-repository.dev.java.net
>Downloading:
>http://repo1.maven.org/maven2/com/sun/jmx/jmxri/1.2.1/jmxri-1.2.1.jar
>Downloading:
>http://repo1.maven.org/maven2/com/sun/jdmk/jmxtools/1.2.1/jmxtools-1.2.1.j
>ar
>[INFO] Unable to find resource 'com.sun.jmx:jmxri:jar:1.2.1' in
>repository central (http://repo1.maven.org/maven2)
>[INFO] Unable to find resource 'com.sun.jdmk:jmxtools:jar:1.2.1' in
>repository central (http://repo1.maven.org/maven2)
>[INFO]
>------------------------------------------------------------------------
>[ERROR] BUILD ERROR
>[INFO]
>------------------------------------------------------------------------
>[INFO] Failed to resolve dependencies for one or more projects in the
>reactor. Reason: Missing:
>----------
>1) com.sun.jmx:jmxri:jar:1.2.1
>
>  Try downloading the file manually from the project website.
>
>  Then, install it using the command:
>      mvn install:install-file -DgroupId=com.sun.jmx -DartifactId=jmxri
>-Dversion=1.2.1 -Dpackaging=jar -Dfile=/path/to/file
>
>  Alternatively, if you host your own repository you can deploy the file
>there:
>      mvn deploy:deploy-file -DgroupId=com.sun.jmx -DartifactId=jmxri
>-Dversion=1.2.1 -Dpackaging=jar -Dfile=/path/to/file -Durl=[url]
>-DrepositoryId=[id]
>
>  Path to dependency:
>   1) org.apache.kafka:kafka_2.8.0:jar:0.8.0-beta1
>   2) log4j:log4j:jar:1.2.15
>   3) com.sun.jmx:jmxri:jar:1.2.1
>
>2) com.sun.jdmk:jmxtools:jar:1.2.1
>
>[Š]
>
>- I hand-edit the pom.xml and change the version of log4j from 1.2.15 to
>1.2.16 (apparently this was still not fixed)
>
>Now the "mvn package" command apparently succeeds but the generated jar
>is empty (only manifests in it):
>
>[INFO] [jar:jar {execution: default-jar}]
>[INFO] Building jar:
>/home/ftrofin/kafka/core/target/kafka_2.8.0-0.8.0-beta1.jar
>[INFO]
>-----------