1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162 |
- plugins {
- id "com.google.protobuf" version "0.8.19"
- id 'java-library'
- }
- group 'com.incubator.message'
- version '1.0-SNAPSHOT'
- dependencies {
- testImplementation 'org.junit.jupiter:junit-jupiter-api:5.10.0'
- testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.10.0'
- api 'com.alibaba.fastjson2:fastjson2:2.0.53'
- api 'com.google.protobuf:protobuf-java:4.28.3'
- api 'io.grpc:grpc-all:1.68.1'
- }
- protobuf {
-
- protoc {
- artifact = 'com.google.protobuf:protoc:4.28.3'
- }
-
- plugins {
- grpc {
- artifact = 'io.grpc:protoc-gen-grpc-java:1.68.1'
- }
- }
-
- generateProtoTasks {
- all().forEach {
- it.plugins {
- grpc {}
- }
- }
- }
- }
- sourceSets {
- main {
- java {
-
- srcDirs 'build/generated/source/proto/main/grpc'
- srcDirs 'build/generated/source/proto/main/java'
- }
- }
- }
- tasks {
-
- build.dependsOn("generateProto")
-
- test {
- useJUnitPlatform()
- testLogging {
- events("PASSED", "FAILED", "SKIPPED")
- }
- }
- }
|