Skip to content

Commit

Permalink
instrument tracing without capturing inputs or outputs
Browse files Browse the repository at this point in the history
  • Loading branch information
bpholt committed Dec 4, 2023
1 parent 18d3949 commit b6431f0
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,10 @@ class TerminationEventHandler extends IOLambda[SnsEvent, INothing] {
given Random[IO] <- Random.scalaUtilRandom[IO].toResource
entryPoint <- XRay.entryPoint[IO]()
awsEnv <- AwsEnvironment.default(client, AwsRegion.US_WEST_2)
ecs <- AwsClient(ECS, awsEnv).map(_.traceWithInputs).map(EcsAlg(_))
ecs <- AwsClient(ECS, awsEnv).map(_.instrumentAndTrace).map(EcsAlg(_))
autoscalingClient <- AwsClient(AutoScaling, awsEnv)
sns <- AwsClient(SNS, awsEnv).map(SnsAlg[IO](_).traceWithInputs)
autoscaling = AutoScalingAlg[IO](autoscalingClient, sns).traceWithInputs
sns <- AwsClient(SNS, awsEnv).map(SnsAlg[IO](_).instrumentAndTrace)
autoscaling = AutoScalingAlg[IO](autoscalingClient, sns).instrumentAndTrace
bridgeFunction = TerminationEventBridge(ecs, autoscaling)
given Logger[IO] <- LoggerFactory[IO].create.toResource
} yield LifecycleHookHandler(entryPoint, "TerminationEventHandler")(bridgeFunction)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ class ScaleOutPendingEventHandler extends IOLambda[SnsEvent, INothing] {
given Random[IO] <- Random.scalaUtilRandom[IO].toResource
entryPoint <- XRay.entryPoint[IO]()
awsEnv <- AwsEnvironment.default(client, AwsRegion.US_WEST_2)
ecs <- AwsClient(ECS, awsEnv).map(_.traceWithInputs).map(EcsAlg(_))
ecs <- AwsClient(ECS, awsEnv).map(_.instrumentAndTrace).map(EcsAlg(_))
autoscalingClient <- AwsClient(AutoScaling, awsEnv)
sns <- AwsClient(SNS, awsEnv).map(SnsAlg[IO](_))
ec2Client <- AwsClient(EC2, awsEnv).map(Ec2Alg[IO](_))
Expand Down

0 comments on commit b6431f0

Please sign in to comment.