frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

Show HN: LogLayer v7 now with StatsD support

https://loglayer.dev/mixins/hot-shots.html
1•theogravity•6h ago
I'm the author of LogLayer, a TypeScript abstraction layer for logging libraries with the ability to send logs to cloud providers like DataDog.

It's made for outputting structured logs, and I've designed the logging APIs to reflect that:

  log.withMetadata({ userId: 123 })
     .withError(new Error())
     .error("Something's wrong!")
Depending on the logging library you're using with LogLayer, it might look like:

  {
    "msg": "Something's wrong!",
    "metadata": {
      "userId": 123
    },
    "err":{
      "type": "Error",
      "message": "test",
    }
  }
The idea is if you decide the logging library isn't fulfilling your needs, you can easily swap out the library where LogLayer is initialized without having to change the code you've already written around logs.

This weekend, I launched v7 of LogLayer, which adds support for mixins. I wanted to keep LogLayer's API focused solely on logging, but also have the ability to extend it if needed.

The use-case that came up is my workplace wants better metrics. We do have auto-instrumentation for our systems, but there are times where we want more pin-pointed metrics. I've noticed in some cases, metrics and logging goes hand-in-hand, and thought that it'd be really nice if I could access the same logging client and be able to send metrics to StatsD as I write my logs.

In node.js land, I believe "hot-shots" is the StatsD client most would use, and created a mixin with it, which adds the hot-shots methods to the LogLayer API. So now you have the ability to send metrics + logs at the same time if you wanted this functionality:

  log.statsIncrement("error.count")
     .withMetadata({ userId: 123 })
     .withError(new Error())
     .error("Something's wrong!")
  
This will now send an increment call to StatsD in addition to shipping out your log to your logging library / cloud provider.

I'm hoping with this DX, thinking about metrics won't be an afterthought because you now have easy access to send it while writing logs.

(You can also send metrics without sending logs with the mixin.)

Being "Seen" and Feeling Part Of

https://growingfearless.substack.com/p/on-being-seen
1•josmor•12s ago•0 comments

The Seifert–Van Kampen Theorem in Homotopy Type Theory (2016) [pdf]

https://home.sandiego.edu/~shulman/papers/vankampen.pdf
1•measurablefunc•49s ago•0 comments

ByViewer – Watch Instagram Stories Anonymously, No Login Needed

https://byviewer.com/
1•cui511511•2m ago•1 comments

Powerful 6.3 quake kills at least 20 in Afghanistan, hundreds injured

https://www.reuters.com/business/environment/magnitude-63-earthquake-hits-afghanistans-hindu-kush...
2•teleforce•4m ago•0 comments

FerroElectric RAM

https://en.wikipedia.org/wiki/Ferroelectric_RAM
1•brudgers•4m ago•0 comments

De-escalating Tailscale CGNAT conflict

https://ysun.co/tscgnat/
1•birdculture•5m ago•0 comments

High-Quality Branded Envelopes for Business Mail

1•skyprint•5m ago•0 comments

Beyond Start and End: PostgreSQL Range Types

https://boringsql.com/posts/beyond-start-end-columns/
2•radimm•9m ago•0 comments

Intuitive UIs support user habits

https://blog.julik.nl/2025/10/what-does-intuitive-even-mean
1•julik•12m ago•0 comments

Show HN: Face Fusion is a fun way to blend faces using AI

https://deepfacefusion.com
2•artemisForge77•13m ago•0 comments

Text Fragments Enable Deep Linking on Web Pages

https://tidbits.com/2025/04/23/text-fragments-enable-deep-linking-on-web-pages/
1•hexage1814•14m ago•0 comments

Cave Rescue That Captivated the Nation

https://www.mentalfloss.com/history/1925-cave-rescue-that-captivated-the-united-states-floyd-collins
1•jameslk•15m ago•0 comments

Thinking Clearly

https://lemire.me/blog/2025/10/26/thinking-clearly/
2•kiyanwang•17m ago•0 comments

The Authoritarian Stack: How Tech Billionaires Are Building a Post-Democratic US

https://www.authoritarian-stack.info/
2•negativelambda•19m ago•1 comments

Cartography of Generative AI

https://cartography-of-generative-ai.net/
1•giuliomagnifico•20m ago•0 comments

I Ask AI for Permission Now (and I Hate Myself for It)

https://www.codecabin.dev/post/i-ask-ai-for-permission-now
1•rebelchrisycom•22m ago•0 comments

CEO Andy Jassy says Amazon's 14,000 layoffs weren't about cutting costs or AI

https://fortune.com/2025/11/01/ceo-andy-jassy-amazon-layoffs-about-culture-not-ai/
1•hansmayer•23m ago•0 comments

Show HN: Easy Text Tools – 130 text utilities that run in the browser

https://easytexttool.com/
2•msdg2024•26m ago•0 comments

A New Faster Algorithm for Gregorian Date Conversion

https://www.benjoffe.com/fast-date
4•benjoffe•26m ago•0 comments

FSF40 Hackathon

https://www.fsf.org/events/fsf40-hackathon
2•salutis•26m ago•0 comments

Installing a MW of nuclear on land is 2x as expensive as on a Aircraft Carrier

https://twitter.com/andercot/status/1984847618489651636
1•MrBuddyCasino•30m ago•0 comments

One-prompt ArXiv filter: parse email digest, output three papers

https://quickchat.ai/post/one-prompt-arxiv-filter
1•piotrgrudzien•32m ago•0 comments

Eigen 5.0.0

https://gitlab.com/libeigen/eigen/-/releases
2•anewhnaccount2•32m ago•0 comments

ecoCompute - Green Tech Conference for Sustainability in Software

https://www.eco-compute.io
1•ArneTR•33m ago•0 comments

Sora AI – Turn Your Words into Videos Powered by OpenAI

https://sora-ai.one/en
1•ucollabn•36m ago•1 comments

I Built an AI to Roast My Own About Page. It Was Brutal (and Right)

https://www.startastory.app/blog/about-page-research/
2•blakey_vibes•40m ago•0 comments

Postbase – Self-Hosted Firebase Alternate – Node, Express, BetterAuth, Postgres

https://github.com/umrashrf/postbase
2•umrashrf•41m ago•0 comments

Master your AI work loads

https://github.com/ulixcode-labs/GPU-pro
1•gpupromain•41m ago•0 comments

Steps to turn off AI

https://againstdata.com/blog/stop-ai
24•austinallegro•43m ago•4 comments

Dynamically include files in GitLab-CI

https://www.zufallsheld.de/2025/10/03/dynamic-gitlab-ci-includes/
1•zufallsheld•46m ago•1 comments