You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat: synchronize executions when attempting to remove an entry (ExpediaGroup#2012)
### 📝 Description
when attempting to remove an execution from the concurrent map
(executions) we need to make sure that the executions map is locked,
that way we will guarantee the atomic calculation of of synchronous
execution exhausted state
Co-authored-by: Samuel Vazquez <[email protected]>
Copy file name to clipboardExpand all lines: executions/graphql-kotlin-dataloader-instrumentation/src/main/kotlin/com/expediagroup/graphql/dataloader/instrumentation/extensions/CompletableFutureExtensions.kt
+4-6Lines changed: 4 additions & 6 deletions
Original file line number
Diff line number
Diff line change
@@ -35,18 +35,16 @@ fun <V> CompletableFuture<V>.dispatchIfNeeded(
35
35
val dataLoaderRegistry = environment.dataLoaderRegistry as?KotlinDataLoaderRegistry?:throwMissingKotlinDataLoaderRegistryException()
36
36
37
37
if (dataLoaderRegistry.dataLoadersInvokedOnDispatch()) {
Copy file name to clipboardExpand all lines: executions/graphql-kotlin-dataloader-instrumentation/src/main/kotlin/com/expediagroup/graphql/dataloader/instrumentation/syncexhaustion/state/SyncExecutionExhaustedState.kt
+19-19Lines changed: 19 additions & 19 deletions
Original file line number
Diff line number
Diff line change
@@ -71,11 +71,12 @@ class SyncExecutionExhaustedState(
Copy file name to clipboardExpand all lines: executions/graphql-kotlin-dataloader-instrumentation/src/test/kotlin/com/expediagroup/graphql/dataloader/instrumentation/syncexhaustion/DataLoaderSyncExecutionExhaustedInstrumentationTest.kt
+4-4Lines changed: 4 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -614,9 +614,9 @@ class DataLoaderSyncExecutionExhaustedInstrumentationTest {
614
614
fun`Instrumentation should not consider executions that thrown exceptions`() {
615
615
val executions =listOf(
616
616
ExecutionInput.newExecutionInput("query test1 { astronaut(id: 1) { id name } }").operationName("test1").build(),
617
-
ExecutionInput.newExecutionInput("query test2 { astronaut(id: 2) { id name } }").operationName("test2").build(),
618
-
ExecutionInput.newExecutionInput("query test3 { mission(id: 3) { id designation } }").operationName("test3").build(),
0 commit comments