Skip to content

Commit

Permalink
feat: include service name to sentry logs (#7841)
Browse files Browse the repository at this point in the history
* feat: attach service name to sentry log

* Update packages/auth/src/config/plugins.ts

Co-authored-by: Riku Rouvila <[email protected]>

* Update packages/config/src/config/plugins.ts

Co-authored-by: Riku Rouvila <[email protected]>

* Update packages/documents/src/config/plugins.ts

Co-authored-by: Riku Rouvila <[email protected]>

* Update packages/gateway/src/config/plugins.ts

Co-authored-by: Riku Rouvila <[email protected]>

* Update packages/metrics/src/config/plugins.ts

Co-authored-by: Riku Rouvila <[email protected]>

* Update packages/notification/src/config/plugins.ts

Co-authored-by: Riku Rouvila <[email protected]>

* Update packages/search/src/config/plugins.ts

Co-authored-by: Riku Rouvila <[email protected]>

* Update packages/user-mgnt/src/config/plugins.ts

Co-authored-by: Riku Rouvila <[email protected]>

* Update packages/webhooks/src/config/plugins.ts

Co-authored-by: Riku Rouvila <[email protected]>

* Update packages/workflow/src/config/plugins.ts

Co-authored-by: Riku Rouvila <[email protected]>

---------

Co-authored-by: Riku Rouvila <[email protected]>
  • Loading branch information
jamil314 and rikukissa authored Oct 31, 2024
1 parent ad5c9ed commit b48fdfc
Show file tree
Hide file tree
Showing 10 changed files with 40 additions and 10 deletions.
5 changes: 4 additions & 1 deletion packages/auth/src/config/plugins.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,10 @@ export default function getPlugins() {
options: {
client: {
environment: process.env.DOMAIN,
dsn: env.SENTRY_DSN
dsn: env.SENTRY_DSN,
initialScope: {
tags: { service: 'auth' }
}
},
catchLogErrors: true
}
Expand Down
5 changes: 4 additions & 1 deletion packages/config/src/config/plugins.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,10 @@ export default function getPlugins() {
options: {
client: {
environment: env.DOMAIN,
dsn: env.SENTRY_DSN
dsn: env.SENTRY_DSN,
initialScope: {
tags: { service: 'config' }
}
},
catchLogErrors: true
}
Expand Down
5 changes: 4 additions & 1 deletion packages/documents/src/config/plugins.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,10 @@ export default function getPlugins() {
options: {
client: {
environment: process.env.DOMAIN,
dsn: SENTRY_DSN
dsn: SENTRY_DSN,
initialScope: {
tags: { service: 'documents' }
}
},
catchLogErrors: true
}
Expand Down
5 changes: 4 additions & 1 deletion packages/gateway/src/config/plugins.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,10 @@ export const getPlugins = () => {
options: {
client: {
dsn: SENTRY_DSN,
environment: process.env.DOMAIN
environment: process.env.DOMAIN,
initialScope: {
tags: { service: 'gateway' }
}
},
catchLogErrors: true
}
Expand Down
5 changes: 4 additions & 1 deletion packages/metrics/src/config/plugins.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,10 @@ export default function getPlugins() {
options: {
client: {
environment: process.env.DOMAIN,
dsn: SENTRY_DSN
dsn: SENTRY_DSN,
initialScope: {
tags: { service: 'metrics' }
}
},
catchLogErrors: true
}
Expand Down
5 changes: 4 additions & 1 deletion packages/notification/src/config/plugins.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,10 @@ export default function getPlugins() {
options: {
client: {
environment: process.env.DOMAIN,
dsn: SENTRY_DSN
dsn: SENTRY_DSN,
initialScope: {
tags: { service: 'notification' }
}
},
catchLogErrors: true
}
Expand Down
5 changes: 4 additions & 1 deletion packages/search/src/config/plugins.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,10 @@ export default function getPlugins() {
options: {
client: {
environment: process.env.DOMAIN,
dsn: SENTRY_DSN
dsn: SENTRY_DSN,
initialScope: {
tags: { service: 'search' }
}
},
catchLogErrors: true
}
Expand Down
5 changes: 4 additions & 1 deletion packages/user-mgnt/src/config/plugins.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,10 @@ export default function getPlugins() {
options: {
client: {
environment: process.env.DOMAIN,
dsn: SENTRY_DSN
dsn: SENTRY_DSN,
initialScope: {
tags: { service: 'user-mgnt' }
}
},
catchLogErrors: true
}
Expand Down
5 changes: 4 additions & 1 deletion packages/webhooks/src/config/plugins.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,10 @@ export default function getPlugins() {
options: {
client: {
environment: process.env.DOMAIN,
dsn: SENTRY_DSN
dsn: SENTRY_DSN,
initialScope: {
tags: { service: 'webhooks' }
}
},
catchLogErrors: true
}
Expand Down
5 changes: 4 additions & 1 deletion packages/workflow/src/config/plugins.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,10 @@ export default function getPlugins() {
options: {
client: {
environment: process.env.DOMAIN,
dsn: SENTRY_DSN
dsn: SENTRY_DSN,
initialScope: {
tags: { service: 'workflow' }
}
},
catchLogErrors: true
}
Expand Down

0 comments on commit b48fdfc

Please sign in to comment.