All Projects → mentos1386 → Nest Raven

mentos1386 / Nest Raven

Licence: mit
Sentry Raven Module for Nest.js Framework

Programming Languages

typescript
32286 projects

Projects that are alternatives of or similar to Nest Raven

ogma
A monorepo for the ogma logger and related packages
Stars: ✭ 201 (+63.41%)
Mutual labels:  module, nest
Ipfs Mini
A super tiny module for querying IPFS that works in the browser and node.
Stars: ✭ 115 (-6.5%)
Mutual labels:  module
Rest Nestjs Postgres
CrudJS implemented as a REST API, using Nest.js and Postgres
Stars: ✭ 93 (-24.39%)
Mutual labels:  nest
Yii2 Rest
Yii2 REST Client
Stars: ✭ 109 (-11.38%)
Mutual labels:  module
Octoposh
The Octopus Deploy Powershell module
Stars: ✭ 96 (-21.95%)
Mutual labels:  module
Logrus
Hooks for logrus logging
Stars: ✭ 110 (-10.57%)
Mutual labels:  sentry
Raven Aiohttp
An aiohttp transport for raven-python
Stars: ✭ 92 (-25.2%)
Mutual labels:  sentry
Tinypart
TinyPart is an iOS modularization framework implemented by Ojective-C. It also supports URL-routing and inter-module communication. TinyPart是一个由Objective-C编写的面向协议的iOS模块化框架,同时它还支持URL路由和模块间通信机制。
Stars: ✭ 120 (-2.44%)
Mutual labels:  module
Node Hot Loader
Hot module replacement (hot reload) for Node.js applications. Develop without server restarting.
Stars: ✭ 111 (-9.76%)
Mutual labels:  module
Nest
A progressive Node.js framework for building efficient, scalable, and enterprise-grade server-side applications on top of TypeScript & JavaScript (ES6, ES7, ES8) 🚀
Stars: ✭ 42,981 (+34843.9%)
Mutual labels:  nest
Raven
Raven is a Package Manager for Chez Scheme
Stars: ✭ 107 (-13.01%)
Mutual labels:  module
Magento2 Sentry
Magento 2 module to log to Sentry
Stars: ✭ 99 (-19.51%)
Mutual labels:  sentry
Attic Sentry
Mirror of Apache Sentry
Stars: ✭ 109 (-11.38%)
Mutual labels:  sentry
Raven.cr
Raven is a Crystal client for Sentry
Stars: ✭ 96 (-21.95%)
Mutual labels:  sentry
Sentry Php
The official PHP SDK for Sentry (sentry.io)
Stars: ✭ 1,591 (+1193.5%)
Mutual labels:  sentry
Breaker
🚧 Flexible mechanism to make execution flow interruptible.
Stars: ✭ 93 (-24.39%)
Mutual labels:  module
Magentoextensions
Magento Extension Directory 1> Themes Switcher 2> Default Shipping On Cart 3> Upshare 4> Product Image Optimizer 5> Idealo Product Export 6> magento Google shopping Api v2 7>Google feed and facebook feed 8> Pdf upload in magento media wysiwyg 9> Product Image optimizer. If You want magento 2 extensions 1>Advance Layred Navigation(including SEO URL, Rating as filter, slider filter, Ajax Filtering), 2>Attribute Pages with SEO and Custom URL key(you can do all kind of seo on those pages with logos) 3>Improved Sorting (Enable users to view products by options as 'Best Sellers', 'Top Rated', 'Most Viewed' etc.) 4>Custom Stock Status(Add statuses to products automatically or manually, Create multiple custom stock statuses, Upload special icons for stock statuses) 5>Product Labels(Using this extension you can add any label to your produts on product page or category page) 6>Custom Order Number(Using this extension you can customize order, invoice, shippment, credit memo Number) 7>All type of file upload in Wysiwyg(pdf, zip, doc etc file upload in wysiwyg), 8>Infinite Scroll, 9>Multiple FlatRate Shipping, 10>Open Api,Google api for currency Rates, 11>Product Attribute's Description, 12>Store and Currency switcher according to Ip address Please Contact me and All those extensions are paid with installation and configuration are free support.
Stars: ✭ 106 (-13.82%)
Mutual labels:  module
Auth Module
auth.nuxtjs.org
Stars: ✭ 1,624 (+1220.33%)
Mutual labels:  module
Container Query
A PostCSS plugin and Javascript runtime combination, which allows you to write container queries in your CSS the same way you would write media queries.
Stars: ✭ 119 (-3.25%)
Mutual labels:  module
Pluginguimagic
Examples for foleys_gui_magic - the styleable plugin gui
Stars: ✭ 120 (-2.44%)
Mutual labels:  module

