@@ -27,12 +27,12 @@ import kotlinx.coroutines.launch
2727
2828private val logger = logger { }
2929
30- typealias ArtifactResult = Result <Map <String , Artifact >? >
30+ typealias CachedVersionArtifact = Result <Map <String , Artifact >? >
3131
3232private val prefetchScope = CoroutineScope (Dispatchers .IO )
3333
3434fun Routing.artifactRoutes (
35- bindingsCache : LoadingCache <ActionCoords , ArtifactResult >,
35+ bindingsCache : LoadingCache <ActionCoords , CachedVersionArtifact >,
3636 prometheusRegistry : PrometheusMeterRegistry ? = null,
3737) {
3838 prometheusRegistry?.let {
@@ -50,15 +50,15 @@ fun Routing.artifactRoutes(
5050
5151private fun Route.artifact (
5252 prometheusRegistry : PrometheusMeterRegistry ? ,
53- bindingsCache : LoadingCache <ActionCoords , ArtifactResult >,
53+ bindingsCache : LoadingCache <ActionCoords , CachedVersionArtifact >,
5454 refresh : Boolean = false,
5555) {
5656 headArtifact(bindingsCache, prometheusRegistry, refresh)
5757 getArtifact(bindingsCache, prometheusRegistry, refresh)
5858}
5959
6060private fun Route.headArtifact (
61- bindingsCache : LoadingCache <ActionCoords , ArtifactResult >,
61+ bindingsCache : LoadingCache <ActionCoords , CachedVersionArtifact >,
6262 prometheusRegistry : PrometheusMeterRegistry ? ,
6363 refresh : Boolean ,
6464) {
@@ -78,7 +78,7 @@ private fun Route.headArtifact(
7878}
7979
8080private fun Route.getArtifact (
81- bindingsCache : LoadingCache <ActionCoords , ArtifactResult >,
81+ bindingsCache : LoadingCache <ActionCoords , CachedVersionArtifact >,
8282 prometheusRegistry : PrometheusMeterRegistry ? ,
8383 refresh : Boolean ,
8484) {
@@ -102,7 +102,7 @@ private fun Route.getArtifact(
102102
103103internal fun prefetchBindingArtifacts (
104104 coords : Collection <ActionCoords >,
105- bindingsCache : LoadingCache <ActionCoords , ArtifactResult >,
105+ bindingsCache : LoadingCache <ActionCoords , CachedVersionArtifact >,
106106) {
107107 prefetchScope.launch {
108108 bindingsCache.getAll(coords)
@@ -111,7 +111,7 @@ internal fun prefetchBindingArtifacts(
111111
112112private suspend fun ApplicationCall.toBindingArtifacts (
113113 refresh : Boolean ,
114- bindingsCache : LoadingCache <ActionCoords , ArtifactResult >,
114+ bindingsCache : LoadingCache <ActionCoords , CachedVersionArtifact >,
115115): Map <String , Artifact >? {
116116 val actionCoords = parameters.extractActionCoords(extractVersion = true )
117117
0 commit comments