Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion library_generation/generate_library.sh
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,12 @@ case "${proto_path}" in
removed_proto="google/rpc/http.proto"
proto_files="${proto_files//${removed_proto}/}"
;;
"google/shopping"*)
# this proto is included in //google/shopping/css/v1:google-cloud-shopping-css-v1-java
# and //google/shopping/merchant/inventories/v1beta:google-cloud-merchant-inventories-v1beta-java
# and //google/shopping/merchant/reports/v1beta:google-cloud-merchant-reports-v1beta-java
proto_files="${proto_files} google/shopping/type/types.proto"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we still need to include them here if these are included in java-common-protos?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some classes are missing in proto-* directory if google/shopping/type/types.proto is excluded.

deleted:    java-shopping-css/proto-google-shopping-css-v1/src/main/java/com/google/shopping/type/Channel.java
deleted:    java-shopping-css/proto-google-shopping-css-v1/src/main/java/com/google/shopping/type/ChannelOrBuilder.java
deleted:    java-shopping-css/proto-google-shopping-css-v1/src/main/java/com/google/shopping/type/CustomAttribute.java
deleted:    java-shopping-css/proto-google-shopping-css-v1/src/main/java/com/google/shopping/type/CustomAttributeOrBuilder.java
deleted:    java-shopping-css/proto-google-shopping-css-v1/src/main/java/com/google/shopping/type/Destination.java
deleted:    java-shopping-css/proto-google-shopping-css-v1/src/main/java/com/google/shopping/type/DestinationOrBuilder.java
deleted:    java-shopping-css/proto-google-shopping-css-v1/src/main/java/com/google/shopping/type/Price.java
deleted:    java-shopping-css/proto-google-shopping-css-v1/src/main/java/com/google/shopping/type/PriceOrBuilder.java
deleted:    java-shopping-css/proto-google-shopping-css-v1/src/main/java/com/google/shopping/type/ReportingContext.java
deleted:    java-shopping-css/proto-google-shopping-css-v1/src/main/java/com/google/shopping/type/ReportingContextOrBuilder.java
deleted:    java-shopping-css/proto-google-shopping-css-v1/src/main/java/com/google/shopping/type/TypesProto.java

So I think the answer to your question is no (these classes can be inherited from shared dependencies).

;;
esac
# download gapic-generator-java, protobuf and grpc plugin.
download_tools "${gapic_generator_version}" "${protobuf_version}" "${grpc_version}" "${os_architecture}"
Expand Down Expand Up @@ -285,7 +291,8 @@ case "${proto_path}" in
esac
# copy proto files to proto-*/src/main/proto
for proto_src in ${proto_files}; do
if [[ "${proto_src}" == "google/cloud/common/operation_metadata.proto" ]]; then
if [[ "${proto_src}" == "google/cloud/common/operation_metadata.proto" ]] ||
[[ "${proto_src}" == "google/shopping/type/types.proto" ]]; then
continue
fi
mkdir -p "${temp_destination_path}/proto-${folder_name}/src/main/proto"
Expand Down