mirror of https://github.com/grpc/grpc-java.git
all: generate automatic module name in the manifest (#10413)
This commit is contained in:
parent
08a44b9224
commit
41552bfd9a
|
|
@ -65,6 +65,9 @@ tasks.named("javadoc").configure {
|
||||||
tasks.named("jar").configure {
|
tasks.named("jar").configure {
|
||||||
// Must use a different archiveClassifier to avoid conflicting with shadowJar
|
// Must use a different archiveClassifier to avoid conflicting with shadowJar
|
||||||
archiveClassifier = 'original'
|
archiveClassifier = 'original'
|
||||||
|
manifest {
|
||||||
|
attributes('Automatic-Module-Name': 'io.grpc.alts')
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// We want to use grpc-netty-shaded instead of grpc-netty. But we also want our
|
// We want to use grpc-netty-shaded instead of grpc-netty. But we also want our
|
||||||
|
|
|
||||||
|
|
@ -21,6 +21,11 @@ compileContextJava {
|
||||||
targetCompatibility = 1.7
|
targetCompatibility = 1.7
|
||||||
}
|
}
|
||||||
|
|
||||||
|
tasks.named("jar").configure {
|
||||||
|
manifest {
|
||||||
|
attributes('Automatic-Module-Name': 'io.grpc')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
compileOnly sourceSets.context.output
|
compileOnly sourceSets.context.output
|
||||||
|
|
|
||||||
|
|
@ -7,6 +7,13 @@ plugins {
|
||||||
}
|
}
|
||||||
|
|
||||||
description = "gRPC: Auth"
|
description = "gRPC: Auth"
|
||||||
|
|
||||||
|
tasks.named("jar").configure {
|
||||||
|
manifest {
|
||||||
|
attributes('Automatic-Module-Name': 'io.grpc.auth')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
api project(':grpc-api'),
|
api project(':grpc-api'),
|
||||||
libraries.google.auth.credentials
|
libraries.google.auth.credentials
|
||||||
|
|
|
||||||
|
|
@ -18,6 +18,12 @@ configurations {
|
||||||
alpnagent
|
alpnagent
|
||||||
}
|
}
|
||||||
|
|
||||||
|
tasks.named("jar").configure {
|
||||||
|
manifest {
|
||||||
|
attributes('Automatic-Module-Name': 'io.grpc.benchmarks')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
implementation project(':grpc-core'),
|
implementation project(':grpc-core'),
|
||||||
project(':grpc-netty'),
|
project(':grpc-netty'),
|
||||||
|
|
|
||||||
|
|
@ -7,6 +7,12 @@ plugins {
|
||||||
|
|
||||||
description = 'gRPC: Census'
|
description = 'gRPC: Census'
|
||||||
|
|
||||||
|
tasks.named("jar").configure {
|
||||||
|
manifest {
|
||||||
|
attributes('Automatic-Module-Name': 'io.grpc.census')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
api project(':grpc-api')
|
api project(':grpc-api')
|
||||||
// force dependent jars to depend on latest grpc-context
|
// force dependent jars to depend on latest grpc-context
|
||||||
|
|
|
||||||
|
|
@ -56,6 +56,12 @@ tasks.named("javadoc").configure {
|
||||||
exclude 'io/grpc/perfmark/**'
|
exclude 'io/grpc/perfmark/**'
|
||||||
}
|
}
|
||||||
|
|
||||||
|
tasks.named("jar").configure {
|
||||||
|
manifest {
|
||||||
|
attributes('Automatic-Module-Name': 'io.grpc.internal')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
animalsniffer {
|
animalsniffer {
|
||||||
// Don't check sourceSets.jmh
|
// Don't check sourceSets.jmh
|
||||||
sourceSets = [
|
sourceSets = [
|
||||||
|
|
|
||||||
|
|
@ -19,6 +19,12 @@ tasks.named("compileJava").configure {
|
||||||
"|")
|
"|")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
tasks.named("jar").configure {
|
||||||
|
manifest {
|
||||||
|
attributes('Automatic-Module-Name': 'io.grpc.gcp.observability')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
annotationProcessor libraries.auto.value
|
annotationProcessor libraries.auto.value
|
||||||
api project(':grpc-api')
|
api project(':grpc-api')
|
||||||
|
|
|
||||||
|
|
@ -7,6 +7,12 @@ plugins {
|
||||||
|
|
||||||
description = 'gRPC: googleapis'
|
description = 'gRPC: googleapis'
|
||||||
|
|
||||||
|
tasks.named("jar").configure {
|
||||||
|
manifest {
|
||||||
|
attributes('Automatic-Module-Name': 'io.grpc.googleapis')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
api project(':grpc-api')
|
api project(':grpc-api')
|
||||||
implementation project(path: ':grpc-alts', configuration: 'shadow'),
|
implementation project(path: ':grpc-alts', configuration: 'shadow'),
|
||||||
|
|
|
||||||
|
|
@ -9,6 +9,12 @@ plugins {
|
||||||
|
|
||||||
description = "gRPC: GRPCLB LoadBalancer plugin"
|
description = "gRPC: GRPCLB LoadBalancer plugin"
|
||||||
|
|
||||||
|
tasks.named("jar").configure {
|
||||||
|
manifest {
|
||||||
|
attributes('Automatic-Module-Name': 'io.grpc.grpclb')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
implementation project(':grpc-core'),
|
implementation project(':grpc-core'),
|
||||||
project(':grpc-protobuf'),
|
project(':grpc-protobuf'),
|
||||||
|
|
|
||||||
|
|
@ -7,6 +7,12 @@ plugins {
|
||||||
|
|
||||||
description = 'gRPC: Inprocess'
|
description = 'gRPC: Inprocess'
|
||||||
|
|
||||||
|
tasks.named("jar").configure {
|
||||||
|
manifest {
|
||||||
|
attributes('Automatic-Module-Name': 'io.grpc.inprocess')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
api project(':grpc-core')
|
api project(':grpc-core')
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -13,6 +13,12 @@ configurations {
|
||||||
alpnagent
|
alpnagent
|
||||||
}
|
}
|
||||||
|
|
||||||
|
tasks.named("jar").configure {
|
||||||
|
manifest {
|
||||||
|
attributes('Automatic-Module-Name': 'io.grpc.netty')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
api project(':grpc-core'),
|
api project(':grpc-core'),
|
||||||
libraries.netty.codec.http2
|
libraries.netty.codec.http2
|
||||||
|
|
|
||||||
|
|
@ -70,6 +70,9 @@ dependencies {
|
||||||
tasks.named("jar").configure {
|
tasks.named("jar").configure {
|
||||||
// Must use a different archiveClassifier to avoid conflicting with shadowJar
|
// Must use a different archiveClassifier to avoid conflicting with shadowJar
|
||||||
archiveClassifier = 'original'
|
archiveClassifier = 'original'
|
||||||
|
manifest {
|
||||||
|
attributes('Automatic-Module-Name': 'io.grpc.netty.shaded')
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
tasks.named("shadowJar").configure {
|
tasks.named("shadowJar").configure {
|
||||||
|
|
|
||||||
|
|
@ -8,6 +8,12 @@ plugins {
|
||||||
|
|
||||||
description = "gRPC: OkHttp"
|
description = "gRPC: OkHttp"
|
||||||
|
|
||||||
|
tasks.named("jar").configure {
|
||||||
|
manifest {
|
||||||
|
attributes('Automatic-Module-Name': 'io.grpc.okhttp')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
api project(':grpc-util')
|
api project(':grpc-util')
|
||||||
implementation libraries.okio,
|
implementation libraries.okio,
|
||||||
|
|
|
||||||
|
|
@ -21,6 +21,12 @@ dependencies {
|
||||||
signature libraries.signature.android
|
signature libraries.signature.android
|
||||||
}
|
}
|
||||||
|
|
||||||
|
tasks.named("jar").configure {
|
||||||
|
manifest {
|
||||||
|
attributes('Automatic-Module-Name': 'io.grpc.protobuf.lite')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
tasks.named("compileTestJava").configure {
|
tasks.named("compileTestJava").configure {
|
||||||
options.compilerArgs += [
|
options.compilerArgs += [
|
||||||
"-Xlint:-cast"
|
"-Xlint:-cast"
|
||||||
|
|
|
||||||
|
|
@ -9,6 +9,12 @@ plugins {
|
||||||
|
|
||||||
description = 'gRPC: Protobuf'
|
description = 'gRPC: Protobuf'
|
||||||
|
|
||||||
|
tasks.named("jar").configure {
|
||||||
|
manifest {
|
||||||
|
attributes('Automatic-Module-Name': 'io.grpc.protobuf')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
api project(':grpc-api'),
|
api project(':grpc-api'),
|
||||||
libraries.jsr305,
|
libraries.jsr305,
|
||||||
|
|
|
||||||
|
|
@ -8,6 +8,12 @@ plugins {
|
||||||
|
|
||||||
description = "gRPC: RouteLookupService Loadbalancing plugin"
|
description = "gRPC: RouteLookupService Loadbalancing plugin"
|
||||||
|
|
||||||
|
tasks.named("jar").configure {
|
||||||
|
manifest {
|
||||||
|
attributes('Automatic-Module-Name': 'io.grpc.rls')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
implementation project(':grpc-util'),
|
implementation project(':grpc-util'),
|
||||||
project(':grpc-protobuf'),
|
project(':grpc-protobuf'),
|
||||||
|
|
|
||||||
|
|
@ -16,6 +16,12 @@ tasks.named("compileJava").configure {
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
|
tasks.named("jar").configure {
|
||||||
|
manifest {
|
||||||
|
attributes('Automatic-Module-Name': 'io.grpc.services')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
api project(':grpc-protobuf'),
|
api project(':grpc-protobuf'),
|
||||||
project(':grpc-stub'),
|
project(':grpc-stub'),
|
||||||
|
|
|
||||||
|
|
@ -29,6 +29,12 @@ sourceSets {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
tasks.named("jar").configure {
|
||||||
|
manifest {
|
||||||
|
attributes('Automatic-Module-Name': 'io.grpc.servlet')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
api project(':grpc-api')
|
api project(':grpc-api')
|
||||||
compileOnly 'javax.servlet:javax.servlet-api:4.0.1',
|
compileOnly 'javax.servlet:javax.servlet-api:4.0.1',
|
||||||
|
|
|
||||||
|
|
@ -69,6 +69,12 @@ tasks.withType(Checkstyle) {
|
||||||
enabled = false
|
enabled = false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
tasks.named("jar").configure {
|
||||||
|
manifest {
|
||||||
|
attributes('Automatic-Module-Name': 'io.grpc.servlet.jakarta')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
api project(':grpc-api')
|
api project(':grpc-api')
|
||||||
compileOnly 'jakarta.servlet:jakarta.servlet-api:5.0.0',
|
compileOnly 'jakarta.servlet:jakarta.servlet-api:5.0.0',
|
||||||
|
|
|
||||||
|
|
@ -7,6 +7,13 @@ plugins {
|
||||||
}
|
}
|
||||||
|
|
||||||
description = "gRPC: Stub"
|
description = "gRPC: Stub"
|
||||||
|
|
||||||
|
tasks.named("jar").configure {
|
||||||
|
manifest {
|
||||||
|
attributes('Automatic-Module-Name': 'io.grpc.stub')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
api project(':grpc-api'),
|
api project(':grpc-api'),
|
||||||
libraries.guava
|
libraries.guava
|
||||||
|
|
|
||||||
|
|
@ -8,6 +8,12 @@ plugins {
|
||||||
|
|
||||||
description = "gRPC: Testing Protos"
|
description = "gRPC: Testing Protos"
|
||||||
|
|
||||||
|
tasks.named("jar").configure {
|
||||||
|
manifest {
|
||||||
|
attributes('Automatic-Module-Name': 'io.grpc.testing.protobuf')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
api project(':grpc-protobuf'),
|
api project(':grpc-protobuf'),
|
||||||
project(':grpc-stub')
|
project(':grpc-stub')
|
||||||
|
|
|
||||||
|
|
@ -8,6 +8,12 @@ plugins {
|
||||||
|
|
||||||
description = 'gRPC: Util'
|
description = 'gRPC: Util'
|
||||||
|
|
||||||
|
tasks.named("jar").configure {
|
||||||
|
manifest {
|
||||||
|
attributes('Automatic-Module-Name': 'io.grpc.util')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
api project(':grpc-core')
|
api project(':grpc-core')
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -140,6 +140,9 @@ tasks.named("compileJava").configure {
|
||||||
|
|
||||||
tasks.named("jar").configure {
|
tasks.named("jar").configure {
|
||||||
archiveClassifier = 'original'
|
archiveClassifier = 'original'
|
||||||
|
manifest {
|
||||||
|
attributes('Automatic-Module-Name': 'io.grpc.xds')
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
tasks.named("sourcesJar").configure {
|
tasks.named("sourcesJar").configure {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue