-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: gRPC codegen config in parent pom #170
Conversation
Manually checked that this works nicely in the doc snippets which has a protobuf dir and another sample that does not. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM apart from the question about proto
vs protobuf
dir.
<id>generate-protobuf-endpoints</id> | ||
<activation> | ||
<file> | ||
<exists>src/main/protobuf</exists> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I thought the directory was usually proto
? maybe it can be either? I think we use to have proto
in samples?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, I'll change, IntelliJ suggests both (and we probably pick either up in Akka gRPC) but we indeed use proto
Akka gRPC samples so let's go with that.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For the record protobuf
is the default in sbt/Scala projects
throw new IllegalStateException( | ||
s"SDK Akka gRPC plugin version is [$pluginVersion] but parent pom version is not the same [$parentPomAkkaGrpcVersion]. " + | ||
s"Align $parentPomFile with the SDK build version to correct.") | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great to have this check in place. 👍
A profile triggered by the existence of a src/main/protobuf enables the akka-grpc plugin with the right config.
Also adds validation that the grpc version in the parent pom and the SDK are aligned as a CI check.