Live data from Hacker News

XML is the future

bitecode.dev

341–350 of 408 posts

Re: XML is the future

#341

Earlier quoted context omitted.

I am in the exact opposite,but equally frustrating boat. In last 5 years, I have worked at 2 Faang and a large hedge fund and everywhere they had extremely outdated stack or undocumented in-house stack or outdated undocumented in-house stack. Already derecated dependencies were pinned years ago and management won't let you modernize anything since there "no business value in it" and we need to ship a feature instead…

really surprised faang management doesn't see the value in addressing technical debt.

Because they don't see technical debt as a bad thing. Go back to the original pitch for technical debt by Ward Cunningham. He was working for a finance company and used the debt metaphor to advocate in favor of "borrowing against the future" when implementing new code. The idea was that you could use the latest stuff without reinventing everything. Like mortgage payments, the reinvention could happen over time, in increments, until it's "paid off". The problem is that nowadays, especially in finance, you're dealing with people who are used to over leveraging everything. To them, the idea is to pile on debt until it becomes unmanageable: and then sell. Or go into Chapter 11.

Re: XML is the future

#342

Earlier quoted context omitted.

A better comparison would perhaps be “ansible” vs “puppet” vs “chef”. I wrote everything in shell, then puppet, then chef, then ansible. Doing literally the same thing. Because fads.

Taking this comment in good faith, because HN... Do you really not see any difference between Ansible and a shell script? Even just the move between shell and bash/csh/tcsh/zsh whatever else can make a marked difference in productivity and ergonomics.

I can see that Ansible with its do-it-yourself-AST-in-YAML is more tedious to write and even debug :-P No wonder they have shorthand versions of their module calls, too.

I'm still using it, though every piece of software lately, fad or not, is something I tend to endure or survive or cope with, rather than use or enjoy using. Little papercuts everywhere.

Re: XML is the future

#343
So.. there's a lot to unpack here.

There's a few ways to interpret the "hype-train" of mainstream development

1 - it's gonna solve all my problems

2 - everyone else is talking about it so I should learn it

3 - incremental ad-hoc solution to a real problem someone encountered, may or may not apply to me

Many juniors are guilty of 1 & 2, few make it to realize that most of the time these lie in camp 3. There's a real use case for this, but you have to train your mind to not see it as a silver-bullet or worry about hype train.

The difference between academia & industry is that academia tends to develop general solutions to problems few if any people encounter. The best of the industrial programmer will take the bits of academia & try to make our ad-hoc solutions slightly more general while staying practical.

This is endless, and depending on your perspective its fascinating OR exhausting.

To me its a bit of both, but with distance & the realization that I do not need to care about virtually any new tech, I usually lean to the fascinating side.

As a language designer its humbling to see the milage people get out of many half-baked solutions in the JS ecosystem, and a sign that generality isn't the whole picture.

Re: XML is the future

#344
post #335

Earlier quoted context omitted.

So how old does the tech need to be?

The older the better. The better understood, both in capability and limitation. The better chance no new updates will break it. The better chance no new updates. The better you get to know it. The better you get to integrate it. The better the chance it will be there tomorrow too. The better the investment learning it becomes.

On the opposite end of the spectrum, if your stack is too old (and niche enough) then you won't get to know it very well once every bit of documentation was hosted on expired domain name, and you can only find bits of online discussion about it are Internet Archives snapshots of a forum long since dead.

And also you don't get to integrate it very well if everything around it isn't maintained, and compatible on old version of a library (with said documentation not existing anymore).

Also, while resume-driven development is not a good thing either, it's certainly not a good investment to pigeonhole your career into working with something you hate working with.

Re: XML is the future

#345
Wondering why web apps that do genuinely need to be react based or similar because of complex interactivity aren't being built as cross platform desktop apps using something like GTK. Performance would be much better, there would be a rich set of ready to use GUI components to use etc

Re: XML is the future

#346
post #315

Earlier quoted context omitted.

that's a long explanation on how to use various features of a notation. would it be easier to just use json? You have many moving pieces with a complex notation, a complex domain, and potentially multiple architects..

If you have a simple use case, yes. If you need the things that XML has, no, JSON is not simpler. It is more complex. Every attempt to embed XML/HTML into JSON has resulted in something worse than XML/HTML... and they are all different , too, which is bad. The main problem with XML is that most people don't need what it has. The main problem with XML in the late 1990s and early 2000s is that it was jammed in many pla…

It indeed seems like we agree :)

Re: XML is the future

#347
All development frameworks and new tech are about reducing the amount of labor required to produce outcomes. This can mean reducing the amount of up-front labor required (running JS on the frontend and backend means that junior devs only need to know one language), or reducing the amount of refactoring required later on (more structured SPA frameworks like angular turn everything you want to do into a matter of boilerplate CRUD). In both cases, it's about having a uniform pattern for anything you want to do so that onboarding new people to the project is easier. Want to get some blog posts for this view? Inject the IBlogService. Want to get a list of all authors? Inject the IAuthorService. Without having read the docs, you can starting typing "I{ThingIWant}Service" and your IDE will pop up whatever services are available.

