I'm trying to engage in a project that I started five years ago. Yes, it's a private social "network," which is to say, it's not really a network if it's just for me. And probably my friends. As Meta gets further and further into the territory of "no consequences," and fails to be social in any way, I want to move on. I'm already just posting and rarely reading, so why bother? It's little more than a contextual journal at this point.
All of those years ago, I sketched out some data structures that would make it pretty easy to adapt to various post types (text, photos, links, etc.), but at some point it became pretty convoluted. Reasonably, it gets out of the over-normalized relational stuff and adopts more serialized bits as they relate to sub-types of content. But also, it makes some decisions about when to serialize or deserialize and send it over the wire. Whatever my thinking was when I started that, I do not recall. So as I come back to it, none of it works. This week I've sat down to look at it three times and lost interest very fast.
It's so clear to me why I didn't have the output of my peers when I was writing code as my primary job. Now I know it's the ADHD, but at the time I just thought that I was lazy. That's definitely not the case. What's interesting though is that when I have a clean start, I go for super simple everything. As it turns out, the non-neurotypical nature of my brain prefers simplicity, limited scope and much more readable code. When I encounter something in code that I wrote more than a decade ago, it feels over-engineered and gross. I wonder now if the simplicity would make up for the output if I were doing this as my primary job function.
In any case, I've resolved that I just need to start over with the end-to-end transmission of data between the client and the database, with all of the stuff in between. The database is fine, it's everything in between. If you write code, then you've heard of "data transfer objects," or DTO's, which I've always found to be cumbersome and often not necessary. My forum app doesn't have them. And part of the way that you get away with that is server-side rendering of user interfaces, which in this case isn't what I'm doing. So you add this go between over the wire, and then you're in the business of optimally shaping payloads. What I'm starting to get is that payloads are just wrappers around those entities that you already have. Duh. So if you have a text post, for example, and it has links, you're just optimizing that graph and sending that. I'm sure day-to-day code monkeys laugh at me for this realization.
Sometimes I'm amazed at how much I know, and how many dumb things I do anyway, when it comes to this craft. And boy does AI give you a lot of dumb options, but I'm trying to get more out of it.
No comments yet.