congbobo184 commented on issue #5503: [Schema]GenericData$Record cannot be cast 
URL: https://github.com/apache/pulsar/issues/5503#issuecomment-548220863
 
 
   ```
                       "    \"name\": \"Test\",\n" +
                       "    \"fields\": [\n" +
                       "      {\n" +
                       "        \"name\": \"id\",\n" +
                       "        \"type\": [\n" +
                       "          \"null\",\n" +
                       "          \"int\"\n" +
                       "        ]\n" +
                       "      },\n" +
                       "      {\n" +
                       "        \"name\": \"name\",\n" +
                       "        \"type\": [\n" +
                       "          \"null\",\n" +
                       "          \"string\"\n" +
                       "        ]\n" +
                       "      }\n" +
                       "    ]\n" +
                       "  }
   ```
   you should change the name to Foo2 and add the namespace,  like
   ```
   ReflectData.get().getSchema(Foo2.class).toString(). 
   ```
   the namespace like this output

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to