Live data from Hacker News

Ask HN: What's the largest amount of bad code you have ever seen work?

news.ycombinator.com

551–560 of 601 posts

Re: Ask HN: What's the largest amount of bad code you have ever seen work?

#551
post #366

Earlier quoted context omitted.

Code like this makes me think of the famous line from the film version of Hellraiser: "I have such sights to show you..." Contrast PostgreSQL or... uhh... virtually any other database. Oracle's mess is clearly a result of bad management, not a reflection of the intrinsic difficulty of the problem domain.

Nonsense. The problem domain you dismiss is hideously complicated. Oracle DB and PostgreSQL are entirely different classes of products. No airline runs its reservation system on PostreSQL. That's not a coincidence.

Have you heard the term "marketing"?

Re: Ask HN: What's the largest amount of bad code you have ever seen work?

#552

Earlier quoted context omitted.

The real risk is for people who are too young to know what to ask

I'd hope they wouldn't even consider somebody for this sort of job who's too young to know what to ask.

That's kind of naive, of course you want young people who will work hard and maybe not know what they are getting in to. I was offered a job at oracle back in the day, I would have felt a lot of despair if this is what it was.

Re: Ask HN: What's the largest amount of bad code you have ever seen work?

#554
post #498

Earlier quoted context omitted.

You've violated the terms of service of Oracle Database by insinuating the codebase quality is in any way not superior to any and all competitors. No benchmarks or comparisons may be performed on the Oracle Database Product under threat of grave bodily harm at the discretion of our very depraved CEO.

I doubt the competition (e.g. IBM or Microsoft) has any better code quality. Even PostgreSQL is 1.3M lines of code, so let's get something deliberately written for simplicity. SQLite is just 130k SLoC, so another order of magnitude simpler. And yet, even SQLite has an awful amount of test cases. https://www.sqlite.org/testing.html

Worked on sql server for 10+ years. MS SQL Server is way better than that. The sybase sql server code we started with and then rewrote was as bad as oracle.

Re: Ask HN: What's the largest amount of bad code you have ever seen work?

#555
post #522
post #498

Earlier quoted context omitted.

I doubt the competition (e.g. IBM or Microsoft) has any better code quality. Even PostgreSQL is 1.3M lines of code, so let's get something deliberately written for simplicity. SQLite is just 130k SLoC, so another order of magnitude simpler. And yet, even SQLite has an awful amount of test cases. https://www.sqlite.org/testing.html

It's because software LOC scales linerarly with the amount of man-months spent: a testament to the unique ability of our species to create beautiful, abstract designs that will stand the test of time.

This is an interesting comment, because I can't decide if you are sarcastic or making a deep insightful comment. Because I don't think the statement is true. LOC can go on forever, but it usually happens in things that aren't beautiful and abstract.

Re: Ask HN: What's the largest amount of bad code you have ever seen work?

#556
The ugliest, most incomprehensible code I've ever see was when I had to mess with RedHat's version of Anaconda (for building distros) back in the early 2000s. It was worse than the multi-thousand line TCL screen-scraper that I had to occasionally fix in 1999. It was the first code I'd even seen written in Python. You couldn't really trace anything, it was all so nested and idiomatic. It made the Perl code I inherited from a long-time Perl guru downright comprehensible. I've looked askance at Python since.

Re: Ask HN: What's the largest amount of bad code you have ever seen work?

#557
post #187

I took over a Perl project where every SQL call was an exec to a java program which would make the query. The largest madness was a J2EE mess where persistence was achieved by taking your current object, sending a message bean to the server, it would touch the database and return the result which was being polled for (making it synchronous). The amazing thing is that the client and the server were the same J2EE insta…

"I took over a Perl project where every SQL call was an exec to a java program which would make the query."

and

"Oh, and at the same time, none of this was in source control."

Owwww, that's painful! 12 people spaghetti Perl that did its DB lookups via Java and non of it in source control?

Owwww, owwww, owwww....

Re: Ask HN: What's the largest amount of bad code you have ever seen work?

#559

Earlier quoted context omitted.

Good lord, just reading it can cause panic attack.

It literally gave me a sinking feeling. I’d quit that job on day 0.

But you would have to wait for day 1+ to realize

Re: Ask HN: What's the largest amount of bad code you have ever seen work?

#560
post #18

Oracle Database 12.2. It is close to 25 million lines of C code. What an unimaginable horror! You can't change a single line of code in the product without breaking 1000s of existing tests. Generations of programmers have worked on that code under difficult deadlines and filled the code with all kinds of crap. Very complex pieces of logic, memory management, context switching, etc. are all held together with thousand…

Really interesting post. I have often worked in such a mess of a code even though in orders of magnitude smaller code bases with only a few developers. I would never imagine a project like oracle is like this. Since there seem to be a number of oracle employees around, I would be very interested to know if there have been any propositions to start cleaning up this shit. The man hours wasted from this workflow is so huge that I expect that even a small percent of oracle's developers could be assigned to rewrite it and they would catch up the rest of the product in a reasonable time frame so that in a few years it could be rewritten and stop wasting developers' time.
Post reply on HN