lukecwik commented on a change in pull request #16460: URL: https://github.com/apache/beam/pull/16460#discussion_r782437843
########## File path: buildSrc/src/main/groovy/org/apache/beam/gradle/GrpcVendoring_1_43_2.groovy ########## @@ -0,0 +1,203 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * License); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an AS IS BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.beam.gradle + +/** + * Utilities for working with our vendored version of gRPC. + * + * To update: + * 1. Determine the set of io.grpc libraries we want to include. + * 2. Use mvn dependency:tree and https://search.maven.org/search?q=g:io.grpc + * to determine dependency tree. You may need to search for optional dependencies + * and determine if they are needed (e.g. conscrypt). + */ +class GrpcVendoring_1_43_2 { + static def grpc_version = "1.43.2" + + // See https://github.com/grpc/grpc-java/blob/v1.43.2/build.gradle + // or https://search.maven.org/search?q=g:io.grpc%201.43.2 + static def guava_version = "30.1.1-jre" + static def protobuf_version = "3.19.2" + static def gson_version = "2.8.9" + static def google_auth_version = "0.22.2" + static def opencensus_version = "0.28.0" + static def conscrypt_version = "2.5.1" + static def proto_google_common_protos_version = "2.0.1" + + // tcnative version from https://github.com/grpc/grpc-java/blob/master/SECURITY.md#netty + static def netty_version = "4.1.63.Final" + static def netty_ssl_version = "2.0.38.Final" Review comment: ```suggestion static def netty_tcnative_version = "2.0.38.Final" ``` ########## File path: buildSrc/src/main/groovy/org/apache/beam/gradle/GrpcVendoring_1_43_2.groovy ########## @@ -0,0 +1,203 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * License); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an AS IS BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.beam.gradle + +/** + * Utilities for working with our vendored version of gRPC. + * + * To update: + * 1. Determine the set of io.grpc libraries we want to include. + * 2. Use mvn dependency:tree and https://search.maven.org/search?q=g:io.grpc + * to determine dependency tree. You may need to search for optional dependencies + * and determine if they are needed (e.g. conscrypt). + */ +class GrpcVendoring_1_43_2 { + static def grpc_version = "1.43.2" + + // See https://github.com/grpc/grpc-java/blob/v1.43.2/build.gradle + // or https://search.maven.org/search?q=g:io.grpc%201.43.2 + static def guava_version = "30.1.1-jre" + static def protobuf_version = "3.19.2" + static def gson_version = "2.8.9" + static def google_auth_version = "0.22.2" + static def opencensus_version = "0.28.0" + static def conscrypt_version = "2.5.1" + static def proto_google_common_protos_version = "2.0.1" + + // tcnative version from https://github.com/grpc/grpc-java/blob/master/SECURITY.md#netty + static def netty_version = "4.1.63.Final" + static def netty_ssl_version = "2.0.38.Final" + + /** Returns the list of implementation time dependencies. */ + static List<String> dependencies() { + return [ + "com.google.guava:guava:$guava_version", + "com.google.protobuf:protobuf-java:$protobuf_version", + "com.google.protobuf:protobuf-java-util:$protobuf_version", + "com.google.code.gson:gson:$gson_version", + "io.grpc:grpc-auth:$grpc_version", + "io.grpc:grpc-core:$grpc_version", + "io.grpc:grpc-context:$grpc_version", + "io.grpc:grpc-netty:$grpc_version", + "io.grpc:grpc-protobuf:$grpc_version", + "io.grpc:grpc-stub:$grpc_version", + "io.grpc:grpc-testing:$grpc_version", + // Use a classifier to ensure we get the jar containing native libraries. In the future + // hopefully netty releases a single jar containing native libraries for all architectures. + "io.netty:netty-transport-native-epoll:$netty_version:linux-x86_64", + // tcnative version from https://github.com/grpc/grpc-java/blob/master/SECURITY.md#netty Review comment: ```suggestion ``` ########## File path: buildSrc/src/main/groovy/org/apache/beam/gradle/GrpcVendoring_1_43_2.groovy ########## @@ -0,0 +1,203 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * License); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an AS IS BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.beam.gradle + +/** + * Utilities for working with our vendored version of gRPC. + * + * To update: + * 1. Determine the set of io.grpc libraries we want to include. + * 2. Use mvn dependency:tree and https://search.maven.org/search?q=g:io.grpc + * to determine dependency tree. You may need to search for optional dependencies + * and determine if they are needed (e.g. conscrypt). + */ +class GrpcVendoring_1_43_2 { + static def grpc_version = "1.43.2" + + // See https://github.com/grpc/grpc-java/blob/v1.43.2/build.gradle + // or https://search.maven.org/search?q=g:io.grpc%201.43.2 + static def guava_version = "30.1.1-jre" + static def protobuf_version = "3.19.2" + static def gson_version = "2.8.9" + static def google_auth_version = "0.22.2" + static def opencensus_version = "0.28.0" + static def conscrypt_version = "2.5.1" + static def proto_google_common_protos_version = "2.0.1" + + // tcnative version from https://github.com/grpc/grpc-java/blob/master/SECURITY.md#netty + static def netty_version = "4.1.63.Final" + static def netty_ssl_version = "2.0.38.Final" + + /** Returns the list of implementation time dependencies. */ + static List<String> dependencies() { + return [ + "com.google.guava:guava:$guava_version", + "com.google.protobuf:protobuf-java:$protobuf_version", + "com.google.protobuf:protobuf-java-util:$protobuf_version", + "com.google.code.gson:gson:$gson_version", + "io.grpc:grpc-auth:$grpc_version", + "io.grpc:grpc-core:$grpc_version", + "io.grpc:grpc-context:$grpc_version", + "io.grpc:grpc-netty:$grpc_version", + "io.grpc:grpc-protobuf:$grpc_version", + "io.grpc:grpc-stub:$grpc_version", + "io.grpc:grpc-testing:$grpc_version", + // Use a classifier to ensure we get the jar containing native libraries. In the future + // hopefully netty releases a single jar containing native libraries for all architectures. + "io.netty:netty-transport-native-epoll:$netty_version:linux-x86_64", + // tcnative version from https://github.com/grpc/grpc-java/blob/master/SECURITY.md#netty + "io.netty:netty-tcnative-boringssl-static:$netty_ssl_version", Review comment: ```suggestion "io.netty:netty-tcnative-boringssl-static:$netty_tcnative_version", ``` ########## File path: buildSrc/src/main/groovy/org/apache/beam/gradle/GrpcVendoring_1_43_2.groovy ########## @@ -0,0 +1,203 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * License); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an AS IS BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.beam.gradle + +/** + * Utilities for working with our vendored version of gRPC. + * + * To update: + * 1. Determine the set of io.grpc libraries we want to include. + * 2. Use mvn dependency:tree and https://search.maven.org/search?q=g:io.grpc + * to determine dependency tree. You may need to search for optional dependencies + * and determine if they are needed (e.g. conscrypt). Review comment: 3. Validate built artifact by running unit and integration tests in a PR (for example linkToYourTestingPR) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
