Hacker News new | ask | show | jobs
by conistonwater 2893 days ago
I have no idea either, but those are "constants", and so it is only logical that they belong in com.seriouscompany.business.java.fizzbuzz.packagenamingpackage.impl.Constants (https://github.com/EnterpriseQualityCoding/FizzBuzzEnterpris...).
1 comments

I think it’s really shortsighted to hardcode them statically into constants. You’d have to build a completely new binary should the requirements someday change! Obviously they belong behind a configuration interface, an instance of which can then be dependency injected to places that need them. In this way you can easily supply them from whatever source you like, such as a properties file, XML document, a database or even a web service.

As it is now, 2/10 would not pass review.

Sounds like Spring ConfigurationProperties https://docs.spring.io/spring-boot/docs/current/reference/ht...
I'm utterly unsurprised.