googleapis / googleapis/google-cloud-java

[sdk-platform-java] Generator is not generating all the root level resources in the proto files

未关闭
#12,402 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
priority: p3 type: bug
主要语言
Java
星标
2.1k
派生
1.2k
平均合并
1 天 23 小时
30 天内合并 PR
157

描述

See [this](yaqs/4937742893109477376#n15) and the earlier comments in the thread for more context.

Given two top level resources added to the proto file:
```
option (google.api.resource_definition) = {
type: "service.googleapis.com/FolderLocation"
pattern: "folders/{folder}/locations/{location}"
};

option (google.api.resource_definition) = {
type: "service.googleapis.com/OrganizationLocation"
pattern: "organizations/{organization}/locations/{location}"
};
```
It seems to only generate a resource for FolderLocation as `FolderLocationName`.

These resource definitions are the parent to a child resource:
```
message ChildResource {
option (google.api.resource) = {
type: "service.googleapis.com/ChildResource"
pattern: "organizations/{organization}/locations/{location}/things/{thing}"
pattern: "folders/{folder}/locations/{location}/things/{thing}"
plural: "childResource"
singular: "childResource"
};
}
```

These should map properly to the the two top level resource definitions, but it only seems to map to one.

We need to investigate why only one of these resources is being created.

贡献指南

打开贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。