diff --git a/.github/workflows/verify-grpc-generation.yml b/.github/workflows/verify-grpc-generation.yml
new file mode 100644
index 000000000..3bf624377
--- /dev/null
+++ b/.github/workflows/verify-grpc-generation.yml
@@ -0,0 +1,29 @@
+name: Verify gRPC Generation
+
+on:
+ push:
+ pull_request:
+ workflow_dispatch:
+
+# Only run the latest job
+concurrency:
+ group: '${{ github.workflow }} @ ${{ github.head_ref || github.ref }}'
+ cancel-in-progress: true
+
+jobs:
+ verify-grpc-generation:
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v6
+ - name: Set up JDK 21
+ uses: actions/setup-java@v5
+ with:
+ java-version: '21'
+ distribution: 'temurin'
+ cache: maven
+ - name: Verify gRPC code generation
+ # -pl: build only spec-grpc and compat-0.3/spec-grpc modules
+ # -am: also build their dependencies
+ # -Dskip.protobuf.generate=false: enable protoc generation in spec-grpc (skipped by default)
+ # -Pproto-compile: activate the proto-compile profile in compat-0.3/spec-grpc
+ run: mvn install -B -DskipTests -pl spec-grpc,compat-0.3/spec-grpc -am -Dskip.protobuf.generate=false -Pproto-compile
diff --git a/spec-grpc/pom.xml b/spec-grpc/pom.xml
index 7c33db060..be2938b10 100644
--- a/spec-grpc/pom.xml
+++ b/spec-grpc/pom.xml
@@ -96,19 +96,21 @@
io.github.ascopes
protobuf-maven-plugin
- 4.1.2
+ 5.1.4
${skip.protobuf.generate}
true
- ${protobuf-java.version}
+
+ ${protobuf-java.version}
+
${project.basedir}/src/main/java/
-
-
+
+
io.grpc
protoc-gen-grpc-java
${grpc.version}
-
-
+
+