Skip to content

Commit

Permalink
Koin-reflect
Browse files Browse the repository at this point in the history
Update jcenter -> mavenCentral
  • Loading branch information
IRus committed Mar 12, 2021
1 parent 1b3c23c commit 3efa083
Show file tree
Hide file tree
Showing 34 changed files with 270 additions and 48 deletions.
13 changes: 13 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ find . -name '*.tar' |xargs ls -lh |grep -v original |grep -v common
```
# Execution time
# JVM Baseline
time (for i in {1..10}; do ./jvm/build/install/jvm/bin/jvm; done)
# 2 classes
time (for i in {1..10}; do ./baseline/build/install/baseline/bin/baseline; done)
Expand All @@ -34,6 +37,7 @@ time (for i in {1..10}; do ./owb/build/install/owb/bin/owb; done)
time (for i in {1..10}; do ./spring/build/install/spring/bin/spring; done)
time (for i in {1..10}; do ./springboot/build/install/springboot/bin/springboot; done)
time (for i in {1..10}; do ./koin/build/install/koin/bin/koin; done)
time (for i in {1..10}; do ./koin-reflect/build/install/koin-reflect/bin/koin-reflect; done)
time (for i in {1..10}; do ./kodein/build/install/kodein/bin/kodein; done)
# 100 classes
Expand All @@ -48,6 +52,7 @@ time (for i in {1..10}; do ./owb-deep/build/install/owb-deep/bin/owb-deep; done)
time (for i in {1..10}; do ./spring-deep/build/install/spring-deep/bin/spring-deep; done)
time (for i in {1..10}; do ./springboot-deep/build/install/springboot-deep/bin/springboot-deep; done)
time (for i in {1..10}; do ./koin-deep/build/install/koin-deep/bin/koin-deep; done)
time (for i in {1..10}; do ./koin-reflect-deep/build/install/koin-reflect-deep/bin/koin-reflect-deep; done)
time (for i in {1..10}; do ./kodein-deep/build/install/kodein-deep/bin/kodein-deep; done)
```

