2

我用以下 web ui https://schema-registry-ui.landoop.com尝试了不同的东西

我似乎无法将以下内容放入注册表:

{
    "namespace": "test.avro",
    "type": "record",
    "name": "test",
    "fields": [
        {
            "name": "field1", 
            "type": "string" 
        },
        {
            "name": "field2",  
            "type": "record", 
            "fields":[
                {"name": "field1", "type": "string" },
                {"name": "field2",  "type": "string"},
                {"name": "intField", "type": "int"}
            ]
        }
    ]
}

此外,有没有办法从当前模式中引用另一个模式来创建复合/嵌套模式?

4

1 回答 1

0

看看这个例子

https://github.com/Landoop/schema-registry-ui/issues/43

您需要将架构定义为一个数组 - 第一个元素是嵌套记录,第二个元素是主 avro 记录

于 2017-05-10T15:39:05.190 回答