You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@kafka.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2017/05/16 21:09:04 UTC

[jira] [Commented] (KAFKA-5229) Reflections logs excessive warnings when scanning classpaths

    [ https://issues.apache.org/jira/browse/KAFKA-5229?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16013114#comment-16013114 ] 

ASF GitHub Bot commented on KAFKA-5229:
---------------------------------------

GitHub user bharatviswa504 opened a pull request:

    https://github.com/apache/kafka/pull/3072

    KAFKA-5229:Reflections logs excessive warnings when scanning classpaths

    changed the reflections log level to ERROR.
    And tested it, now the warning logs are not shown up during the start of Kafka connect.
    @ewencp could you please review the changes.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/bharatviswa504/kafka KAFKA-5229

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/kafka/pull/3072.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #3072
    
----
commit aa18ca9e652c72e2d4ebb77b41e54dbcc40de4e7
Author: Bharat Viswanadham <bh...@us.ibm.com>
Date:   2017-05-16T21:07:03Z

    KAFKA-5229:Reflections logs excessive warnings when scanning classpaths

----


> Reflections logs excessive warnings when scanning classpaths
> ------------------------------------------------------------
>
>                 Key: KAFKA-5229
>                 URL: https://issues.apache.org/jira/browse/KAFKA-5229
>             Project: Kafka
>          Issue Type: Bug
>          Components: KafkaConnect
>    Affects Versions: 0.10.0.0, 0.10.0.1, 0.10.1.0, 0.10.1.1, 0.10.2.0, 0.10.2.1
>            Reporter: Ewen Cheslack-Postava
>            Assignee: Bharat Viswanadham
>            Priority: Minor
>              Labels: newbie
>
> We use Reflections to scan the classpath for available plugins (connectors, converters, transformations), but when doing so Reflections tends to generate a lot of log noise like this:
> {code}
> [2017-05-12 14:59:48,224] WARN could not get type for name org.jboss.netty.channel.SimpleChannelHandler from any class loader (org.reflections.Reflections:396)
> org.reflections.ReflectionsException: could not get type for name org.jboss.netty.channel.SimpleChannelHandler
> 	at org.reflections.ReflectionUtils.forName(ReflectionUtils.java:390)
> 	at org.reflections.Reflections.expandSuperTypes(Reflections.java:381)
> 	at org.reflections.Reflections.<init>(Reflections.java:126)
> 	at org.apache.kafka.connect.runtime.PluginDiscovery.scanClasspathForPlugins(PluginDiscovery.java:68)
> 	at org.apache.kafka.connect.runtime.AbstractHerder$1.run(AbstractHerder.java:391)
> 	at java.lang.Thread.run(Thread.java:745)
> Caused by: java.lang.ClassNotFoundException: org.jboss.netty.channel.SimpleChannelHandler
> 	at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
> 	at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
> 	at java.security.AccessController.doPrivileged(Native Method)
> 	at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
> 	at java.lang.ClassLoader.loadClass(ClassLoader.java:425)
> 	at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
> 	at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
> 	at org.reflections.ReflectionUtils.forName(ReflectionUtils.java:388)
> 	... 5 more
> {code}
> Despite being benign, these warnings worry users, especially first time users.
> We should either a) see if we can get Reflections to turn off these specific warnings via some config or b) make Reflections only log at > WARN by default in our log4j config. (b) is probably safe since we should only be seeing these at startup and I don't think I've seen any actual issue logged at WARN.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)