Skip to content

Commit 5c60e15

Browse files
committed
foldSpan
1 parent 55caa4c commit 5c60e15

File tree

1 file changed

+3
-3
lines changed
  • http/src/main/scala/org/broadinstitute/dsde/workbench/leonardo/http/api

1 file changed

+3
-3
lines changed

http/src/main/scala/org/broadinstitute/dsde/workbench/leonardo/http/api/AppRoutes.scala

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ import org.broadinstitute.dsde.workbench.leonardo.http.api.AppV2Routes.{
1818
listAppResponseEncoder
1919
}
2020
import org.broadinstitute.dsde.workbench.leonardo.http.service.AppService
21+
import org.broadinstitute.dsde.workbench.leonardo.http.spanResource
2122
import org.broadinstitute.dsde.workbench.model.UserInfo
2223
import org.broadinstitute.dsde.workbench.model.google.GoogleProject
2324
import org.broadinstitute.dsde.workbench.openTelemetry.OpenTelemetryMetrics
@@ -196,9 +197,8 @@ class AppRoutes(kubernetesService: AppService[IO], userInfoDirectives: UserInfoD
196197
private def foldSpan(apiCall: IO[Unit], apiName: String)(implicit ev: Ask[IO, AppContext]): IO[Unit] =
197198
for {
198199
ctx <- ev.ask[AppContext]
199-
apiCall = kubernetesService.updateAppConfig(userInfo, CloudContext.Gcp(googleProject), appName, req)
200-
_ <- ctx.span.fold(apiCall)(span => spanResource[IO](span, "updateApp").use(_ => apiCall))
201-
} yield StatusCodes.Accepted
200+
_ <- ctx.span.fold(apiCall)(span => spanResource[IO](span, apiName).use(_ => apiCall))
201+
} yield ()
202202

203203
private[api] def deleteAppHandler(userInfo: UserInfo,
204204
googleProject: GoogleProject,

0 commit comments

Comments
 (0)