HNHacker News
TopNewBestAskShowJobs

xani_

1,252 karma · joined January 28, 2020

submissionscomments
xani_··on Discussion: structured, leveled logging
From what I've skimmed the most problems seem to be "golang's type system won't allow expressing all of that on compile time so it will be costly" and I don't think that can be sensibly fixed in logging package

> I know a bad API when I see one. strings.Replacer [1] uses the same syntax, and several others have commented in the discussion about it being a bad idea.

What's wrong with it ? Never used it. But I think the complaints has been about wasting time for runtime type handling and Replacer doesn't have that problem.

xani_··on Discussion: structured, leveled logging
It's less about package and more about interface.

One "good enough" in stdlib means libraries could just require passing a interface matching it. Then no matter which logging package you use, as long as it fulfils the interface of stdlib logger it can be used with any library or other component you pulled.

So with simple app you can just have simple logger that dumps everything on stderr, complex app can have whatever complex logging logic it needs, but lib "just using stdlib logger" doesn't care about that.

And as a lib author, again, you can just use the stdlib one and most likely cover all your use cases.

xani_··on Discussion: structured, leveled logging
Develop bigger app and you will understand.

But one example - having an logging interface that is not shit (the current builtin is so garbage it might as well not exist at all) allows for packages to adopt it as default method and you magically can just fed same logger to every dep you pull with no loss of features or having to write wrapper.

Contexted logger means you can just fed ["plugin":pluginname] tagged one to every plugin and get logs pointing you to the place where it happened.

