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

Hong Tang commented on AVRO-12:
-------------------------------

Here is the unit test that can reproduce the error (add the code in 
TestSchema.java):

{code}
  public void testRecursive2() throws Exception {
    String jsonSchema =
        "{\"type\": \"record\", \"name\": \"Node\", \"fields\": {"
            + "\"label\": \"string\","
            + "\"children\": {\"type\": \"array\", \"items\": \"Node\" }}}";
    Schema s1 = Schema.parse(jsonSchema);
    Schema s2 = Schema.parse(jsonSchema);
    assertEquals(s1, s2);
  }
{code}

> Bug in comparison of recurisive schemas
> ---------------------------------------
>
>                 Key: AVRO-12
>                 URL: https://issues.apache.org/jira/browse/AVRO-12
>             Project: Avro
>          Issue Type: Bug
>          Components: java
>    Affects Versions: 1.0
>            Reporter: Hong Tang
>             Fix For: 1.0
>
>
> Comparison of recursive schema will lead to infinite recursion (eventually 
> leading to java.lang.StackOverflowError.)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to