Adventures in Nodeland - Issue #8 - Wecome Mercurius Auth!





Matteo Collina
Matteo Collina
Hi Everyone! Last week has been a flurry of activity on all Open Source projects I’m maintaining - check them out!

GitHub - mercurius-js/auth: Mercurius Auth Plugin
Mercurius is the GraphQL plugin for Fastify that I wrote and spoke in the past quite a lot. Mercurius Auth builds upon Mercurius to provide a contex-aware authorization system that allows you to restrict the access to resolvers and external services in case of gateway. Jonny Green did an amazing implementation that wraps the resolvers with an auth check whenever the @auth directive is specified.
I’m really excited about this new library as I implemented authorisation systems several times and this looks as a massive time saver. Check it out!
Every now and then I get asked how Fastify came to be, or why Fastify is having the great adoption it is currently having. The secret sauce is its community. I spoke extensively on the topic at last year OpenJS World.
Build a Community, Not a Framework - Matteo Collina, NearForm
Build a Community, Not a Framework - Matteo Collina, NearForm
Fastify v3.15.1 shipped last Friday that improved the user experience in case of bad configuration values:
  1. - do not crash if a route is registered without a url.
  2. - reply.hasHeader should include node core res.hasHeader!
GitHub - lmammino/async-iteration-http-requests: Playing around with async iterators with HTTP servers
JS Monthly #13 / GraphQL & JS Multithreading / April 2021
JS Monthly #13 / GraphQL & JS Multithreading / April 2021
At the JS Monthly live meetup I spoke about the design of pino.transport() and why it makes all the difference.
I worked a little bit on the topic and crafted a very basic example that demonstrate how to use the new transport API to log with prettyPrint to the stdout and to a file with level warn:
OSS life
Luciano Mammino 💛 Node.js
Did you know that you can use `on` to turn an event emitter into an async iterator in #NodeJS?

Need an example? How about doing a `for await...of` to handle incoming #HTTP requests a-là-Deno? 🙃
Almost 3 years ago I started working on adding support to Async Iterators to Node.js core APIs. One of those is using async iterators to receive events! Yesterday Luciano posted a snippet showing how to process incoming requests using an async iterator… in the end it’s something you should not do, as you might inadvertently force your server to only process one request at a time!
GitHub - lmammino/async-iteration-http-requests: Playing around with async iterators with HTTP servers
GitHub - nodejs/undici: An HTTP/1.1 client, written from scratch for Node.js
Undici is the new HTTP/1.1 client for Node.js that we are developing outside of Node.js core. We have shipped the first release candidate: you can test it with “npm i [email protected]”.
I work as a Technical Director at NearForm and I am also responsible to interview candidates. We are still hiring across the board for senior roles, so if you would like to work with me, apply at:
Shaping a better world
Thank you very much for enjoying this newsletter and engaging with it over Twitter! I always receive such a warm welcome for all content I produce and I cannot be happier.
Did you enjoy this issue? Yes No
Matteo Collina
Matteo Collina @matteocollina

I write about my journey as a core contributor of Node.js, as an author and a maintainer of many modules - including Fastify and Pino. In addition, I speak at conferences, and I will add links to all my talks in case you missed one.

In order to unsubscribe, click here.
If you were forwarded this newsletter and you like it, you can subscribe here.
Created with Revue by Twitter.