CompletableFutureArtifactService
Java-friendly wrapper around an ArtifactService that it owns. Each method calls the suspend method of the same name and returns a CompletableFuture of its result, so Java callers never pass a Continuation. Canceling a future cancels its call, and close cancels every call in flight, then closes the service if it is AutoCloseable.
Functions
The wrapped artifact service, for code that has dropped into Kotlin.
Cancels calls in flight, then closes the service if it is AutoCloseable. Every later call returns a canceled future.
Calls ArtifactService.listVersions.
Calls ArtifactService.loadArtifact, which loads the latest version when version is null. The future completes with null if there is no such artifact.
Calls ArtifactService.saveArtifact; the future completes with the saved version.