I see a lot of old school developers complaining about the abstraction of frameworks and how it was simpler to code things in CGI, PHP, C, etc. when you were closer to the machine, or at least were managing the state of the program manually and not through some framework which uses reflection and @Decorators/Annotations everywhere to declare things. But such systems mean that whenever you bring some new junior dev on, they have to spend 6 months learning how your system works, being totally useless to the company in the meantime (especially since college doesn't seem to teach useful job skills anymore).

As it is now, even though there's a million different fad frameworks out there, they're mostly all about the same. I can easily transition between nestjs, .net mvc, or spring boot because they all imitate spring. Frontend frameworks are usually about the same too, and sometimes the frontend is shockingly similar to the backend (like Angular).

I'd much rather work with the banality of angular/react CRUD/boilerplate than have to write another line of unframeworked PHP, or manually write another Apache2 routing config file ever again. That's not to mention operations stuff: CI/CD, despite all of its attempts to boil all possible program states and logic down into infinitely complex declarative yaml files and containerizing everything, is better than the alternative: SSH'ing into a server, manually dealing with system library dependencies, and copying files into /var/www

Re: XML is the future

#348
After doing web dev since the late 90s I've seen plenty of trends come and go.

It's all about tradeoffs. There's no silver bullet. Analyze the problem and then decide on a solution.

People praise the last hyped trend as the next coming of Christ until they find out the drawbacks and move on to the next hype.

Re: XML is the future

#349
post #7

I've been working in the tech industry in the US for about 5 years. Ever since I knew myself I've been coding. From middle school to high school, given any problem, like Sudoku, or keeping up daily chores, my solution was Programming! Programming wasy homebase. Then I studied it in uni, thought I was kinda good at it, and loved it. But when I started working in the industry, I realized that it's absolutely exhausting…

I've been in the industry for over 30 years and I absolutely get where you're coming from. It is an ever changing field and it can be exhausting. I hear this repeatedly from many coworkers (and workers from the same field).

All I can give is some advice from my lengthy experience.

Most of the changes happen on the "edges". Those edges are primarily three fold:

First, the user interface: everything that deals with input parsing and formatting. This also includes protocol marshalling (Http, JSON, XML, ...)

Second the data persistence. This involves choice of database or any other persistence. Including serialisation of your data. Any I/O really.

Third, anything to do with deployment. This includes environment isolation, configuration management, process automation and so on.

These the edges have nothing to do with your core application logic.

You can reduce the impact of a switch to a new stack by inflating your core logic and shielding it from the rest of your stack.

This is tricky and I still catch myself all the time doing it wrong. Because doing it wrong is tempting and easy.

For example, consider a connection to the db: you will need a connection string. You can fetch that from an environment variable somewhere deep in your core code. But by reaching out to the system like that, you make that core piece of code dependent on the deployment strategy. Instead, you can move that part as close as possible to the entry point and then pass it down as function/class arguments. You can group similar operations together, close to the entry point. That way, if the dependent e strategy or the stack changes, your core code does not need to change.

Another example is the case where your core code is dependent on a library from your stack. For example, when working with python and flask, it's easy to import "request" or "g" from the framework. But every piece of code relying on that will be tightly coupled to the framework and subject to change whenever the framework changes (either same framework with breaking changes, or framework switch). The solution is the same. Move those elements as close as possible to the entry points. In this example of flask, keep this as close as possible to your routes. But also keep your routes clean of core logic. Interact with the HTTP layer only and pass the values as arguments to your core.

Finally, a similar situation, but much more sneaky and hard to spot is reliance on data types from your stack. Spotting cases where you rely too much on library modules can be done by investigating imports. But reliance on data types is harder to spot. Sticking with the flask example: the http headers are encapsulated by an object of the flask stack (werkzeug in this case). You may be careful and extract the headers in the route to follow my earlier example. But if you then pass the headers unmodified down into your core logic you will again be coupled to the stack. Instead you should extract only the values you care about and hand only those down to break the coupling.

Finding the right balance where to cut the coupling is challenging. The more you cut, the better you will be shielded from changes. But the less you can benefit from pre existing implementations from the stack. Where to cut is ultimately a design decision.

When done well, it will be far less frustrating to jump on the bandwagon of the latest tech. Not completely painless but far less stressful. Not least because you will have confidence that you didn't accidentally break core logic.

Re: XML is the future

#350
post #335

Earlier quoted context omitted.

So how old does the tech need to be?

The older the better. The better understood, both in capability and limitation. The better chance no new updates will break it. The better chance no new updates. The better you get to know it. The better you get to integrate it. The better the chance it will be there tomorrow too. The better the investment learning it becomes.

> The older the better.

But remember to use the right tool for the right job - older isn't always better. E.g. there is a set of people who use stored procedures for everything and it does make sense when you are doing data-heavy processing on database-side. But using that for everything, even when the volume is absurdly low, is a bad idea - using a language like Java would be a million time more flexible, composable, testable (unit tests, anyone?) and allow making changes with greater confidence.

Post reply on HN