Kafka Quickstart: What Dependencies do I need?

后端 未结 3 1782
不知归路
不知归路 2021-02-03 13:27

I am working through the kafka quickstart:

http://kafka.apache.org/07/quickstart.html

and the basic Consumer Group example:

https://cwiki.apache.org/conf

3条回答
  •  南方客
    南方客 (楼主)
    2021-02-03 14:17

    The problem is that kafka beta was built in a way that pom generated with a jar isn't valid and maven could not recognize it and parse properly, thus fetching transitive dependencies. We've managed to mitigate this problem by enlisting all of the dependencies from that pom (scala, zk, etc) in our pom definition. We're waiting for next beta builds of kafka, in which problem will be fixed.

    Full dependencies list is below. Note that you have to change scala version dependency accordingly to the postfix of your kafka artifact.

    
                org.scala-lang
                scala-library
                2.8.0
            
            
                log4j
                log4j
                1.2.15
                
                    
                        com.sun.jmx
                        jmxri
                    
                    
                        com.sun.jdmk
                        jmxtools
                    
                    
                        javax.jms
                        jms
                    
                
            
            
                net.sf.jopt-simple
                jopt-simple
                3.2
            
            
                org.slf4j
                slf4j-simple
                1.6.4
            
            
                org.scala-lang
                scala-compiler
                2.8.0
            
            
                com.101tec
                zkclient
                0.3
            
            
                com.yammer.metrics
                metrics-core
                2.2.0
            
            
                com.yammer.metrics
                metrics-annotation
                2.2.0
            
            
                org.easymock
                easymock
                3.0
                test
            
            
                org.scalatest
                scalatest
                1.2
                test
            
    

    As for the

    Maybe I should switch to Apache Active MQ. But that sounds less fun. Am I missing something?

    Well, don't you forget that this is the beta release? Some bad things are happening, indeed, but currently we're running kafka 0.7 without any efforts.

提交回复
热议问题