googleapis / googleapis/google-cloud-java

[sdk-platform-java] Improve handling of resource names that (errantly) omit any/all resource ID segments.

Đang mở
#12,526 0 bình luận 0 reaction 0 người được giao Xem trên GitHub
priority: p3 type: feature request
Ngôn ngữ chính
Java
Star
2.1k
Fork
1.2k
Merge trung bình
1 ngày 23 giờ
Pull request đã merge (30 ngày)
154

Mô tả

A `google.api.resource(_definition)` should have alternating collection ID and resource ID segments e.g. `books/{book}`. Singletons are a well-known exception to this. That said, if it is ever encountered that a resource is missing a resource ID segment e.g. `books/author`, then the generator, which currently throws an exception, should throw a detailed exception stating which resource is missing a resource ID segment.

http://yaqs/3643436287798542336 is an example case. It was not a straight forward debugging process based on the exception currently thrown, but would've been much easier if the generator had stated something along the lines of `"Resource Foo does not have any resource ID segments"`.

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.