Continuous integration – deploying only changed components
- Eureka server
- Zuul proxy
- Microservice #1
Each of these components is a separate Docker image and they are sharing a same Git repository. Also Jenkins is available.
My question is it possible when changes are made a single component to only rebuild that docker image and deploy it instead of redeploying everything. What is the common practice in CI?
I’ve thought about this and one possible way that could work is separating modules into different git repositories and using git submodules in the main project, are there better ways to implement this (either in maven/jenkins or in docker) ?
One Solution collect form web for “Continuous integration – deploying only changed components”
I can see no reason that you would have this configured as a single project. I can only imagine the pain it’s causing beyond the issues your question raises, and I urge you to split this into separate git repos with separate build systems as soon as you can possibly arrange it. I wouldn’t bother with the git submodules either. This isn’t a project — this is three entirely separate components that should be versioned independently and have independent lifecycles, therefore should be in separate repos with separate build systems. As it stands, you’re doing to much work already and you’re likely to do a lot more unnecessary work as you start to accidentally break things not related to the change you’re making.
I’m currently working in a senior position in one of the world’s largest banks, and I’m giving the same advice to the development teams I’m working with right now. Microservices especially call for independent evolution and isolation.