Jeffrey Sanda
Jeffrey Sanda

Reputation: 1

Cannot upload to Snowflake stage using Talend, NoSuchMethodError

I am using Talend to create a file and then upload it to a Snowflake stage prior to populating the database. I am successfully connecting, but this error is generated when I attempt to PUT the file:

Exception in thread "Thread-2" java.lang.NoSuchMethodError: org.apache.avro.Schema.getLogicalType()Lorg/apache/avro/LogicalType;
    at org.talend.daikon.avro.LogicalTypeUtils.isLogicalDate(LogicalTypeUtils.java:74)
    at org.talend.codegen.enforcer.IncomingSchemaEnforcer.put(IncomingSchemaEnforcer.java:446)
    at org.talend.codegen.enforcer.IncomingSchemaEnforcer.put(IncomingSchemaEnforcer.java:379)

My best guess is that the class used in Talend does not match the class used in Snowflake, but I may be wrong and don't know how to fix it even if I am right. How can I fix this error?

Upvotes: 0

Views: 378

Answers (1)

Nick White
Nick White

Reputation: 76

You probably have two or more versions of Avro jars on your class path and the version loaded is too old and doesn’t have LogicalType implemented. It looks like logical types came in around Avro v1.8.0.

https://issues.apache.org/jira/browse/AVRO-1497

Upvotes: 1

Related Questions