有没有使用过 https://github.com/google/gnostic/tree/main/cmd/protoc-gen-openapi 这个库的呢?有点问题想要咨询一下。官方提供的这个例子 https://github.com/google/gnostic/blob/main/cmd/protoc-gen-openapi/examples/tests/openapiv3annotations/message.proto ,如下所示
option (openapi.v3.document) = {
  info: {
    title: "Title from annotation";
    version: "Version from annotation";
    description: "Description from annotation";
    contact: {
      name: "Contact Name";
      url: "https://github.com/google/gnostic";
      email: "[email protected]";
    }
    license: {
      name: "Apache License";
      url: "https://github.com/google/gnostic/blob/master/LICENSE";
    }
  }
  components: {
    security_schemes: {
      additional_properties: [
        {
          name: "BasicAuth";
          value: {
            security_scheme: {
              type: "http";
              scheme: "basic";
            }
          }
        }
      ]
    }
  }
};
使用了 openapiv3.proto 的参数,官方提供的例子里生成的 openapi.yaml 文件是包含这些信息的,
info:
    title: Title from annotation
    description: Description from annotation
    contact:
        name: Contact Name
        url: https://github.com/google/gnostic
        email: [email protected]
    license:
        name: Apache License
        url: https://github.com/google/gnostic/blob/master/LICENSE
    version: Version from annotation
我在本地编译该 proto 文件却没有包含这个信息,有没有大佬帮忙解答一下,感谢🙏