diff options
Diffstat (limited to 'opendc-compute/opendc-compute-api/src')
4 files changed, 11 insertions, 6 deletions
diff --git a/opendc-compute/opendc-compute-api/src/main/kotlin/org/opendc/compute/api/ComputeClient.kt b/opendc-compute/opendc-compute-api/src/main/kotlin/org/opendc/compute/api/ComputeClient.kt index c26d0b8b..09cfe6f5 100644 --- a/opendc-compute/opendc-compute-api/src/main/kotlin/org/opendc/compute/api/ComputeClient.kt +++ b/opendc-compute/opendc-compute-api/src/main/kotlin/org/opendc/compute/api/ComputeClient.kt @@ -54,7 +54,7 @@ public interface ComputeClient : AutoCloseable { cpuCount: Int, memorySize: Long, labels: Map<String, String> = emptyMap(), - meta: Map<String, Any> = emptyMap() + meta: Map<String, Any> = emptyMap(), ): Flavor /** @@ -79,7 +79,7 @@ public interface ComputeClient : AutoCloseable { public fun newImage( name: String, labels: Map<String, String> = emptyMap(), - meta: Map<String, Any> = emptyMap() + meta: Map<String, Any> = emptyMap(), ): Image /** @@ -110,7 +110,7 @@ public interface ComputeClient : AutoCloseable { flavor: Flavor, labels: Map<String, String> = emptyMap(), meta: Map<String, Any> = emptyMap(), - start: Boolean = true + start: Boolean = true, ): Server /** diff --git a/opendc-compute/opendc-compute-api/src/main/kotlin/org/opendc/compute/api/InsufficientServerCapacityException.kt b/opendc-compute/opendc-compute-api/src/main/kotlin/org/opendc/compute/api/InsufficientServerCapacityException.kt index 8fbb7308..497d5266 100644 --- a/opendc-compute/opendc-compute-api/src/main/kotlin/org/opendc/compute/api/InsufficientServerCapacityException.kt +++ b/opendc-compute/opendc-compute-api/src/main/kotlin/org/opendc/compute/api/InsufficientServerCapacityException.kt @@ -26,4 +26,6 @@ package org.opendc.compute.api * This exception is thrown to indicate that the compute service does not have enough capacity at the moment to * fulfill a launch request. */ -public class InsufficientServerCapacityException(override val cause: Throwable? = null) : Exception("There was insufficient capacity available to satisfy the launch request") +public class InsufficientServerCapacityException( + override val cause: Throwable? = null, +) : Exception("There was insufficient capacity available to satisfy the launch request") diff --git a/opendc-compute/opendc-compute-api/src/main/kotlin/org/opendc/compute/api/ServerState.kt b/opendc-compute/opendc-compute-api/src/main/kotlin/org/opendc/compute/api/ServerState.kt index 2b5aebb1..a4d7d7d7 100644 --- a/opendc-compute/opendc-compute-api/src/main/kotlin/org/opendc/compute/api/ServerState.kt +++ b/opendc-compute/opendc-compute-api/src/main/kotlin/org/opendc/compute/api/ServerState.kt @@ -49,5 +49,5 @@ public enum class ServerState { /** * The server has been deleted and cannot be started later on. */ - DELETED + DELETED, } diff --git a/opendc-compute/opendc-compute-api/src/main/kotlin/org/opendc/compute/api/ServerWatcher.kt b/opendc-compute/opendc-compute-api/src/main/kotlin/org/opendc/compute/api/ServerWatcher.kt index cf995fc3..3229e101 100644 --- a/opendc-compute/opendc-compute-api/src/main/kotlin/org/opendc/compute/api/ServerWatcher.kt +++ b/opendc-compute/opendc-compute-api/src/main/kotlin/org/opendc/compute/api/ServerWatcher.kt @@ -32,5 +32,8 @@ public interface ServerWatcher { * @param server The server whose state has changed. * @param newState The new state of the server. */ - public fun onStateChanged(server: Server, newState: ServerState) {} + public fun onStateChanged( + server: Server, + newState: ServerState, + ) {} } |
