It looks like you are trying to connect to SASL Kafka broker? If that's
the case make sure you follow the 
dochttp://kafka.apache.org/documentation.html#security_jaas_client
to pass in JAAS config with the KafkaClient section to your
consumer. -Harsha
On Thu, Sep 20, 2018, at 8:31 AM, Sravanthi Gottam wrote:
> Hi Team,


>  


> I am facing the issue in creating the Kafka consumer. I am giving the
> jaas config file in the build path>  


>  


> 10:14:00,765 WARN  [org.springframework.web.context.support.Annotatio-
> nConfigWebApplicationContext] (ServerService Thread Pool -- 84)
> Exception encountered during context initialization - cancelling
> refresh attempt:
> _org.springframework.context.ApplicationContextException_: Failed to
> start bean 'org.springframework.kafka.config.internalKafkaListenerEnd-
> pointRegistry'; nested exception is
> _org.apache.kafka.common.KafkaException_: Failed to construct kafka
> consumer> 10:14:00,789 ERROR 
> [org.springframework.web.servlet.DispatcherServlet]
> (ServerService Thread Pool -- 84) Context initialization failed:
> _org.springframework.context.ApplicationContextException_: Failed to
> start bean 'org.springframework.kafka.config.internalKafkaListenerEnd-
> pointRegistry'; nested exception is
> _org.apache.kafka.common.KafkaException_: Failed to construct kafka
> consumer>        at 
> org.springframework.context.support.DefaultLifecycleProcess-
>        or.doStart(_DefaultLifecycleProcessor.java:176_) [spring-context-
>        4.3.3.RELEASE.jar:4.3.3.RELEASE]>        at 
> org.springframework.context.support.DefaultLifecycleProcess-
>        or.access$200(_DefaultLifecycleProcessor.java:51_) [spring-context-
>        4.3.3.RELEASE.jar:4.3.3.RELEASE]>        at 
> org.springframework.context.support.DefaultLifecycleProcess-
>        or$LifecycleGroup.start(_DefaultLifecycleProcessor.java:346_)
>        [spring-context-4.3.3.RELEASE.jar:4.3.3.RELEASE]>        at 
> org.springframework.context.support.DefaultLifecycleProcess-
>        or.startBeans(_DefaultLifecycleProcessor.java:149_) [spring-context-
>        4.3.3.RELEASE.jar:4.3.3.RELEASE]>  


> ... 24 more


> Caused by: _org.apache.kafka.common.KafkaException_:
> _java.lang.IllegalArgumentException_: No serviceName defined in either
> JAAS or Kafka config>        at 
> org.apache.kafka.common.network.SaslChannelBuilder.configur-
>        e(_SaslChannelBuilder.java:98_) [kafka-clients-0.11.0.0.jar:]>        
> at org.apache.kafka.common.network.ChannelBuilders.create(_Cha-
>        nnelBuilders.java:112_) [kafka-clients-0.11.0.0.jar:]>        at 
> org.apache.kafka.common.network.ChannelBuilders.clientChann-
>        elBuilder(_ChannelBuilders.java:58_) [kafka-clients-
>        0.11.0.0.jar:]>        at 
> org.apache.kafka.clients.ClientUtils.createChannelBuilder(_-
>        ClientUtils.java:88_) [kafka-clients-0.11.0.0.jar:]>        at 
> org.apache.kafka.clients.consumer.KafkaConsumer.<init>(_Kaf-
>        kaConsumer.java:695_) [kafka-clients-0.11.0.0.jar:]>        ... 36 more


> Caused by: _java.lang.IllegalArgumentException_: No serviceName
> defined in either JAAS or Kafka config>        at 
> org.apache.kafka.common.security.kerberos.KerberosLogin.get-
>        ServiceName(_KerberosLogin.java:298_) [kafka-clients-
>        0.11.0.0.jar:]>        at 
> org.apache.kafka.common.security.kerberos.KerberosLogin.con-
>        figure(_KerberosLogin.java:87_) [kafka-clients-0.11.0.0.jar:]>        
> at org.apache.kafka.common.security.authenticator.LoginManager-
>        .<init>(_LoginManager.java:49_) [kafka-clients-0.11.0.0.jar:]>        
> at org.apache.kafka.common.security.authenticator.LoginManager-
>        .acquireLoginManager(_LoginManager.java:73_) [kafka-clients-
>        0.11.0.0.jar:]>        at 
> org.apache.kafka.common.network.SaslChannelBuilder.configur-
>        e(_SaslChannelBuilder.java:90_) [kafka-clients-0.11.0.0.jar:]>        
> ... 40 more


>  


>  


> Thanks,


> *Sravanthi Gottam*


> Medical Management Systems


>  


> Centene logo


> 7930 Clayton Rd | St Louis, MO 63117


> Ext: 8099453


> _Sravanthi.gottam@centene.com_


>  


> CONFIDENTIALITY NOTICE: This communication contains information
> intended for the use of the individuals to whom it is addressed and
> may contain information that is privileged, confidential or exempt
> from other disclosure under applicable law. If you are not the
> intended recipient, you are notified that any disclosure, printing,
> copying, distribution or use of the contents is prohibited. If you
> have received this in error, please notify the sender immediately by
> telephone or by returning it by return mail and then permanently
> delete the communication from your system. Thank you.

Reply via email to