https://pulumi.com logo
#aws
Title
# aws
f

future-diamond-31373

08/18/2021, 8:16 PM
Hey has anyone successfully hooked up x-ray with pulumi’s magic function lambdas in typescript? With the traditional sdk xray integration looks something like this
Copy code
import Lambda from 'aws-sdk/clients/lambda';
import { captureAWSClient } from 'aws-xray-sdk-core';

const client = captureAWSClient(new Lambda());
However since our lambda functions are managed through pulumi, there isn’t an easy way to apply this wrapper. Or if there is, I’ve completely missed it. I checked out the pulumi docs on the functiontracingconfig parameter, which gives me a high level trace (lambda execution time), but doesn’t go into the subcalls within the lambda like the capture client normally would.
g

great-sunset-355

08/20/2021, 3:05 AM
I'm not sure what mean by magic functions? AWS package does not offer you more than AWS Console does. Since Xray is a 3rd party package you need to install it. The thing you are missing is the packaging step that pulumi does not offer (yet?) https://pulumi-community.slack.com/archives/C01PF3E1B8V/p1629384278059100?thread_ts=1629368996.058400&cid=C01PF3E1B8V
4 Views