Lethalman's comments

Lethalman | 3 months ago | on: Idempotency keys for exactly-once processing

> To ensure monotonicity, retrieval of the idempotency key and emitting a message with that key must happen atomically, uninterrupted by other worker threads. Otherwise, you may end up in a situation where thread A fetches sequence value 100, thread B fetches sequence value 101, B emits a message with idempotency key 101, and then A emits a message with idempotency key 100\. A consumer would then, incorrectly, discard A’s message as a duplicate.

Also check out Lamport vector clocks. It solves this problem if your producers are a small fixed number.

Lethalman | 10 years ago | on: Cheap Docker images with Nix

You are right. It's unfair, I'm going to modify the post to mention alpine.

The post is both about tiny images AND how to build docker images with nix. I think it was an interesting tooling to make for our community. Some Nix people are already using it for obvious reasons.

Lethalman | 10 years ago | on: Cheap Docker images with Nix

The blog post code is supposed to run with latest master since a few days. We've merged a big change that leads to reducing a lot the closure of our packages.

Nix moves fast enough, in the sense we usually do a good job at not breaking things. Yet we have to necessarily introduce innovations in our frameworks.

Lethalman | 10 years ago | on: Code.google.com was shut down, Go packaging is broken

How Nix solved the issue:

1. Each go package has an attribute name in nix, like anything else, that is not tied to its url.

2. Each go package has an url where to fetch the source from, which is not the import path to use the package.

3. Each go package has a number of old import url aliases (e.g. "code.google.com/...")

4. Whenever a package X depends on Y with an old import url, then X is rewritten to use the new url path of Y using govers.

So the problem is solved at our packaging level.

This is not to say it's the best solution, but certainly a good alternative solution.

Lethalman | 10 years ago | on: Open Letter to Mozilla: Bring Back Persona

Sorry, where is it said they will stop development of Persona? The homepage and the service seem to be in full health, there's no warning anywhere for users of Persona.

Is there any official statement that Persona will shut down?

Lethalman | 10 years ago | on: Show HN: Sqlata, the SQL builder I wanted

I've looked at knex. But I felt it not to be as composable as sqlata.

In knex operators are written with .where() itself. Also it doesn't manage table aliases apparently. And it's quite tied to an underlying connection as I can see.

But yes, all the sql bulders out there are quite similar, but there are notable differences compared to sqlata if you look deeper.

Lethalman | 10 years ago | on: NixOS Linux

You also upgrade grub versions I hope :) Or maybe improve the grub installation scripts.

Lethalman | 10 years ago | on: NixOS Linux

Things you must be afraid when using nix:

1) If you install a bad grub, you cannot rollback it using nix. That means, not a wrong grub line, but if grub itself is broken.

2) Anything that is not under nix control, the data: like desktop configurations, databases, ecc.

Lethalman | 10 years ago | on: NixOS Linux

It's a different approach. That's basically an implementation using ostree. Nix is way different than that. Neither is better in my opinion, but I use Nix happily.

Lethalman | 10 years ago | on: NixOS Linux

There's a /bin/sh because libc needs it, but we're going to remove that one too in the future somehow.

But /usr/bin/env is in nixos to make it easy for people to run scripts. But packages never use /usr/bin/env, it's just there for convenience.

Lethalman | 11 years ago | on: Pony – High Performance Actor Programming

So I haven't seen yet in the website a code sample showing how a simple ping-pong actors would communicate, so I can't even test quickly if this is possible with the language.

If the program can implement a lock between the two actors, then your language is not deadlock free. Even a loop by checking if some variable has changed by the other actor (if possible in this language, I still don't even know by the deep lack of examples), and the other actor doing the same thing, that can be claimed as deadlock.

Lethalman | 11 years ago | on: Pony – High Performance Actor Programming

Stopped being interested after reading "It's deadlock free!", "because Pony has no locks at all"... yeah but actor X waiting for actor Y which waits for actor X is a deadlock. It's not a matter of lock primitives, it's a matter of software. (yes, x-comment from reddit)

Lethalman | 11 years ago | on: A Fast, Minimal Memory, Consistent Hash Algorithm

This is a nice algorithm and I thought about writing something that only depended on numbers and not on allocating nodes in a ring.

It works well when adding nodes, but then how does it work when removing a node in the middle? When allocating nodes in a ring it's easy, just reassign the vnodes. But what with this algorithm? Can anybody explain how does it keep track of which nodes take control of which part of the removed node?

page 1