Expand Down Expand Up @@ -81,6 +86,12 @@ cloc ./koin-deep/src
cloc ./kodein-deep/src
```

# Results for JVM (JDK 11)

|DI|Jar w/Deps Size, Mb|:arrow_down: Exec time, s|LoC|
|----|----|----|----|
|JVM Baseline|TODO|TODO|-|

## Results for 2 classes (JDK 11)

|DI|Jar w/Deps Size, Mb|:arrow_down: Exec time, s|LoC|
Expand All @@ -89,6 +100,7 @@ cloc ./kodein-deep/src
|Dagger|1.7|1.41|37|
|Cayenne DI|1.8|2.05|37|
|Koin|1.8|2.56|16|
|Koin-Reflect|TODO|TODO|TODO|
|Kodein|2.4|2.93|17|
|Bootique|4.2|4.31|52|
|Guice|5.3|6.51|33|
Expand All @@ -104,6 +116,7 @@ cloc ./kodein-deep/src
|Dagger|2.0|2.70|534|
|Cayenne DI|2.0|3.70|1444|
|Koin|2.1|3.92|113|
|Koin-Reflect|TODO|TODO|TODO|
|Kodein|2.9|5.58|114|
|Bootique|4.3|5.79|549|
|Guice|5.4|8.70|530|
Expand Down
4 changes: 2 additions & 2 deletions baseline-deep/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
plugins {
kotlin("jvm").version("1.4.30-M1")
kotlin("jvm").version("1.4.31")
application
}

Expand All @@ -8,7 +8,7 @@ application {
}

repositories {
jcenter()
mavenCentral()
}

dependencies {
Expand Down
4 changes: 2 additions & 2 deletions baseline/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
plugins {
kotlin("jvm").version("1.4.30-M1")
kotlin("jvm").version("1.4.31")
application
}

Expand All @@ -8,7 +8,7 @@ application {
}

repositories {
jcenter()
mavenCentral()
}

dependencies {
Expand Down
2 changes: 1 addition & 1 deletion bootique-deep/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ application {
}

repositories {
jcenter()
mavenCentral()
maven {
url = uri("https://maven.objectstyle.org/nexus/content/repositories/bootique-snapshots/")
}
Expand Down
2 changes: 1 addition & 1 deletion bootique/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ application {
}

repositories {
jcenter()
mavenCentral()
maven {
url = uri("https://maven.objectstyle.org/nexus/content/repositories/bootique-snapshots/")
}
Expand Down
2 changes: 1 addition & 1 deletion cayennedi-deep/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ application {
}

repositories {
jcenter()
mavenCentral()
}

dependencies {
Expand Down
2 changes: 1 addition & 1 deletion cayennedi/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ application {
}

repositories {
jcenter()
mavenCentral()
}

dependencies {
Expand Down
4 changes: 2 additions & 2 deletions common-deep/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
plugins {
kotlin("jvm").version("1.4.30-M1")
kotlin("jvm").version("1.4.31")
}

repositories {
jcenter()
mavenCentral()
}

dependencies {
Expand Down
6 changes: 6 additions & 0 deletions common-deep/src/test/kotlin/GenerateKoin.kt
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,10 @@ fun main() {
single<Service$it> { DefaultService$it(get()) }
""".trimIndent())
}

(1..101).forEach {
println("""
singleBy<Service$it, DefaultService$it>()
""".trimIndent())
}
}
4 changes: 2 additions & 2 deletions common/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
plugins {
kotlin("jvm").version("1.4.30-M1")
kotlin("jvm").version("1.4.31")
}

repositories {
jcenter()
mavenCentral()
}

dependencies {
Expand Down
2 changes: 1 addition & 1 deletion dagger-deep/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ application {
}

repositories {
jcenter()
mavenCentral()
}

dependencies {
Expand Down
2 changes: 1 addition & 1 deletion dagger/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ application {
}

repositories {
jcenter()
mavenCentral()
}

dependencies {
Expand Down
4 changes: 2 additions & 2 deletions gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionSha256Sum=a7ca23b3ccf265680f2bfd35f1f00b1424f4466292c7337c85d46c9641b3f053
distributionUrl=https\://services.gradle.org/distributions/gradle-6.8-all.zip
distributionSha256Sum=9af5c8e7e2cd1a3b0f694a4ac262b9f38c75262e74a9e8b5101af302a6beadd7
distributionUrl=https\://services.gradle.org/distributions/gradle-6.8.3-all.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
4 changes: 2 additions & 2 deletions guice-deep/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ application {
}

repositories {
jcenter()
mavenCentral()
}

dependencies {
implementation(project(":common-deep"))

implementation("com.google.inject:guice:5.0.0-BETA-1")
implementation("com.google.inject:guice:5.0.1")
}
4 changes: 2 additions & 2 deletions guice/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ application {
}

repositories {
jcenter()
mavenCentral()
}

dependencies {
implementation(project(":common"))

implementation("com.google.inject:guice:5.0.0-BETA-1")
implementation("com.google.inject:guice:5.0.1")
}
20 changes: 20 additions & 0 deletions jvm/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
plugins {
kotlin("jvm").version("1.4.31")
application
}

application {
mainClass.set("org.objectstyle.jvm.MainKt")
}

tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile>().configureEach {
kotlinOptions.jvmTarget = "11"
}

repositories {
mavenCentral()
}

dependencies {
implementation(kotlin("stdlib-jdk8"))
}
3 changes: 3 additions & 0 deletions jvm/src/main/kotlin/org/objectstyle/jvm/Main.kt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
package org.objectstyle.jvm

fun main() {}
4 changes: 2 additions & 2 deletions kodein-deep/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
plugins {
kotlin("jvm").version("1.4.30-M1")
kotlin("jvm").version("1.4.31")
application
}

Expand All @@ -12,7 +12,7 @@ tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile>().configureEach
}

repositories {
jcenter()
mavenCentral()
}

dependencies {
Expand Down
4 changes: 2 additions & 2 deletions kodein/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
plugins {
kotlin("jvm").version("1.4.30-M1")
kotlin("jvm").version("1.4.31")
application
}

Expand All @@ -12,7 +12,7 @@ tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile>().configureEach
}

repositories {
jcenter()
mavenCentral()
}

dependencies {
Expand Down
6 changes: 3 additions & 3 deletions koin-deep/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
plugins {
kotlin("jvm").version("1.4.30-M1")
kotlin("jvm").version("1.4.31")
application
}

Expand All @@ -8,12 +8,12 @@ application {
}

repositories {
jcenter()
mavenCentral()
}

dependencies {
implementation(project(":common-deep"))

implementation(kotlin("stdlib-jdk8"))
implementation("org.koin:koin-core:2.2.1")
implementation("io.insert-koin:koin-core:3.0.1-beta-1")
}
20 changes: 20 additions & 0 deletions koin-reflect-deep/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
plugins {
kotlin("jvm").version("1.4.31")
application
}

application {
mainClass.set("io.heapy.koin.MainKt")
}

repositories {
mavenCentral()
}

dependencies {
implementation(project(":common-deep"))

implementation(kotlin("stdlib-jdk8"))
implementation("io.insert-koin:koin-core:3.0.1-beta-1")
implementation("io.insert-koin:koin-core-ext:3.0.1-beta-1")
}
Loading

0 comments on commit 3efa083

Please sign in to comment.