diff --git a/lerna.json b/lerna.json index 1728208df0..e016e50225 100644 --- a/lerna.json +++ b/lerna.json @@ -1,6 +1,6 @@ { "$schema": "node_modules/lerna/schemas/lerna-schema.json", - "version": "2.29.26", + "version": "2.29.27", "npmClient": "yarn", "packages": [ "packages/*", diff --git a/packages/server/src/sdk/app/rows/search/sqs.ts b/packages/server/src/sdk/app/rows/search/sqs.ts index 2b3ed0c087..19b105443d 100644 --- a/packages/server/src/sdk/app/rows/search/sqs.ts +++ b/packages/server/src/sdk/app/rows/search/sqs.ts @@ -43,6 +43,7 @@ import { } from "./filters" import { dataFilters, PROTECTED_INTERNAL_COLUMNS } from "@budibase/shared-core" import { isSearchingByRowID } from "./utils" +import tracer from "dd-trace" const builder = new sql.Sql(SqlClient.SQL_LITE) const SQLITE_COLUMN_LIMIT = 2000 @@ -232,7 +233,11 @@ async function runSqlQuery( } const db = context.getAppDB() - return await db.sql(sql, bindings) + + return await tracer.trace("sqs.runSqlQuery", async span => { + span?.addTags({ sql }) + return await db.sql(sql, bindings) + }) } const response = await alias.queryWithAliasing(json, processSQLQuery) if (opts?.countTotalRows) {