Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
latch
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
8 ms
·
31.
▲
by
latch
1y ago
Author of ccache here. I've barely touched Go in over a decade, but if I did, I'd probably still use ccache if I didn't need cutting edge (because I think the API is simple), but not if I needed something at huge scale. When
32.
▲
by
latch
2y ago
Author here. I agree this is a less-than captivating piece. I write a lot about Zig and wanted something I could reference from other pieces. But, to answer your question directly: absolutely. In addition to writing a lot about it, I mainta
33.
▲
by
latch
2y ago
There's definitely overhead with the GenericWriter, seeing as it uses the AnyWriter for every call except `write` (1) genericWriter - 31987.66ns per iterations appendSlice - 20112.35ns per iterations appen
34.
▲
by
latch
2y ago
A couple comments have mentioned that whatever issue my post raises, are minor compared to the simplicity of the language. But the current implementation of GenericWriter + AnyWriter (with some performance pitfalls) seems more, not less, co
35.
▲
by
latch
2y ago
In most BIG banks, "Vice President" is almost an entry-level title. Easily have 1000s of them. For example, this article points out that Goldman Sachs had ~12K VPs out of more than 30K employees: https://web.archive.org
36.
▲
by
latch
2y ago
Their explanation for why Go performs badly didn't make any sense to me. I'm not sure if they don't understand how goroutines work, if I don't understand how goroutines work or if I just don't understand their expla
37.
▲
by
latch
2y ago
I don't understand why people use Ecto (or ActiveRecord, or...) Back in the day, I'm pretty sure we were using Hibernate and friend because our software was shipped and we wanted it to work with whatever database the client was us
38.
▲
by
latch
2y ago
In my experience, the real problem with any support scheme is that the decision makers don't have enough skin in the game. It's easy to deprioritize tech debt and bug fixing when you aren't facing 3am pages. The obvious solut
39.
▲
by
latch
2y ago
It's a bit like row vs column store. If there are two lists, in the first example, you're doing: a1 -> b1 -> c1 -> d1 a2 -> b2 -> c2 In the 2nd example, you're doing [a1, a2] [b1, b2]
40.
▲
by
latch
2y ago
Why never for a live system? Store users with an username/email and scrypt-encrypted password. On login, pull the encrypted password where username = $1. Compare. If valid, create a session id (fill 16 bytes with a cryptographically se
41.
▲
by
latch
2y ago
Serious question, are you familiar with dedicated hosting?
42.
▲
by
latch
2y ago
If your scale is crazy, or your product doesn't allow you to use battle-tested pieces, then orchestration is complex in both cases. In most cases, managing software on bare metal is more complex in exactly one case: when engineers only
43.
▲
by
latch
2y ago
This example came from a real world http server. Admittedly, Zig's "web dev" community is small, but we're trying :) I'm sure a lot could be improved in httpz, but it's filling a gap.
44.
▲
by
latch
2y ago
The inspiration for the post came from my httpz library. The fallback using a FixedBufferAllocator + ArenaAllocator is used. The fixed buffer is a thread local. But the arena allocators belong to connections, of which there could be thousan
45.
▲
by
latch
2y ago
fixed, thanks.
46.
▲
by
latch
2y ago
No mention of setting the :sensitive process flag to true. Been a while since I've done Elixir, but I think sensitive: true disables additional things, possibly to the point of being a little too much in some cases.
47.
▲
by
latch
2y ago
I think there are at least 2 serious issues with TLS, both documented in: https://github.com/ziglang/zig/issues/15226
48.
▲
by
latch
2y ago
Yes. I think I don't understand something, because without a cohesive concurrency story, it isn't clear how you're supposed to glue different components together effectively. For example, an http server is using nonblocking c
49.
▲
by
latch
2y ago
To add more concrete examples, you could look at tagged unions, errorsets and optionals. An `if` statement in Zig has a few different faces, traditional condition, unwrapping an optional and unwrapping an errorset. That makes the language &
50.
▲
by
latch
2y ago
I've written a lot of Zig, including a somewhat popular http framework, a driver for PostgreSQL and one for DuckDB. Personally, I feel that if you want to grow as a programmer, no matter what you're doing, there's little that
51.
▲
by
latch
3y ago
I don't mean to pick on your specific comments, but I find these analysis almost always lack a crucial perspective: level of knowledge. This is the single biggest factor, and it's the hardest one to be honest about. No one wants t
52.
▲
by
latch
3y ago
The biggest issue with std.http.Server is [1]: This server assumes *all* clients are well behaved and standard compliant; it can and will deadlock if a client holds a connection open without sending a request. Atop your readme, you
53.
▲
by
latch
3y ago
Like many http server implementations in Zig, this is a wrapper around `std.http.Server`. `std.http.Server` only exists as a mechanism to test the `std.http.Client` (which is needed for things like, downloading packages). So `std.http.Serve
54.
▲
by
latch
3y ago
As a Zig developer with one of the more popular HTTP server libraries around (http.zig), this is impressive and good use of comptime and (good) abuse of Zig's anytype. I'm looking forward to learning from the codebase. But, it
55.
▲
by
latch
3y ago
In my project, you can start N workers, each accept(2) thanks to REUSEPORT[_LB] and manages its own epoll/kqueue. When a request is complete, the application's handler is called directly by that worker. I considered what you'
56.
▲
by
latch
3y ago
I have a somewhat popular HTTP server library for Zig [1]. It started off as a thread-per-connection (with an optional thread pool), but when it became apparent that async wasn't going to be added back into the language any time soon,
57.
▲
by
latch
3y ago
I feel like a simple improvement to LRU is to not promote on every fetch. This adds some frequency bias into the mix and reduces the need to synchronize between threads. Is this a known/used technique?
58.
▲
by
latch
3y ago
The first example, reading lines in a file, is really slow. Depending on the input, it could be 4x-10x slower. In Go, the equivalent `ReadLine` is implemented on `bufio.Reader`. Thus the implementation can take advantage of the buffering. I
59.
▲
by
latch
3y ago
If it's supposed to be sorted by name, why does "Ariel Oxy Bleach..." show up before "2-Fold Umbrella..." but "Ariel Antibac Jumbo" shows up after. This isn't just bad search, it's objectively w
60.
▲
by
latch
3y ago
The complaint about "rice" is that the tagging is incomplete. "vegan" isn't a bad facet, but the count is wrong. When you select "vegan", most vegan products are removed. I don't see how filtering wro
More ›