summaryrefslogtreecommitdiff
path: root/opendc-faas/opendc-faas-service
diff options
context:
space:
mode:
authorFabian Mastenbroek <mail.fabianm@gmail.com>2022-10-06 15:34:19 +0200
committerGitHub <noreply@github.com>2022-10-06 15:34:19 +0200
commit7ba3b953300c46b4e3afcde17cd3dd14b1af8406 (patch)
tree950ba678869ec868c26ab3b95b57e4cabadb23c7 /opendc-faas/opendc-faas-service
parentc2047d09b27b0c05f5c203509dde524e17d3b729 (diff)
parent47357afd16f928260db34d4dd3e686fb9ee7c5ff (diff)
merge: Update build and runtime dependencies (#107)
This pull request updates the build and runtime dependencies used by OpenDC to their latest version compatible with the project. ## Implementation Notes :hammer_and_pick: * Update simulator dependency versions * Remove unused distribution conventions * Update next version to 3.0 * Eliminate use of wildcard imports * Switch to Spotless for formatting
Diffstat (limited to 'opendc-faas/opendc-faas-service')
-rw-r--r--opendc-faas/opendc-faas-service/src/main/kotlin/org/opendc/faas/service/FunctionObject.kt2
-rw-r--r--opendc-faas/opendc-faas-service/src/main/kotlin/org/opendc/faas/service/internal/FaaSFunctionImpl.kt2
-rw-r--r--opendc-faas/opendc-faas-service/src/main/kotlin/org/opendc/faas/service/internal/FaaSServiceImpl.kt10
-rw-r--r--opendc-faas/opendc-faas-service/src/test/kotlin/org/opendc/faas/service/FaaSServiceTest.kt9
4 files changed, 16 insertions, 7 deletions
diff --git a/opendc-faas/opendc-faas-service/src/main/kotlin/org/opendc/faas/service/FunctionObject.kt b/opendc-faas/opendc-faas-service/src/main/kotlin/org/opendc/faas/service/FunctionObject.kt
index d953f737..091e82a8 100644
--- a/opendc-faas/opendc-faas-service/src/main/kotlin/org/opendc/faas/service/FunctionObject.kt
+++ b/opendc-faas/opendc-faas-service/src/main/kotlin/org/opendc/faas/service/FunctionObject.kt
@@ -25,7 +25,7 @@ package org.opendc.faas.service
import org.apache.commons.math3.stat.descriptive.DescriptiveStatistics
import org.opendc.faas.service.deployer.FunctionInstance
import org.opendc.faas.service.telemetry.FunctionStats
-import java.util.*
+import java.util.UUID
/**
* An [FunctionObject] represents the service's view of a serverless function.
diff --git a/opendc-faas/opendc-faas-service/src/main/kotlin/org/opendc/faas/service/internal/FaaSFunctionImpl.kt b/opendc-faas/opendc-faas-service/src/main/kotlin/org/opendc/faas/service/internal/FaaSFunctionImpl.kt
index bd7f13f6..36532aa8 100644
--- a/opendc-faas/opendc-faas-service/src/main/kotlin/org/opendc/faas/service/internal/FaaSFunctionImpl.kt
+++ b/opendc-faas/opendc-faas-service/src/main/kotlin/org/opendc/faas/service/internal/FaaSFunctionImpl.kt
@@ -24,7 +24,7 @@ package org.opendc.faas.service.internal
import org.opendc.faas.api.FaaSFunction
import org.opendc.faas.service.FunctionObject
-import java.util.*
+import java.util.UUID
/**
* A [FaaSFunction] implementation that is passed to clients.
diff --git a/opendc-faas/opendc-faas-service/src/main/kotlin/org/opendc/faas/service/internal/FaaSServiceImpl.kt b/opendc-faas/opendc-faas-service/src/main/kotlin/org/opendc/faas/service/internal/FaaSServiceImpl.kt
index 4ee55dea..901213af 100644
--- a/opendc-faas/opendc-faas-service/src/main/kotlin/org/opendc/faas/service/internal/FaaSServiceImpl.kt
+++ b/opendc-faas/opendc-faas-service/src/main/kotlin/org/opendc/faas/service/internal/FaaSServiceImpl.kt
@@ -22,8 +22,12 @@
package org.opendc.faas.service.internal
-import kotlinx.coroutines.*
+import kotlinx.coroutines.CoroutineScope
+import kotlinx.coroutines.InternalCoroutinesApi
+import kotlinx.coroutines.Job
+import kotlinx.coroutines.cancel
import kotlinx.coroutines.intrinsics.startCoroutineCancellable
+import kotlinx.coroutines.suspendCancellableCoroutine
import mu.KotlinLogging
import org.opendc.common.util.Pacer
import org.opendc.faas.api.FaaSClient
@@ -41,7 +45,9 @@ import org.opendc.faas.service.telemetry.SchedulerStats
import java.lang.IllegalStateException
import java.time.Clock
import java.time.Duration
-import java.util.*
+import java.util.ArrayDeque
+import java.util.Random
+import java.util.UUID
import kotlin.coroutines.Continuation
import kotlin.coroutines.CoroutineContext
import kotlin.coroutines.resumeWithException
diff --git a/opendc-faas/opendc-faas-service/src/test/kotlin/org/opendc/faas/service/FaaSServiceTest.kt b/opendc-faas/opendc-faas-service/src/test/kotlin/org/opendc/faas/service/FaaSServiceTest.kt
index 28234cf4..97ffc5a5 100644
--- a/opendc-faas/opendc-faas-service/src/test/kotlin/org/opendc/faas/service/FaaSServiceTest.kt
+++ b/opendc-faas/opendc-faas-service/src/test/kotlin/org/opendc/faas/service/FaaSServiceTest.kt
@@ -22,8 +22,11 @@
package org.opendc.faas.service
-import io.mockk.*
-import org.junit.jupiter.api.Assertions.*
+import io.mockk.every
+import io.mockk.mockk
+import org.junit.jupiter.api.Assertions.assertEquals
+import org.junit.jupiter.api.Assertions.assertNotNull
+import org.junit.jupiter.api.Assertions.assertNull
import org.junit.jupiter.api.Test
import org.junit.jupiter.api.assertDoesNotThrow
import org.junit.jupiter.api.assertThrows
@@ -32,7 +35,7 @@ import org.opendc.faas.service.deployer.FunctionDeployer
import org.opendc.faas.service.deployer.FunctionInstance
import org.opendc.faas.service.deployer.FunctionInstanceState
import org.opendc.simulator.kotlin.runSimulation
-import java.util.*
+import java.util.UUID
/**
* Test suite for the [FaaSService] implementation.