Few days ago I had read someone’s blog on how they went with the flow and tried gradle and eventually ended up in a mess and went back to good ol’ maven.
I wasn’t really sure then. And I am not really that sure right now either, as my situation is probably different for one reason, and second, I immensely dislike XML files.
Nevertheless, I get what he was saying. Gradle is no smooth sailing. Quite frequently I find myself struggling with making things work. Plugins, versions, sourcesets…
Verions and Plugins
Gradle is going the python way. Python 2.6, 2.7, 3.4 … and nothing compatible with another. One library in one version, wont work the same in another version. Gradle is also in a similar landscape with all the damn plugins.
Gradle as a build tool, does come with certain sets of plugins. But eventually you will end up depending on a bunch of other 3rd party plugins for your needs. For e.g., spring-boot
. Now, with every new version of Gradle, the dependent plugins are not guranteed to behave the same as before. Moreover, its not even sure if they will even work at all.
So, you are stuck with the old version plugins, and keep hoping to get a newer version released soon so that you can finally close that tech debt item you always wanted to finish.
Multi projects
I was a fan of multi module or multi projects. Not anymore!
- Many of the plugins do not work seamlessly with multi-project settings. Take for example the
release plugin
. Or theJacoco
plugin. - Dependency management among all the sub projects is a pain.
- Integration tests do not work properly when modules depend on each other. I actually had to write sources in one module, unit tests in the same module and integ tests in another module.
Memory and CPU foot print
I dont know how gradle works under the hood. But whenever I run it, it almost kills my machine. I can make an omlete with that much heat. I was hoping in later versions, with all that daemmon, parallelization, it would get better. But even with version 4.8, it sucks amazingly.
Well, I am not going away from Gradle anytime soon. But I wish it stabilizes a bit more.