Skip to content

Commit f63086b

Browse files
Upgrade protobuf plugin from 0.8.19 to 0.9.4 (#3101)
https://github.com/google/protobuf-gradle-plugin/releases > - Significantly improve support for task configuration avoidance. README.md has not yet been updated to encourage using configureEach instead of each within generateProtoTasks {}, but it is beneficial as long as you are not using any IDE plugins > - Added generated code to java SourceSet instead of only adding it to JavaCompile and related tasks. This should cause tasks like sourcesJar and javadoc to now include the generated code. You may need to exclude the generated code from linters I skimmed through the differences in the generated java files in protogen, and AFAICT the only change is that `Builder`s now have `@SuppressWarnings("deprecation")` on them. --------- Co-authored-by: Alec Grieser <[email protected]>
1 parent 8b77068 commit f63086b

File tree

4 files changed

+1
-33
lines changed

4 files changed

+1
-33
lines changed

fdb-record-layer-jmh/fdb-record-layer-jmh.gradle

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -23,16 +23,6 @@ plugins {
2323
}
2424

2525
apply from: rootProject.file('gradle/proto.gradle')
26-
sourceSets {
27-
jmh {
28-
proto {
29-
srcDir "src/jmh/proto"
30-
}
31-
java {
32-
srcDir 'protogen/jmh/java'
33-
}
34-
}
35-
}
3626

3727
def coreProject = ":${ext.coreProjectName}"
3828
dependencies {

fdb-relational-grpc/fdb-relational-grpc.gradle

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -40,15 +40,6 @@ protobuf {
4040
}
4141
}
4242

43-
sourceSets {
44-
main {
45-
java {
46-
// Add these two dirs to the default src/main/java.
47-
srcDir("${projectDir}/protogen/main/grpc")
48-
}
49-
}
50-
}
51-
5243
dependencies {
5344
// Have grpc depend on fdb-relational-api. Anyone that uses grpc will also use api.
5445
// Having grpc depend on api makes it so we can add utility here shared by

gradle/libs.versions.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ download = { id = "de.undercouch.download", version = "5.6.0" }
155155
gitversion = { id = "com.palantir.git-version", version = "3.1.0" }
156156
jmh = { id = "me.champeau.jmh", version = "0.7.2" }
157157
nexus = { id = "io.github.gradle-nexus.publish-plugin", version = "2.0.0" }
158-
protobuf = { id = "com.google.protobuf", version = "0.8.19" }
158+
protobuf = { id = "com.google.protobuf", version = "0.9.4" }
159159
serviceloader = { id = "com.github.harbby.gradle.serviceloader", version = "1.1.8" }
160160
shadow = { id = "com.github.johnrengelman.shadow", version = "7.1.2" }
161161
spotbugs = { id = "com.github.spotbugs", version = "6.1.3" }

gradle/proto.gradle

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -20,19 +20,6 @@
2020

2121
apply plugin: 'com.google.protobuf'
2222

23-
sourceSets {
24-
main {
25-
java {
26-
srcDir 'protogen/main/java'
27-
}
28-
}
29-
test {
30-
java {
31-
srcDir 'protogen/test/java'
32-
}
33-
}
34-
}
35-
3623
configurations {
3724
compileProtoPath {
3825
// The default generated by com.google.protobuf.gradle.ProtobufPlugin.createCompileProtoPathConfiguration

0 commit comments

Comments
 (0)