3 ms·
I feel like I can point out lots of similar problems to the other solutions you suggest (heck, I thing some of those problems you list even apply to those other
by hn_throwaway_99 2y ago
I feel like I can point out lots of similar problems to the other solutions you suggest (heck, I thing some of those problems you list even apply to those other solutions).
The list approach has some downsides, but it also has a bunch of upsides. I feel like when people like to point out potential flaws of these approaches, they're ignoring the history and difficulties that comes with Cloudflare's scope. An enumerated list is the simplest and most flexible of the approaches, and it also doesn't require any a priori agreement on the structure of a header key - this is probably important when you think about the sheer number of teams at Cloudflare, potential technology acquisitions, etc.
- amluto 2y agoLists, extensible protobufs, etc are indeed great in their extensibility. The issue I would see (if I worked at Cloudflare) isn’t to using a list — it’s that the list is the same list that’s used for externally visible HTTP headers.
- hn_throwaway_99 2y agoI don't see that as a problem at all: "Hey any teams out there, before you can add internal headers, you need to register them with some service." Then the list is loaded from static storage at startup time and/or refreshed on some periodic basis.
- Aeolun 2y ago> it also doesn't require any a priori agreement on the structure of a header key - this is probably important when you think about the sheer number of teams at Cloudflare That’s more of an indictment of how little effort is spent aligning things. It’s not that hard to tell every team that any headers have to start with ‘CFint’ and then enforce that.
- ketzo 2y ago> It’s not that hard How many years do you have to spend in software before you stop uttering those four cursed words?
- Aeolun 2y agoIt takes just as much experience to acknowledge that the cure is worse than the disease.
- poincaredisk 2y ago* Headers that are originally private, but are later changed to public * Headers that are intended to be public, but then are changed to private * Headers that were created in the very early days of the company, which are so deeply integrated into everything that renaming them is basically impossible (or at least very hard and risky) * Headers that are set by some appliance/third party solution not controlled by CF, but which are technically internal and must be stripped. * Newly acquired company has its own set of internal headers. Management is not amused when a huge, disrupting refactor is suggested by engineers. And this is just a tip of the iceberg of possible problems when your scale is big enough.
- bhawks 2y agoSo because everything is a Byzantine labyrinth due to scale we're all going to agree to remember to add internal headers to strip to another service? Maintaining the header to strip list is just another piece of technical debt to keep paying down. Having a policy to strip everything under a prefix seems much less error prone.
- hn_throwaway_99 2y ago> It’s not that hard to tell every team that any headers have to start with ‘CFint’ and then enforce that. To be a little bit blunt, this just means you have never built software in a very large company that may have a lot of existing/completely independent software, or have made technology acquisitions after the fact. That is, if you are starting from "time 0" of course it's very easy to say "internal headers need to start with CFInt", but that's rarely the case.
- Aeolun 2y agoI think if you work for such a very large company the only reason you are ok with it is because nobody at the top says ‘no more’. If they do, it suddenly becomes very easy to get everything aligned, because there is likely a vast collection of bodies just collecting a paycheck that can be more productively assigned to manually renaming everything.