Skip to content

Commit

Permalink
chore(canary-v2): Replace region with location. (#2106)
Browse files Browse the repository at this point in the history
  • Loading branch information
Matt Duftler committed Mar 30, 2018
1 parent 8edef9c commit 4b884f8
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ data class CanaryScopes(

data class CanaryScope(
val scope: String,
val region: String?,
val location: String?,
val start: Instant,
val end: Instant,
val step: Long = 60, // TODO: would be nice to use a Duration
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,9 @@ data class KayentaCanaryContext(
data class CanaryConfigScope(
val scopeName: String = "default",
val controlScope: String,
val controlRegion: String?,
val controlLocation: String?,
val experimentScope: String,
val experimentRegion: String?,
val experimentLocation: String?,
val startTimeIso: String?,
val endTimeIso: String?,
val step: Long = 60, // TODO: clarify this is in seconds
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -150,15 +150,15 @@ class KayentaCanaryStage(

val controlScope = CanaryScope(
scope.controlScope,
scope.controlRegion,
scope.controlLocation,
start,
end,
config.step.seconds,
scope.extendedScopeParams
)
val experimentScope = controlScope.copy(
scope = scope.experimentScope,
region = scope.experimentRegion
location = scope.experimentLocation
)

requestScopes[scope.scopeName] = CanaryScopes(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,13 +91,13 @@ object KayentaServiceTest : Spek({
scopes = mapOf("canary" to CanaryScopes(
CanaryScope(
scope = "covfefe-control",
region = "us-west-2",
location = "us-west-2",
start = startTime,
end = endTime
),
CanaryScope(
scope = "covfefe-experiment",
region = "us-west-2",
location = "us-west-2",
start = startTime,
end = endTime
)
Expand Down Expand Up @@ -236,7 +236,7 @@ object KayentaServiceTest : Spek({
"default": {
"controlScope": {
"scope": "myapp-v059",
"region": "us-central1",
"location": "us-central1",
"start": "2018-02-15T20:05:00Z",
"end": "2018-02-15T21:05:00Z",
"step": 60,
Expand All @@ -246,7 +246,7 @@ object KayentaServiceTest : Spek({
},
"experimentScope": {
"scope": "myapp-v059",
"region": "us-central1",
"location": "us-central1",
"start": "2018-02-15T20:05:00Z",
"end": "2018-02-15T21:05:00Z",
"step": 60,
Expand Down

0 comments on commit 4b884f8

Please sign in to comment.