4 ms·
Even "experienced" developers who haven't had formal computer science training can run into performance problems. At my last job, our application was running sl
by Johnny555 11y ago
Even "experienced" developers who haven't had formal computer science training can run into performance problems. At my last job, our application was running slower and slower as we added clients. None of the Ruby devs could figure it out, the code was "fine", all of the tests passed and ran quickly (with a stubbed 10 item customer table), and everything ran great until we grew beyond a hundred or so customers so it fell on me to optimize the database which was clearly the problem. I finally took a look at the code and found the problem -- it was a loop within a loop within a loop doing a full scan across the entire customer table disguised by the two inner loops being inside separate Gems. The application had O(n^3) performance. None of the developers knew what that meant so I gave a "lunch-and-learn" presentation on big-O notation and what it means for performance.
- JustSomeNobody 11y agoI've seen this happen with experienced developer with a CS degree. They say, it's "not my job" to test with large data. B.S., it is your job so sit down, shut up and do it. The job of QA isn't to find all your bugs, it's to ensure you don't have any.
- greenyoda 11y agoLong ago, I was asked to fix a bug about a user interface hanging when too many items were added. After poking around, I discovered that there was an algorithm, whose run time was an exponential function of the number of items, that was taking several minutes to run (after which the UI would be responsive again). The punch line was that this algorithm was actually computing a value that was never used by the rest of the code, so I just deleted it. That was in C++ code written by an experienced developer.