Hacker News new | ask | show | jobs
by meerita 91 days ago
The worst experience I had was with a telecom company. They had an internal web app that allowed them to upload a gigantic CSV file with millions of records from new phone activations. The web app took 59 minutes to process it!

The culprit: a single 30K .js file with one function, more and more recursive functions, and deeply nested if/else statements, up to 10 levels.

We spent one month undoing that Gordian knot and got the same process down to less than a minute. With AI, we probably would have done it in less than a day, and with a better programming language, probably even faster.

1 comments

If it only took 59 minutes to process millions of records, it was nowhere near as bad as it could have been. At around one millisecond per record, it sounds like you probably don’t even have any accidental quadratic time complexity on the number of records! What are you complaining about?
I know a phone company where just the cronjob that sends bills took over 3 days to run. I guess it's not a problem until it takes more than a month.
They had another internal tool written in php 4, 2 days and 20 hours running as well, and we untied everything in minutes.