The structured logging part is mostly to avoid woes of then having to parse it back to structured format via bunch of regexpes that will inevitably break next release. If you still don't get it, here is a regexp to parse HAProxy logs:

    .*haproxy\[(\d+)]: (.+?):(\d+) \[(.+?)\] (.+?)(|[\~]) (.+?)\/(.+?) ([\-\d]+)\/([\-\d]+)\/([\-\d]+)\/([\-\d]+)\/([\-\d]+) ([\-\d]+) ([\-\d]+) (\S+) (\S+) (\S)(\S)(\S)(\S) ([\-\d]+)\/([\-\d]+)\/([\-\d]+)\/([\-\d]+)\/([\-\d]+) ([\-\d]+)\/([\-\d]+)(| \{.*\}) (".*)([\n|\s]*?)$`)



> I think Go team might be overlooking the fact that a big chunk of the userbase doesnt understand, and has no need for a logging package

How does that proposal impede them ?

if you don't need any of the extras you'd be able to just `log.Info"

xani_··on URL is also a shell script that executes some malicious(?) code
zsh auto-quoting on paste was enough to beat it
xani_··on CernVM File System
I'd love that for rescue media, just load what you need and mirror rest of the image to RAM in background
xani_··on Movim – A decentralized social platform built on XMPP
There was one beautiful moment where Google and Facebook supported XMPP so you could just set up your XMPP server and talk with people across the platforms but both decided to close their gardens for the usual reasons

But XMPP is shitshow of million XEPs and massive matrix of which supports what. So just because in theory there is some feature you want it doesn't mean that your server and your client will work with it. That's terrible value proposition to anyone wanting to do anything in the space, you dont want to debug (and we did had to, when we used xmpp for our company chat) why user X using communicator Y on platform Z can't send attachment to your user on communicator Q.

XMPP needs to just sit the fuck down, gather the XEPs and put it into XMPP 3.0, with few feature sets that every client and server using it needs to support all at once, not picking and choosing.

So if you make text only chat client, it supports all of the formatting, all of the file send/receive, all of the MUC things, all of the E2E encryption things, all at once. And have one text formatting to support (Markdown seems to be winning here), not a bunch.

xani_··on It seems that the good times for online Minecraft play are over
I dunno, I can just imagine new age of cyber-bullying when a bunch of kids just mass-reports some poor kid (hell, even provoke them on chat so if detached moderator sees that they think it's legit) and sends their account to shadow realm.

Having a closed set of realms servers can opt in with more stringent moderation might be a good idea, but forcing it globally is just entirely stupid; there are things inappropriate for kids that are just fine for teenager audience, and adults play the game too.

If I was in your spot I'd honestly either set up, or rent them a private minecraft server, then they can invite their friends there and you have full control on what is happening with it.

> Correct me if I'm wrong, I don't see anything in their process that suggests that a group of adults playing with their friends are at risk of having their chat audited in the absence of a complaint?

Just need one person taking a piss. And it pretty much means no server with strangers is safe as you could be reported by anyone for anything completely benign in context of the server

xani_··on It seems that the good times for online Minecraft play are over
Great time for christian minecraft servers, someone calls you a butt and they will be banished forever from realms of minecraft
xani_··on Making a Website Under 1kB
It seems really silly as this is extremely low bar to get, you can get there by accident if you "just" use plain html/css.

Then again in age of JS frameworks maybe it is an achievement for the new developer that was gaslighted into thinking 500MB of deps to make a simple site is normal

xani_··on Making a Website Under 1kB
> Building a website that actually serves useful content while squeezing its page size under 1,024 bytes is no easy feat.

Narrator: It was extremely easy feat.

Just make spec-invalid webpage and skip all the heads, bodies, htmls and rest of it.

xani_··on Crash recovery for user-space block drivers
I think they resist that mainly because it makes it easier for companies that don't want to upstream their drivers, and nobody else.

Currently, if there is say a better, more efficient way to do some common task ,say storage drivers, do, you can just go in and refactor all of that.

With common interface, you're doomed. You might implement the better way and give it in API, but you can't force anyone to use it, and you can't deprecate the old one.

You also have to keep the old behaviour *forever*, even for things that "do not break userspace" so it's even bigger maintenance burden.

And what if your API is wrong ? Still gotta keep it... and someone might still use it and trip on the wrongness

xani_··on Crash recovery for user-space block drivers
I'm not. It's a wet dream for any company that wants to do distributed block storage but doesn't want to update kernel module every time the new feature or fix gets added; nowadays a lot of that (like Ceph's RBD driver) needs to be in kernel, and it would need to be backported any time new feature that client wants would come along.

The code is tiny compared to full implementation of any of the block drivers and allows them to be moved to userspace so it also potentially saves a lot of maintenance in the future, because it would be the first choice if you're implementing another distributed block file system.

> Is the mental model for this to treat it like a device driver (where it's off by default and can be turned on under specific circumstances), or is this thought of as part of the default-available kernel API that every system will have access to from now on? (I guess FUSE itself is a little fuzzy in this respect)

As a device driver that can be fully tested with no actual hardware, and much smaller area of attack than real driver.

xani_··on Crash recovery for user-space block drivers
Randomly seekable randomly writeable block storage wont be fast when implemented on top of any object store, especially ones that do not allow arbitrary append like S3. Filesystems make a lot of assumptions for underlying storage.

But this allows any typical block device driver to run in userspace which means you no longer require certain version of kernel to support new features or new protocol, which is nice.

It's also useful in testing or prototyping filesystems, as you can make userspace proxy that can emulate any kind of error without much kernel knowledge. Sure, there are already some tools for that but it's easier to do in userspace.

xani_··on When Every Ketchup but One Went Extinct
I'm still disappointed we can't readily buy a pizza sauce in ketchup bottle form
xani_··on ErgodoxE EZ – an ergonomic keyboard with open source firmware
You don't need layers if you have more keys. And it's faster too
xani_··on ErgodoxE EZ – an ergonomic keyboard with open source firmware
The question is whether the comfort is because of ortho, or just because of nice big split layout keyboard?
xani_··on The Projectionist: On the best job that no longer exists
It's just "nostalgia glasses"; only thing that is "alive" is the media being worse and worse after each use.
xani_··on IKEA’s knowledge graph and why it has three layers
If anything years in corporate taught me that something might be pedantic, pointless and still not combat entropy very well
xani_··on IKEA’s knowledge graph and why it has three layers
As not so absolute amateur the key is to type "<parts site> <what you want>" in google and then fiddle

For example "8 vit shit register" gives first link to SN74HC595B, a generic shift register and second link to parametric search

https://eu.mouser.com/c/semiconductors/logic-ics/counter-shi...

with "logic type=shift register" and "number of bits=8" already selected.

You don't even need to spell it correctly

Googling smartly is

> I wish there was a curated list or an "easy mode" on Digi-Key.

exactly what you want.

xani_··on IKEA’s knowledge graph and why it has three layers
I'm guessing infanty went "1mm, close enough" and did it anyway?
xani_··on Not Your Grandfather’s Perl
Most Python code from 10 years ago won't run on modern distro.

Almost all Perl code will

xani_··on Not Your Grandfather’s Perl
Uh,those features are here for almost decade now, some longer IIRC.

But man, just being able to write

   use v5.10
have been a blessing when you need to support some legacy infrastructure. Old Python broke after upgrades, Ruby broke, but Perl code keeps on trucking.

In vast majority of cases the code changes were just "well, the new version of lib gives some warnings about deprecation, might as well clean it up a bit". The minority of cases has been Mojolicious breaking stuff again.

xani_··on The Case for the /usr Merge (2012)
It's funny that you mention that because ZSH does exactly that

    -> ᛯ cat /tmp/1.sh
    #!echo ble bla bla bla  -n -e

    -> ᛯ /tmp/1.sh
    ble bla bla bla  -n -e /tmp/1.sh
It's the best solution but it will take decades for that to migrate to other shells
xani_··on The Case for the /usr Merge (2012)
I have absolute confidence that he's entirely focused on stuff working well on his laptop and that's about that.

You can just smell man have attachment issues with his design decisions and code. Reimplementing stuff that works fine, but badly also seems to be his fucking hobby

xani_··on Patreon laid off their security team
Could be as simple as "they just whined from their security ivory tower so we just made developers doing actual code and ops doing actual ops do their job".

You want people focused on security, but separate security department all too often just becomes annoyance that doesn't understand business, or architecture, just drops decrees.

xani_··on Patreon laid off their security team
Funny how achievements always get credited to the overpaid management but blame gets spread around...
xani_··on Patreon laid off their security team
I dunno, in about 2/3 of our clients the security team could be summed up as ivory tower that throws decrees and enforces half-useless constraints.

Like, we HAD TO change our passwords every 30 days.... but our default modus operandi was not having password auth in first place + hardware tokens for authentication, which made whole password thing totally irrelevant, but no, security, change your password you don't use every 30 days.

xani_··on My VM is lighter (and safer) than your container (2017)
AWS "just" runs linux but this is using unikernels tho ?
xani_··on My VM is lighter (and safer) than your container (2017)
They went to trash because containers are more convenient to use and saving few MBs of disk/memory is not what most users care.

The whole idea was pretty much either use custom kernel (which inevitably have way less info on how to debug anything in it), and re-do all of the network and storage plumbing containers already do via the OS they are running one.

OR just very slim linux one which at least people know how to use but STILL is more complexity than "just a blob with some namespaces in it" and STILL requires a bunch of config and data juggling between hypervisor and VM just to share some host files to the guest.

Either way to get to the level of "just a slim layer of code between hypervisor and your code" you need to do a quite a lot of deep plumbing and when anything goes wrong debugging is harder. All to get some perceived security and no better performance than just... running the binary in a container.

It did percolate into "slim containers" idea where the container is just statically compiled binary + few configs and while it does have same problems with debuggability, you can just attach sidecart to it

I guess next big hype will be "VM bUt YoU RuN WebAsSeMbLy In CuStOm KeRnEl"

xani_··on Reddit's favorite products in one place
I doubt "most people" go out of their way to 4-7 websites on average to buy anything.
← PreviousPage 17 of 19Next →