3 ms·
> Java was full of AbstractSingletonBeanFactory classes long before unit testing became a thing You're right that Java had some long class names to start with,
by cobbzilla 6y ago
> Java was full of AbstractSingletonBeanFactory classes long before unit testing became a thing
You're right that Java had some long class names to start with, but I think it was mostly Spring that introduced the PerhapsOverlyDetailedClassNamingConvention.
Spring's introduction and subsequent wide adoption was a big driver of TDD's growth, which encouraged all those interfaces and mocks.
- watwut 6y agoHonestly, I like long names style of java. I dislike the code style where everyone is using shortcuts for everything.
- cobbzilla 6y agoI don't mind them if they're not too long. And if you can use more recent version of Java, the new `var` keyword is a nice verbosity reduction.
- hibbelig 6y agoI think the point of AbstractSingletonBeanFactory is not the length of the name, but what it does. More specifically, on how meta it is what it does. You can have a bean. Great. You can have a bean that's a singleton. Also great. Then you discover that you can have two different beans that are singletons, and you find that they have one thing in common: how the single instance is created and accessed. Each such singleton bean will have about five lines of code that deal with the single instance, and these five lines will be largely similar. So the Enterprise Java Architect sees that there is something to be abstracted, goes to town, and now you can have seven lines of code configuring the abstraction, so that you can avoid writing the five lines of boilerplate. Unfortunately, the seven lines of configuration will be largely similar for different singleton beans...
- cesarb 6y agoAt this point, I must post the classic "Why I Hate Frameworks" rant: https://web.archive.org/web/20130430052914/http://discuss.joelonsoftware.com:80/?joel.3.219431.12 https://web.archive.org/web/20130430052914/http://discuss.jo...