Nest Logo

Sentry Raven Module for Nest framework

NPM Version Package License NPM Downloads Push Github Actions Coveralls

Description

This's a @sentry/minimal module for Nest.

Installation

$ npm i --save nest-raven

Quick Start

Include Module

For Module to work you need to setup Sentry SDK yourself, this should be done in your main.ts file where you initialize the NestJS application.

app.module.ts

@Module({
  imports: [RavenModule],
})
export class ApplicationModule implements NestModule {}

Using Interceptor

app.controller.ts

  @UseInterceptors(new RavenInterceptor())
  @Get('/some/route')
  public async someRoute() {
    ...
  }

With this setup, sentry will pick up all exceptions (even 400 types).

Global

If you want to set up interceptor as global, you have to follow Nest instructions here. Something like this. This only works for Controllers not for Gateways (limitation by NestJS):

app.module.ts

import { APP_INTERCEPTOR } from '@nestjs/core';

@Module({
  imports: [RavenModule],
  providers: [
    {
      provide: APP_INTERCEPTOR,
      useValue: new RavenInterceptor(),
    },
  ],
})
export class ApplicationModule {}

Filters

Sometimes we don't want to catch all exceptions but only 500 or those that we didn't handle properly. For that we can add filters on interceptor to filter out good exceptions.

app.controller.ts

  @UseInterceptors(new RavenInterceptor({
    filters: [
        // Filter exceptions of type HttpException. Ignore those that
        // have status code of less than 500
        { type: HttpException, filter: (exception: HttpException) => 500 > exception.getStatus() }
    ],
  }))
  @Get('/some/route')
  public async someRoute() {
    ...
  }

Transformers

It may be useful to add some extra data to the Sentry's context before sending the payload. Adding some request-related properties for instance. To achieve this we can add scope transformers on interceptor to injecte some data dynamically.

app.controller.ts

  @UseInterceptors(new RavenInterceptor({
    transformers: [
        // Add an extra property to Sentry's scope
        (scope: Scope) => { scope.addExtra('important key', 'useful value') }
    ],
  }))
  @Get('/some/route')
  public async someRoute() {
    ...
  }

Additional data

Interceptor automatically adds req and req.user (as user) to additional data.

Other additional data can be added for each interceptor.

  • tags
  • extra
  • fingerprint
  • level

app.controller.ts

import { Severity } from '@sentry/node';

  @UseInterceptors(new RavenInterceptor({
    tags: {
      type: 'fileUpload',
    },
    level: Severity.Warning,
  }))
  @Get('/some/route')
  public async someRoute()
    ...
  }

Websockets

Note: Websockets ignore Global interceptors.

It will add ws_client and ws_data extras.

app.gateway.ts

  @UseInterceptors(new RavenInterceptor())
  @SubscribeMessage('message_name')
  public someMessage(client, data: string): string {
    ...
  }

GraphQL

It will add fieldName and args extras.

app.gateway.ts

  @Mutation()
  @UseInterceptors(new RavenInterceptor())
  async upvotePost(@Args('postId') postId: number) {
    ...
  }
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].