Upgrade dd-trace, add APM tracing around key commands, fix tags should be attached to root spans (#3243)
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import { Transaction } from "sequelize";
|
||||
import { sequelize } from "@server/database/sequelize";
|
||||
import Logger from "@server/logging/logger";
|
||||
import { APM } from "@server/logging/tracing";
|
||||
import {
|
||||
ApiKey,
|
||||
Attachment,
|
||||
@@ -20,7 +21,7 @@ import {
|
||||
Share,
|
||||
} from "@server/models";
|
||||
|
||||
export default async function teamPermanentDeleter(team: Team) {
|
||||
async function teamPermanentDeleter(team: Team) {
|
||||
if (!team.deletedAt) {
|
||||
throw new Error(
|
||||
`Cannot permanently delete ${team.id} team. Please delete it and try again.`
|
||||
@@ -203,3 +204,5 @@ export default async function teamPermanentDeleter(team: Team) {
|
||||
throw err;
|
||||
}
|
||||
}
|
||||
|
||||
export default APM.traceFunction({})(teamPermanentDeleter);
|
||||
|
||||
Reference in New Issue
Block a user