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

ASF subversion and git services commented on AVRO-4078:
-------------------------------------------------------

Commit f514b34a66f610fc7e9d255076c036a98de0674e in avro's branch 
refs/heads/avro-4078-test-case from Martin Tzvetanov Grigorov
[ https://gitbox.apache.org/repos/asf?p=avro.git;h=f514b34a6 ]

AVRO-4078: Update the namespace for FullName

Now the test hangs while trying to initialize the static field READER$
and WRITER$

Signed-off-by: Martin Tzvetanov Grigorov <[email protected]>


> RecursiveUpdate error loading schema 
> -------------------------------------
>
>                 Key: AVRO-4078
>                 URL: https://issues.apache.org/jira/browse/AVRO-4078
>             Project: Apache Avro
>          Issue Type: Bug
>          Components: java
>    Affects Versions: 1.11.3
>         Environment: java version 11
> avro version 1.11.4 and 1.11.3
>  
>            Reporter: prashant sharma
>            Priority: Major
>              Labels: pull-request-available
>          Time Spent: 40m
>  Remaining Estimate: 0h
>
> I think there is an issue in avro versions (1.10+) onwards caused by MapUtil 
> class
> ([https://github.com/apache/avro/blob/main/lang/java/avro/src/main/java/org/apache/avro/util/MapUtil.java])
>  
>  [https://github.com/pacificmist0900/avro] 
> Expected no exception to be thrown, but got 
> 'java.lang.ExceptionInInitializerError'
>  
> Caused by: java.lang.ExceptionInInitializerError
> at java.base/java.lang.Class.forName(Class.java:398)
> at org.apache.avro.util.ClassUtils.forName(ClassUtils.java:95)
> at org.apache.avro.util.ClassUtils.forName(ClassUtils.java:72)
> at 
> org.apache.avro.specific.SpecificData.lambda$getClass$2(SpecificData.java:259)
> at 
> java.base/java.util.concurrent.ConcurrentHashMap.computeIfAbsent(ConcurrentHashMap.java:1705)
> at org.apache.avro.util.MapUtil.computeIfAbsent(MapUtil.java:42)
> at org.apache.avro.specific.SpecificData.getClass(SpecificData.java:257)
> Caused by: java.lang.IllegalStateException: Recursive update
> at 
> java.base/java.util.concurrent.ConcurrentHashMap.computeIfAbsent(ConcurrentHashMap.java:1760)
> at org.apache.avro.util.MapUtil.computeIfAbsent(MapUtil.java:42)
> at org.apache.avro.specific.SpecificData.getClass(SpecificData.java:257)
> at org.apache.avro.specific.SpecificData.getForSchema(SpecificData.java:164)
> at 
> org.apache.avro.specific.SpecificDatumWriter.<init>(SpecificDatumWriter.java:47)
> ... 8 more
>  
> If I use avro version 1.9 (which doesn't have MapUtil) my test works.
>  
>  
> P.S - we are migrating our services(that uses kafka and avro schema) from 1.9 
> to 1.11.4 as there has been a critical vulnerability reported in avro 
> ([https://security.snyk.io/vuln/SNYK-JAVA-ORGAPACHEAVRO-8161188]) , But we 
> can't do it as avro 1.11.* fails for us due to above issue. 
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to