mathworks-ref-arch / matlab-avro

MATLAB interface for Apache Avro files.
Other
9 stars 2 forks source link

SLF4J: Class path contains multiple SLF4J bindings #1

Closed astroSimo closed 4 years ago

astroSimo commented 4 years ago

Hi,

I am trying to get this to work on R2018b. I've gone through all the steps and placed the correct matlab-avro-sdk-0.2.jar full path into the javaclasspath.txt.

However when running the example

data = randn(1e2,5); avrowrite('tmp.avro', data);

I get the following error message: SLF4J: Class path contains multiple SLF4J bindings. SLF4J: Found binding in [jar:file:/usr/local/MATLAB/R2018b/java/jarext/slf4j/slf4j-log4j12.jar!/org/slf4j/impl/StaticLoggerBinder.class] SLF4J: Found binding in [jar:file:/mnt/Work/main/toolbox/AVRO/Software/MATLAB/lib/jar/matlab-avro-sdk-0.2.jar!/org/slf4j/impl/StaticLoggerBinder.class] SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.

It appears the two bindings cannot work together. I tried to remove the slf4j-log4j12.jar but this resulted in other problems. Is there a way to get around this?

Thanks Simo

asollander commented 4 years ago

Hi Simo, this is an unfortunate double binding of the logger, and we see it too. As far as I can tell, the message will only occur once, and it will not impair your working with the Avro package.

Would you mind trying this, e.g. doing another read, another write, etc., and see if the message only pops up once in your command window.

Thanks, Anders

astroSimo commented 4 years ago

Hi Anders,

Yes that works, thanks! Now to get my head around understanding avro schemas! :)

Simo