Uh oh, I've done exactly the same thing because i really can't wrap my head around the java package structure, i'm not a java guy; it makes a lot of sense to me to just have everything in /vars as single groovy scripts and call them as steps. How did the refactor go? Was it worth it?
It was absolutely worth it (for me) because I'm a big proponent of unit testing. It just bugged me to have a huge repository of "untested" code that my whole enterprise is depending on. Our shared library has something like 80% unit test coverage right now (post refactor) and a deployment pipeline that makes sure that it doesn't regress.
Of course, your mileage will vary . I'm certainly not going to judge you if you're comfortable having all of your code in vars.
I agree completely in theory; i was just saying to the bosses today that
yes, [onboarding apps to the shared pipeline] is the priority, but the more apps we onboard, the more critical the robustness and reliability of the pipeline is. The more we are relying on it, the more we need to be able to maintain it without breaking it.
Is there a general pattern that develops when doing a refactor like this?
Whenever I start feeling like I'm some sort of jenkins guru, I come across an article like this that puts me in my place.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Uh oh, I've done exactly the same thing because i really can't wrap my head around the java package structure, i'm not a java guy; it makes a lot of sense to me to just have everything in
/vars
as single groovy scripts and call them as steps. How did the refactor go? Was it worth it?It was absolutely worth it (for me) because I'm a big proponent of unit testing. It just bugged me to have a huge repository of "untested" code that my whole enterprise is depending on. Our shared library has something like 80% unit test coverage right now (post refactor) and a deployment pipeline that makes sure that it doesn't regress.
Of course, your mileage will vary . I'm certainly not going to judge you if you're comfortable having all of your code in vars.
I agree completely in theory; i was just saying to the bosses today that
Is there a general pattern that develops when doing a refactor like this?
Whenever I start feeling like I'm some sort of jenkins guru, I come across an article like this that puts me in my place.