Navigation

    APPDRAG Community

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Popular

    REMINDER

    Please be respectful of all AppDragers! Keep it really civil so that we can make the AppDrag community of builders as embracing, positive and inspiring as possible.

    Sentry.io Error tracking integration

    Features requests
    2
    2
    201
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Daniel Mulroy
      Daniel Mulroy last edited by

      Hello team,

      I'm using Sentry.io to track errors on the front-end. They also support backend Node.js, and AWS Lambda.

      You can implement it one function at a time, but they also offer an automatic integration with these steps:
      https://docs.sentry.io/product/integrations/aws-lambda/

      Is integrating with something like this possible?

      I've been integrating on a function-by-function basis, but I have 122 functions, so it could take a while 😉

      Also, once I integrate their code on a function-by-function basis (here's an example of the setup code):

      const Sentry = require("@sentry/serverless");
      Sentry.AWSLambda.init({
        dsn: 'https://my-project-id@my-subdomain.ingest.sentry.io/another-project-id',
        tracesSampleRate: 1.0,
      });
      
      exports.handler = Sentry.AWSLambda.wrapHandler(async (event, context, callback) => {
      
      // code goes here
      
      });
      
      

      I'm having trouble testing the code locally, because the Sentry code thinks it's in a serverless context, with a bunch of context and env variables I don't have locally.

      Anyway, would love to see if something like this is possible.

      1 Reply Last reply Reply Quote 0
      • Wassim
        Wassim last edited by

        Hello,

        As your function runtime is under AWS Lambda you can use it to debug locally your functions.
        https://docs.aws.amazon.com/serverless-application-model/latest/developerguide/serverless-sam-cli-using-invoke.html

        1 Reply Last reply Reply Quote 0
        • First post
          Last post