kotlin-samples
kotlin-samples copied to clipboard
grpc-hello-world-mvn does not build in ubuntu
After downloading repo at https://github.com/GoogleCloudPlatform/kotlin-samples/commit/41339a36aaa1feb6b50789964ba8f5795f53b18e, grpc-hello-world-mvn it does not build properly.
There is an error report by ktlin-maven-plugin: object GreeterGrpcKt should be declared in a file named GreeterGrpcKt.kt
Looking at generated source files, effectively there is no GreeterGrpcKt.kt file, instead there is one with same expected information but named HelloWorldGrpcKt.kt (see image at the bottom). Due to this, HelloWorldServer and HelloWorldClient are not able to find required dependencies as well.
Here is the information about my OS
[INFO] Detecting the operating system and CPU architecture
[INFO] ------------------------------------------------------------------------
[INFO] os.detected.name: linux
[INFO] os.detected.arch: x86_64
[INFO] os.detected.version: 5.4
[INFO] os.detected.version.major: 5
[INFO] os.detected.version.minor: 4
[INFO] os.detected.release: ubuntu
[INFO] os.detected.release.version: 20.04
[INFO] os.detected.release.like.ubuntu: true
[INFO] os.detected.release.like.debian: true
[INFO] os.detected.classifier: linux-x86_64
Here are the dependencies being downloaded related to protoc-gen-grpc-kotlin
[INFO] --- protobuf-maven-plugin:0.5.0:compile-custom (grpc-kotlin) @ grpc-hello-world-kotlin ---
Downloading from central: https://repo.maven.apache.org/maven2/io/grpc/protoc-gen-grpc-kotlin/0.1.3/protoc-gen-grpc-kotlin-0.1.1.pom
Downloaded from central: https://repo.maven.apache.org/maven2/io/grpc/protoc-gen-grpc-kotlin/0.1.3/protoc-gen-grpc-kotlin-0.1.1.pom (3.1 kB at 15 kB/s)
Downloading from central: https://repo.maven.apache.org/maven2/io/grpc/protoc-gen-grpc-kotlin/0.1.3/protoc-gen-grpc-kotlin-0.1.1-linux-x86_64.exe
Downloaded from central: https://repo.maven.apache.org/maven2/io/grpc/protoc-gen-grpc-kotlin/0.1.3/protoc-gen-grpc-kotlin-0.1.1-linux-x86_64.exe (21 MB at 1.0 MB/s)
Generated files tree

What command are you running to see this?
What command are you running to see this?
mvn clean install while being at grpc-hello-world-mvn folder
Thanks! I was able to reproduce with that command and I'll work on fixing it.