graphql-eventbus
nestjs
graphql-eventbus | nestjs | |
---|---|---|
4 | 4 | |
27 | 2,083 | |
- | 3.3% | |
6.7 | 8.0 | |
about 1 month ago | 6 days ago | |
TypeScript | TypeScript | |
MIT License | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
graphql-eventbus
- How to use graphQL api key and secret key with python
-
GraphQL for event driven architecture
Docs: https://graphql-eventbus.vercel.app/
-
GraphQL for Event Driven Architecture
Hey guys, I've been working on a GraphQL library for typescript that enables building event driven architecture using GraphQL schema. It can be used to publish and consume events in a type safe way using any message broker (Kafka, .RabbitMQ, PubSub etc). I built this library to scratch my own itch when I was trying to building a type safe event driven communication between microservices: JSON schema and protobuf didn't feel elegant and were too verbose so I thought why not GraphQL. You can read more in my blog post here: https://graphql-eventbus.vercel.app/blog
Youtube Intro Video: https://www.youtube.com/watch?v=XLbShOmkKk0
Github: https://github.com/skk2142/graphql-eventbus
Docs: https://graphql-eventbus.vercel.app/
I'd love to get your feedback!
nestjs
-
Are there any guides for message brokers in a traditional NestJS REST app?
When you're going to use RabbitMQ I would advise to use the RabbitMQ library at https://github.com/golevelup/nestjs. It's way more flexible than the default RabbitMQ microservice.
-
Providing Providers to Dynamic NestJS Modules
For this, I'm going to be using a package called @golevelup/nestjs-modules to help with the creation of the dynamic module. Instead of having to set up the entire forRoot and forRootAsync methods, we can extend a mixin and let the package take care of the setup for us. everything in this article will work without the package, I just like using it for the sake of simplicity. So, lets dive into setting up our AuthModule to be a dynamic module. First we need to create our injection token for the options
-
How to parse the raw body of a request in a NestJS controller
import { Injectable, NestMiddleware } from '@nestjs/common' import { json } from 'body-parser' /** * Copied this middleware to parse the raw response into a param to use later * from https://github.com/golevelup/nestjs/blob/master/packages/webhooks/src/webhooks.middleware.ts */ @Injectable() export class RawBodyMiddleware implements NestMiddleware { public constructor() {} public use(req: Request, res: Response, next: () => any): any { json({ verify: (req: any, res, buffer) => { if (Buffer.isBuffer(buffer)) { const rawBody = Buffer.from(buffer) req['parsedRawBody'] = rawBody } return true }, })(req, res as any, next) } }
-
What are some good practises for mocking providers in tests
The easiest thing to do is just mock all of a services methods with jest mock functions. I like to do that with this library: https://github.com/golevelup/nestjs/tree/master/packages/testing
What are some alternatives?
graphql-eventbus - GraphQL layer to publish and consume events from any message broker [Moved to: https://github.com/quant-daddy/graphql-eventbus]
shopify-api-node - Shopify Admin API Library for Node. Accelerate development with support for authentication, graphql proxy, webhooks [Moved to: https://github.com/Shopify/shopify-api-js]
purista - A typescript framework for building backend services and api in modern, modular and scalable way with event-driven patterns
stompjs - Javascript and Typescript Stomp client for Web browsers and node.js apps
spec - CloudEvents Specification
ultimate-backend - Multi tenant SaaS starter kit with cqrs graphql microservice architecture, apollo federation, event source and authentication
opentelemetry-ext-js - js extensions for the open-telemetry project
hasura-backend-plus - πAuth and π¦Storage for Hasura. The quickest way to get Auth and Storage working for your next app based on Hasura.
amplication - π₯π₯π₯ Open-source backend development platform. Build production-ready services without wasting time on repetitive coding.
porn-vault - π Manage your ever-growing porn collection. Using Vue & GraphQL
hasura-auth - Authentication for Hasura.
typeorm - TypeORM module for Nest framework (node.js) π