Skip to content

Commit

Permalink
compile -> api switch
Browse files Browse the repository at this point in the history
  • Loading branch information
zendern authored and graemerocher committed Dec 11, 2019
1 parent f934539 commit bf66a99
Show file tree
Hide file tree
Showing 35 changed files with 123 additions and 114 deletions.
2 changes: 1 addition & 1 deletion aop/build.gradle
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
dependencies {
compile project(":inject")
api project(":inject")
}
shadowJar.enabled = true
9 changes: 4 additions & 5 deletions benchmarks/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,10 @@ dependencies {
annotationProcessor project(":validation")
compileOnly project(":inject-java")
compileOnly project(":validation")
compile project(":inject")
compile project(":inject-java-test")
compile project(":validation")
compile project(":runtime")

api project(":inject")
api project(":inject-java-test")
api project(":validation")
api project(":runtime")

jmh 'org.openjdk.jmh:jmh-core:1.22'
jmh 'org.openjdk.jmh:jmh-generator-annprocess:1.21'
Expand Down
4 changes: 2 additions & 2 deletions buffer-netty/build.gradle
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
dependencies {
compile project(":core")
compile dependencyModuleVersion("netty", "netty-buffer")
api project(":core")
api dependencyModuleVersion("netty", "netty-buffer")

compileOnly project(":inject-java")
}
4 changes: 2 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -613,7 +613,7 @@ subprojects { Project subproject ->
// apply plugin:"org.grails.grails-web"
} else {
apply plugin: "groovy"
apply plugin: "java"
apply plugin: "java-library"

sourceCompatibility = '1.8'
targetCompatibility = '1.8'
Expand Down Expand Up @@ -708,7 +708,7 @@ subprojects { Project subproject ->
documentation "org.codehaus.groovy:groovy-templates:$groovyVersion"
documentation "org.codehaus.groovy:groovy-dateutil:$groovyVersion"
if (subproject.name != "bom") {
compile dependencyVersion("slf4j")
api dependencyVersion("slf4j")
}


Expand Down
22 changes: 11 additions & 11 deletions cli/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,17 @@ repositories {
}

dependencies {
compile "info.picocli:picocli-groovy:$picocliVersion"
compile "org.apache.ant:ant:1.9.7"
compile dependencyModuleVersion("groovy", "groovy-ant")
compile dependencyModuleVersion("groovy", "groovy-json")
compile dependencyModuleVersion("groovy", "groovy-jmx")
compile dependencyModuleVersion("groovy", "groovy-xml")
compile dependencyModuleVersion("groovy", "groovy-templates")
compile "org.fusesource.jansi:jansi:1.14"
compile "jline:jline:2.12"
compile "org.springframework.boot:spring-boot-cli:1.5.10.RELEASE"
compile dependencyVersion("snakeyaml")
api "info.picocli:picocli-groovy:$picocliVersion"
api "org.apache.ant:ant:1.9.7"
api dependencyModuleVersion("groovy", "groovy-ant")
api dependencyModuleVersion("groovy", "groovy-json")
api dependencyModuleVersion("groovy", "groovy-jmx")
api dependencyModuleVersion("groovy", "groovy-xml")
api dependencyModuleVersion("groovy", "groovy-templates")
api "org.fusesource.jansi:jansi:1.14"
api "jline:jline:2.12"
api "org.springframework.boot:spring-boot-cli:1.5.10.RELEASE"
api dependencyVersion("snakeyaml")
runtime dependencyModuleVersion("slf4j", "slf4j-simple")
runtime "org.codehaus.plexus:plexus-component-api:1.0-alpha-33"

Expand Down
6 changes: 3 additions & 3 deletions core/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ shadowJar {
}

dependencies {
compile dependencyVersion("slf4j")
compile dependencyVersion("reactive.streams")
compile dependencyVersion("jsr305")
api dependencyVersion("slf4j")
api dependencyVersion("reactive.streams")
api dependencyVersion("jsr305")

compileOnly "org.ow2.asm:asm-tree:$asmVersion"
shadowCompile "org.ow2.asm:asm:$asmVersion"
Expand Down
5 changes: 3 additions & 2 deletions discovery-client/build.gradle
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
dependencies {
compileOnly project(":inject-java")
annotationProcessor project(":inject-java")
compileOnly project(":graal")
compileOnly project(":management")

compile project(":http-client")
compile project(":validation")
api project(":http-client")
api project(":validation")

compileOnly dependencyVersion("micronaut.aws"), {
exclude module:'micronaut-http-client'
Expand Down
9 changes: 5 additions & 4 deletions function-client/build.gradle
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
dependencies {
compile project(":function")
compile project(":http-client")
compile dependencyVersion("micronaut.aws"), {
api project(":function")
api project(":http-client")
api dependencyVersion("micronaut.aws"), {
exclude module:'micronaut-http-client'
exclude module:'micronaut-inject'
}
compileOnly project(":inject-java")
api project(":inject-java")
annotationProcessor project(":inject-java")
compileOnly dependencyVersion("micronaut.function.aws"), {
exclude module:"micronaut-function"
}
Expand Down
7 changes: 4 additions & 3 deletions function-web/build.gradle
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
dependencies {
compileOnly project(":inject-java")
compile project(":function")
compile project(":router")
compile project(":http-server")
annotationProcessor project(":inject-java")
api project(":function")
api project(":router")
api project(":http-server")

testImplementation project(":http-client")
testImplementation project(":inject-groovy")
Expand Down
5 changes: 3 additions & 2 deletions function/build.gradle
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
dependencies {
compile project(":runtime")
api project(":runtime")
compileOnly project(":inject-java")
compile project(":http")
annotationProcessor project(":inject-java")
api project(":http")

testImplementation project(":inject-java")
}
6 changes: 4 additions & 2 deletions graal/build.gradle
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
dependencies {
compileOnly project(":inject-java")
compile project(":inject")
compile dependencyVersion("jackson.databind")
annotationProcessor project(":inject-java")
api project(":inject")
api dependencyVersion("jackson.databind")

testImplementation project(":inject-java")
testImplementation project(":http")
testImplementation project(":inject-java-test")
Expand Down
11 changes: 6 additions & 5 deletions http-client/build.gradle
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
dependencies {
compileOnly project(":inject-java")
compile dependencyVersion("rxjava2")
compile project(":http-netty")
compile project(":runtime")
compile dependencyModuleVersion("netty", "netty-handler-proxy")
annotationProcessor project(":inject-java")
api dependencyVersion("rxjava2")
api project(":http-netty")
api project(":runtime")
api dependencyModuleVersion("netty", "netty-handler-proxy")

compileOnly dependencyVersion("reactor")
compile project(":websocket")
api project(":websocket")

testImplementation project(":inject-groovy")
testImplementation project(":validation")
Expand Down
12 changes: 6 additions & 6 deletions http-netty/build.gradle
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
dependencies {
compileOnly "com.oracle.substratevm:svm:$graalVersion"
compileOnly project(":graal")
compile project(":buffer-netty")
compile project(":http")
compile project(":websocket")
api project(":buffer-netty")
api project(":http")
api project(":websocket")
compileOnly project(":inject-java")
compile dependencyVersion("netty")
compile dependencyVersion("rxjava2")
compile dependencyModuleVersion("netty", "netty-handler")
api dependencyVersion("netty")
api dependencyVersion("rxjava2")
api dependencyModuleVersion("netty", "netty-handler")
}
5 changes: 3 additions & 2 deletions http-server-netty/build.gradle
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
dependencies {
compile project(":http-server")
compile project(":http-netty")
api project(":http-server")
api project(":http-netty")

annotationProcessor project(":inject-java")
compileOnly project(":inject-java")
compileOnly dependencyModuleVersion("netty", "netty-transport-native-epoll")
compileOnly dependencyModuleVersion("netty", "netty-transport-native-kqueue")
Expand Down
6 changes: 3 additions & 3 deletions http-server/build.gradle
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@

dependencies {
compile project(":websocket")
compile project(":runtime")
compile project(":router")
api project(":websocket")
api project(":runtime")
api project(":router")
compileOnly project(":inject-java")
}

Expand Down
5 changes: 3 additions & 2 deletions http/build.gradle
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
dependencies {
compile project(":inject")
api project(":inject")
compileOnly project(":inject-java")
compileOnly project(":graal")
annotationProcessor project(":inject-java")
api project(":graal")

testImplementation project(":inject-groovy")
}
Expand Down
6 changes: 3 additions & 3 deletions inject-groovy/build.gradle
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
dependencies {
compile project(":inject")
compile project(":aop")
compile dependencyVersion("groovy")
api project(":inject")
api project(":aop")
api dependencyVersion("groovy")

testImplementation "junit:junit:4.12"
// testImplementation 'javax.validation:validation-api:1.1.0.Final'
Expand Down
11 changes: 6 additions & 5 deletions inject-java-test/build.gradle
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
dependencies {
compile project(":inject-java")
compile "com.google.testing.compile:compile-testing:0.18"
compile dependencyVersion("groovy")
compile(dependencyVersion("spock")) {
api project(":inject-java")
api "com.google.testing.compile:compile-testing:0.18"
api dependencyVersion("groovy")
api(dependencyVersion("spock")) {
exclude module:'groovy-all'
}
compile files(org.gradle.internal.jvm.Jvm.current().toolsJar)
api files(org.gradle.internal.jvm.Jvm.current().toolsJar)

testImplementation dependencyVersion("validation")
testImplementation "javax.persistence:javax.persistence-api:2.2"
testImplementation project(":runtime")
Expand Down
4 changes: 2 additions & 2 deletions inject-java/build.gradle
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
dependencies {
compile project(":inject")
compile project(":aop")
api project(":inject")
api project(":aop")

compileOnly files(org.gradle.internal.jvm.Jvm.current().toolsJar)
compileOnly dependencyVersion("validation")
Expand Down
8 changes: 4 additions & 4 deletions inject/build.gradle
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
shadowJar.enabled = true
dependencies {
compile dependencyVersion("javax.annotation-api")
compile group: 'javax.inject', name: 'javax.inject', version: '1'
compile project(':core')
compile dependencyVersion("snakeyaml")
api dependencyVersion("javax.annotation-api")
api group: 'javax.inject', name: 'javax.inject', version: '1'
api project(':core')
api dependencyVersion("snakeyaml")

compileOnly "javax.persistence:javax.persistence-api:2.2"
compileOnly dependencyVersion("groovy")
Expand Down
2 changes: 1 addition & 1 deletion jdbc/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@ dependencies {
compileOnly dependencyModuleVersion("spring", "spring-jdbc")
compileOnly dependencyModuleVersion("spring", "spring-tx")

compile project(":inject")
api project(":inject")
}
4 changes: 2 additions & 2 deletions management/build.gradle
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
dependencies {
compile project(":router")
compile project(":runtime")
api project(":router")
api project(":runtime")
compileOnly project(":inject-java")
compileOnly project(":graal")

Expand Down
4 changes: 2 additions & 2 deletions messaging/build.gradle
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
dependencies {
compileOnly project(":inject-java")
compile project(":inject")
compile project(":runtime")
api project(":inject")
api project(":runtime")
}
6 changes: 3 additions & 3 deletions multitenancy/build.gradle
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
dependencies {
compileOnly project(":inject-java")

compile project(":runtime")
compile project(":http")
compile project(":http-server")
api project(":runtime")
api project(":http")
api project(":http-server")
compileOnly project(":session")

testImplementation project(":http-client")
Expand Down
4 changes: 2 additions & 2 deletions router/build.gradle
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
dependencies {
compileOnly dependencyVersion("groovy")
compile project(":inject")
compile project(":http")
api project(":inject")
api project(":http")
compileOnly project(":inject-java")
testImplementation project(":inject-groovy")
testImplementation project(":inject-java")
Expand Down
6 changes: 3 additions & 3 deletions runtime-osx/build.gradle
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
dependencies {
compileOnly project(":inject-java")

compile project(":runtime")
compile dependencyVersion("methvin.directory-watcher")
compile dependencyVersion("jna")
api project(":runtime")
api dependencyVersion("methvin.directory-watcher")
api dependencyVersion("jna")
}
10 changes: 5 additions & 5 deletions runtime/build.gradle
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
shadowJar.enabled = true
dependencies {
for(proj in ['inject', 'http', 'aop']) {
compile project(":$proj")
api project(":$proj")
}
compileOnly "com.oracle.substratevm:svm:$graalVersion"
compileOnly project(":graal")
compileOnly dependencyVersion("jcache")
compile dependencyVersion("validation")
compile dependencyVersion("jackson.databind")
compile dependencyVersion("rxjava2")
api dependencyVersion("validation")
api dependencyVersion("jackson.databind")
api dependencyVersion("rxjava2")

compile([
dependencyVersion('jackson.datatype'),
Expand All @@ -35,7 +35,7 @@ dependencies {
compileOnly dependencyVersion("reactor")
compileOnly dependencyVersion("rxjava1.interop")
compileOnly "com.github.ben-manes.caffeine:caffeine:$caffeineVersion"
compileOnly project(":inject-java")
annotationProcessor project(":inject-java")

testImplementation 'org.jsr107.ri:cache-ri-impl:1.1.0'
testImplementation dependencyVersion("jcache")
Expand Down
4 changes: 2 additions & 2 deletions session/build.gradle
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
shadowJar.enabled = true
dependencies {
compile project(":runtime")
compile project(":http")
api project(":runtime")
api project(":http")

compileOnly project(":inject-java")
compileOnly project(":http-server")
Expand Down
Loading

0 comments on commit bf66a99

Please sign in to comment.