Skip to content
Permalink
Browse files

First stage refactor

  • Loading branch information...
JoeHegarty committed Oct 1, 2019
1 parent 72386da commit 4822e5f1b30cff1f47c1f0cb9a7598f2dc5e8c0c
Showing with 1,523 additions and 3,844 deletions.
  1. +0 −3 CONTRIBUTING.md
  2. +0 −276 build.gradle
  3. +37 −0 build.gradle.kts
  4. +0 −24 docker/docker-compose-etcd.yml
  5. +0 −48 docker/docker-compose.yml
  6. +0 −4 docker/server/Dockerfile
  7. +0 −5 docker/server/entrypoint.sh
  8. +0 −9 gradle.properties
  9. +2 −2 gradlew
  10. +6 −4 settings.gradle → settings.gradle.kts
  11. +0 −28 src/orbit-application/build.gradle
  12. +47 −0 src/orbit-application/build.gradle.kts
  13. +1 −3 src/orbit-application/src/main/kotlin/orbit/application/App.kt
  14. +25 −0 src/orbit-client-sdk/build.gradle.kts
  15. +0 −14 src/orbit-client/build.gradle
  16. +0 −135 src/orbit-client/src/main/kotlin/orbit/client/OrbitClient.kt
  17. +0 −29 src/orbit-client/src/main/kotlin/orbit/client/OrbitClientConfig.kt
  18. +0 −25 src/orbit-client/src/main/kotlin/orbit/client/leasing/NodeLease.kt
  19. +0 −60 src/orbit-client/src/main/kotlin/orbit/client/leasing/NodeLeaser.kt
  20. +0 −43 src/orbit-client/src/main/kotlin/orbit/client/net/AuthInterceptor.kt
  21. +0 −27 src/orbit-client/src/main/kotlin/orbit/client/net/ConnectionHandler.kt
  22. +0 −18 src/orbit-client/src/main/kotlin/orbit/client/net/GrpcClient.kt
  23. +0 −17 src/orbit-client/src/main/kotlin/orbit/client/net/NodeStatus.kt
  24. +0 −24 src/orbit-client/src/main/kotlin/orbit/client/net/OrbitServiceLocator.kt
  25. +0 −45 src/orbit-client/src/test/kotlin/orbit/client/BaseIntegrationTest.kt
  26. +0 −47 src/orbit-client/src/test/kotlin/orbit/client/net/ServiceLocatorTests.kt
  27. +51 −0 src/orbit-common/build.gradle.kts
  28. +30 −0 src/orbit-common/src/commonMain/kotlin/orbit/common/concurrent/AsyncMap.kt
  29. +1 −2 ...commons/src/main → orbit-common/src/commonMain}/kotlin/orbit/common/concurrent/SupervisorScope.kt
  30. +12 −0 src/orbit-common/src/commonMain/kotlin/orbit/common/exception/GeneralExceptions.kt
  31. +8 −9 src/{orbit-commons/src/main → orbit-common/src/commonMain}/kotlin/orbit/common/util/Clock.kt
  32. +4 −4 .../ControlFlowUtils.kt → orbit-common/src/commonMain/kotlin/orbit/common/util/ControlFlowUtills.kt}
  33. +11 −26 src/{orbit-commons/src/main → orbit-common/src/commonMain}/kotlin/orbit/common/util/RNGUtils.kt
  34. +2 −0 src/{orbit-commons/src/main → orbit-common/src/commonMain}/kotlin/orbit/common/util/Stopwatch.kt
  35. +3 −3 src/{orbit-commons/build.gradle → orbit-common/src/commonTest/kotlin/orbit/common/test/RunTest.kt}
  36. +39 −0 src/orbit-common/src/commonTest/kotlin/orbit/common/util/ClockTest.kt
  37. +37 −35 ...-commons/src/test → orbit-common/src/commonTest}/kotlin/orbit/common/util/ControlFlowUtilsTest.kt
  38. +32 −0 src/orbit-common/src/commonTest/kotlin/orbit/common/util/RNGUtilsTest.kt
  39. +25 −0 src/orbit-common/src/commonTest/kotlin/orbit/common/util/StopwatchTest.kt
  40. +33 −0 src/orbit-common/src/jvmMain/kotlin/orbit/common/concurrent/jvm/HashMapBackedAsyncMap.kt
  41. +1 −1 ...n/orbit/common/concurrent → orbit-common/src/jvmMain/kotlin/orbit/common/concurrent/jvm}/Pools.kt
  42. +1 −1 ...common/concurrent → orbit-common/src/jvmMain/kotlin/orbit/common/concurrent/jvm}/ShutdownLatch.kt
  43. +18 −9 ...ComponentProvider.kt → orbit-common/src/jvmMain/kotlin/orbit/common/di/jvm/ComponentContainer.kt}
  44. +11 −0 src/orbit-common/src/jvmMain/kotlin/orbit/common/util/Clock.kt
  45. +5 −5 ...bit/common/concurrent → orbit-common/src/jvmTest/kotlin/orbit/common/concurrent/jvm}/PoolsTest.kt
  46. +3 −8 .../kotlin/orbit/client/BasicTest.kt → orbit-common/src/jvmTest/kotlin/orbit/common/test/RunTest.kt}
  47. +0 −18 src/orbit-commons/src/main/kotlin/orbit/common/collections/CollectionExtensions.kt
  48. +0 −30 src/orbit-commons/src/main/kotlin/orbit/common/collections/GraphTraverser.kt
  49. +0 −27 src/orbit-commons/src/main/kotlin/orbit/common/exception/GeneralExceptions.kt
  50. +0 −127 src/orbit-commons/src/main/kotlin/orbit/common/logging/Logger.kt
  51. +0 −54 src/orbit-commons/src/main/kotlin/orbit/common/logging/Logging.kt
  52. +0 −66 src/orbit-commons/src/main/kotlin/orbit/common/logging/LoggingContext.kt
  53. +0 −47 src/orbit-commons/src/main/kotlin/orbit/common/logging/impl/OrbitDefaultLogger.kt
  54. +0 −27 src/orbit-commons/src/test/kotlin/orbit/common/collections/CollectionExtensionsTest.kt
  55. +0 −47 src/orbit-commons/src/test/kotlin/orbit/common/collections/GraphTraverserTests.kt
  56. +0 −35 src/orbit-commons/src/test/kotlin/orbit/common/util/ClockTest.kt
  57. +0 −40 src/orbit-commons/src/test/kotlin/orbit/common/util/RNGUtilsTest.kt
  58. +0 −46 src/orbit-commons/src/test/kotlin/orbit/common/util/StopwatchTest.kt
  59. +0 −50 src/orbit-proto/build.gradle
  60. +76 −0 src/orbit-proto/build.gradle.kts
  61. +21 −0 src/orbit-proto/src/main/kotlin/orbit/shared/proto/Addressable.kt
  62. +12 −0 src/orbit-proto/src/main/kotlin/orbit/shared/proto/Headers.kt
  63. +85 −0 src/orbit-proto/src/main/kotlin/orbit/shared/proto/Messages.kt
  64. +30 −0 src/orbit-proto/src/main/kotlin/orbit/shared/proto/NodeManagement.kt
  65. +23 −0 src/orbit-proto/src/main/kotlin/orbit/shared/proto/Timestamp.kt
  66. +0 −20 src/orbit-proto/src/main/kotlin/orbit/shared/proto/util/TimestampUtils.kt
  67. +1 −8 src/orbit-proto/src/main/proto/orbit/shared/addressable.proto
  68. +1 −1 src/orbit-proto/src/main/proto/orbit/shared/connection.proto
  69. +10 −10 src/orbit-proto/src/main/proto/orbit/shared/messages.proto
  70. +17 −41 src/orbit-proto/src/main/proto/orbit/shared/node_management.proto
  71. +0 −22 src/orbit-proto/src/test/kotlin/orbit/shared/proto/util/ProtoUtilTests.kt
  72. +0 −14 src/orbit-server/build.gradle
  73. +30 −0 src/orbit-server/build.gradle.kts
  74. +73 −99 src/orbit-server/src/main/kotlin/orbit/server/OrbitServer.kt
  75. +20 −56 src/orbit-server/src/main/kotlin/orbit/server/OrbitServerConfig.kt
  76. +1 −1 src/orbit-server/src/main/kotlin/orbit/server/concurrent/RuntimeScopes.kt
  77. +0 −18 src/orbit-server/src/main/kotlin/orbit/server/config/InjectedWithConfig.kt
  78. +0 −73 src/orbit-server/src/main/kotlin/orbit/server/etcd/EtcdAddressableDirectory.kt
  79. +0 −142 src/orbit-server/src/main/kotlin/orbit/server/etcd/EtcdNodeDirectory.kt
  80. +0 −46 src/orbit-server/src/main/kotlin/orbit/server/local/InMemoryAddressableDirectory.kt
  81. +0 −90 src/orbit-server/src/main/kotlin/orbit/server/local/InMemoryNodeDirectory.kt
  82. +0 −30 src/orbit-server/src/main/kotlin/orbit/server/local/LocalFirstPlacementStrategy.kt
  83. +97 −0 src/orbit-server/src/main/kotlin/orbit/server/mesh/ClusterManager.kt
  84. +2 −2 src/orbit-server/src/main/kotlin/orbit/server/{net → mesh}/LeaseExpiration.kt
  85. +49 −0 src/orbit-server/src/main/kotlin/orbit/server/mesh/LocalNodeInfo.kt
  86. +15 −0 src/orbit-server/src/main/kotlin/orbit/server/mesh/NodeDirectory.kt
  87. +30 −0 src/orbit-server/src/main/kotlin/orbit/server/mesh/local/LocalNodeDirectory.kt
  88. +0 −26 src/orbit-server/src/main/kotlin/orbit/server/net/AddressableLease.kt
  89. +36 −0 src/orbit-server/src/main/kotlin/orbit/server/net/ClientConnection.kt
  90. +94 −0 src/orbit-server/src/main/kotlin/orbit/server/net/ConnectionManager.kt
  91. +0 −88 src/orbit-server/src/main/kotlin/orbit/server/net/Connections.kt
  92. +0 −68 src/orbit-server/src/main/kotlin/orbit/server/net/GrpcClient.kt
  93. +0 −39 src/orbit-server/src/main/kotlin/orbit/server/net/GrpcEndpoint.kt
  94. +0 −41 src/orbit-server/src/main/kotlin/orbit/server/net/GrpcMeshNodeClient.kt
  95. +0 −49 src/orbit-server/src/main/kotlin/orbit/server/net/Message.kt
  96. +0 −35 src/orbit-server/src/main/kotlin/orbit/server/net/NodeIdClientInterceptor.kt
  97. +0 −36 src/orbit-server/src/main/kotlin/orbit/server/net/NodeIdServerInterceptor.kt
  98. +0 −26 src/orbit-server/src/main/kotlin/orbit/server/net/NodeLease.kt
  99. +0 −80 src/orbit-server/src/main/kotlin/orbit/server/net/NodeLeases.kt
  100. +0 −133 src/orbit-server/src/main/kotlin/orbit/server/pipeline/Pipeline.kt
  101. +0 −47 src/orbit-server/src/main/kotlin/orbit/server/pipeline/PipelineContext.kt
  102. +0 −27 src/orbit-server/src/main/kotlin/orbit/server/pipeline/PipelineSteps.kt
  103. +0 −44 src/orbit-server/src/main/kotlin/orbit/server/pipeline/steps/AddressablePipelineStep.kt
  104. +0 −20 src/orbit-server/src/main/kotlin/orbit/server/pipeline/steps/BlankPipelineStep.kt
  105. +0 −33 src/orbit-server/src/main/kotlin/orbit/server/pipeline/steps/ErrorPipelineStep.kt
  106. +0 −34 src/orbit-server/src/main/kotlin/orbit/server/pipeline/steps/LeasePipelineStep.kt
  107. +0 −18 src/orbit-server/src/main/kotlin/orbit/server/pipeline/steps/PipelineStep.kt
  108. +0 −47 src/orbit-server/src/main/kotlin/orbit/server/pipeline/steps/RoutingPipelineStep.kt
  109. +0 −122 src/orbit-server/src/main/kotlin/orbit/server/proto/Conversions.kt
  110. +0 −17 src/orbit-server/src/main/kotlin/orbit/server/routing/AddressableDirectory.kt
  111. +0 −14 src/orbit-server/src/main/kotlin/orbit/server/routing/AddressablePlacementStrategy.kt
  112. +0 −19 src/orbit-server/src/main/kotlin/orbit/server/routing/LocalNodeInfo.kt
  113. +0 −15 src/orbit-server/src/main/kotlin/orbit/server/routing/MeshNode.kt
  114. +0 −19 src/orbit-server/src/main/kotlin/orbit/server/routing/NodeDirectory.kt
  115. +0 −56 src/orbit-server/src/main/kotlin/orbit/server/routing/NodeInfo.kt
  116. +0 −28 src/orbit-server/src/main/kotlin/orbit/server/routing/Route.kt
  117. +0 −56 src/orbit-server/src/main/kotlin/orbit/server/routing/Router.kt
  118. +29 −0 src/orbit-server/src/main/kotlin/orbit/server/service/ConnectionService.kt
  119. +41 −0 src/orbit-server/src/main/kotlin/orbit/server/service/GrpcEndpoint.kt
  120. +53 −0 src/orbit-server/src/main/kotlin/orbit/server/service/NodeManagementService.kt
  121. +44 −0 src/orbit-server/src/main/kotlin/orbit/server/service/ServerAuthInterceptor.kt
  122. +0 −23 src/orbit-server/src/test/kotlin/LocalClientNode.kt
  123. +0 −148 src/orbit-server/src/test/kotlin/local/InMemoryNodeDirectoryTest.kt
  124. +0 −150 src/orbit-server/src/test/kotlin/orbit/server/routing/RouterTest.kt
  125. +46 −0 src/orbit-shared/build.gradle.kts
  126. +1 −1 ...ble/Addressables.kt → orbit-shared/src/commonMain/kotlin/orbit/shared/addressable/Addressable.kt}
  127. +12 −0 src/orbit-shared/src/commonMain/kotlin/orbit/shared/mesh/Exception.kt
  128. +13 −0 src/orbit-shared/src/commonMain/kotlin/orbit/shared/mesh/NodeCapabilities.kt
  129. +3 −5 ...rc/main/kotlin/orbit/server/net → orbit-shared/src/commonMain/kotlin/orbit/shared/mesh}/NodeId.kt
  130. +17 −0 src/orbit-shared/src/commonMain/kotlin/orbit/shared/mesh/NodeInfo.kt
  131. +17 −0 src/orbit-shared/src/commonMain/kotlin/orbit/shared/mesh/NodeLease.kt
  132. +22 −0 src/orbit-shared/src/commonMain/kotlin/orbit/shared/net/Message.kt
  133. +11 −0 src/orbit-shared/src/commonMain/kotlin/orbit/shared/net/PortBinding.kt
  134. +25 −0 src/orbit-shared/src/commonMain/kotlin/orbit/shared/time/Timestamp.kt
  135. +21 −0 src/orbit-shared/src/jvmMain/kotlin/orbit/shared/time/Timestamp.kt

This file was deleted.

This file was deleted.

@@ -0,0 +1,37 @@
/*
Copyright (C) 2015 - 2019 Electronic Arts Inc. All rights reserved.
This file is part of the Orbit Project <https://www.orbit.cloud>.
See license in LICENSE.
*/

import org.jetbrains.kotlin.gradle.dsl.KotlinJvmCompile

val grpcVersion by extra("1.23.0")
val grpcKotlinVersion by extra("0.1.1")
val protobufVersion by extra("3.9.1")
val kotlinCoroutinesVersion by extra("1.3.1")
val slf4jVersion by extra("1.7.26")


plugins {
val kotlinVersion = "1.3.50"

base
kotlin("multiplatform") version kotlinVersion apply false
}

allprojects {
repositories {
mavenCentral()
jcenter()
}
}

subprojects {
tasks.withType<KotlinJvmCompile>().all {
kotlinOptions {
jvmTarget = "1.8"
}
}
}

This file was deleted.

This file was deleted.

This file was deleted.

0 comments on commit 4822e5f

Please sign in to comment.
You can’t perform that action at this time.