-
Notifications
You must be signed in to change notification settings - Fork 70
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'upstream/main' into go/command_response…
…_struct
- Loading branch information
Showing
67 changed files
with
9,974 additions
and
1,963 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
### Kotlin ### | ||
.gradle | ||
build/ | ||
!gradle/wrapper/gradle-wrapper.jar | ||
!**/src/main/**/build/ | ||
!**/src/test/**/build/ | ||
|
||
### Scala ### | ||
target | ||
*.class | ||
|
||
### Node ### | ||
*.js | ||
|
||
### IntelliJ IDEA ### | ||
.idea/modules.xml | ||
.idea/jarRepositories.xml | ||
.idea/compiler.xml | ||
.idea/libraries/ | ||
*.iws | ||
*.iml | ||
*.ipr | ||
out/ | ||
!**/src/main/**/out/ | ||
!**/src/test/**/out/ | ||
.bsp | ||
|
||
### Eclipse ### | ||
.apt_generated | ||
.classpath | ||
.factorypath | ||
.project | ||
.settings | ||
.springBeans | ||
.sts4-cache | ||
bin/ | ||
!**/src/main/**/bin/ | ||
!**/src/test/**/bin/ | ||
|
||
### NetBeans ### | ||
/nbproject/private/ | ||
/nbbuild/ | ||
/dist/ | ||
/nbdist/ | ||
/.nb-gradle/ | ||
|
||
### VS Code ### | ||
.vscode/ | ||
|
||
### Mac OS ### | ||
.DS_Store |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
## Run | ||
Ensure that you have a server running on "localhost" on port "6379". To run the ClusterExample, make sure that the server has cluster mode enabled. If the server is running on a different host and/or port, update the StandaloneExample or ClusterExample with a configuration that matches your server settings. | ||
|
||
To run the Standalone example: | ||
```shell | ||
cd valkey-glide/examples/kotlin | ||
./gradlew runStandalone | ||
``` | ||
|
||
To run the Cluster example: | ||
```shell | ||
cd valkey-glide/examples/kotlin | ||
./gradlew runCluster | ||
``` | ||
|
||
## Version | ||
These examples are running `valkey-glide` version `1.+`. In order to change the version, update the following section in the `build.gradle.kts` file: | ||
```kotlin | ||
dependencies { | ||
implementation("io.valkey:valkey-glide:1.+:$classifier") | ||
} | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
plugins { | ||
kotlin("jvm") version "1.9.23" | ||
application | ||
id("com.google.osdetector") version "1.7.3" | ||
} | ||
|
||
group = "org.example" | ||
version = "1.0-SNAPSHOT" | ||
|
||
repositories { | ||
mavenCentral() | ||
} | ||
|
||
val os = osdetector.os | ||
val classifier = osdetector.classifier | ||
fun nettyTransport(): String { | ||
if (os == "osx") | ||
return "netty-transport-native-kqueue" | ||
else if (os == "linux") | ||
return "netty-transport-native-epoll" | ||
else | ||
throw Exception("Unsupported operating system $os") | ||
} | ||
|
||
dependencies { | ||
testImplementation(kotlin("test")) | ||
implementation("io.valkey:valkey-glide:1.+:$classifier") | ||
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.7.1") | ||
} | ||
|
||
tasks.test { | ||
useJUnitPlatform() | ||
} | ||
|
||
kotlin { | ||
jvmToolchain(11) | ||
} | ||
|
||
tasks.register<JavaExec>("runStandalone") { | ||
group = "application" | ||
description = "Run the standalone example" | ||
classpath = sourceSets.main.get().runtimeClasspath | ||
mainClass = "glide.examples.StandaloneExample" | ||
} | ||
|
||
tasks.register<JavaExec>("runCluster") { | ||
group = "application" | ||
description = "Run the cluster example" | ||
classpath = sourceSets.main.get().runtimeClasspath | ||
mainClass = "glide.examples.ClusterExample" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
kotlin.code.style=official |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
#Tue Jul 09 17:54:28 PDT 2024 | ||
distributionBase=GRADLE_USER_HOME | ||
distributionPath=wrapper/dists | ||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.5-bin.zip | ||
zipStoreBase=GRADLE_USER_HOME | ||
zipStorePath=wrapper/dists |
Oops, something went wrong.