0

I'm currently learning gitlab ci/cd and ran into a problem. I am a java developer and I have written a multi-module maven project with microservice architecture. At the root of the project, I have a BOM file in which the heir modules are declared and dependencies are declared in the dependencyManagment tag so that all microservices use the same versions of spring-cloud. Each module has its own repository. Logically, each module has its own database and pom refers to the parent (bom) to import dependency versions. The question is that when writing gitlab pipelines, I get an error: Non-resolvable parent POM for (module name) ... It is logical that he has nowhere to get dependency versions, etc., but in this case, how to control the versions of the libraries of all modules or can maybe it's not needed at all? Help me come up with a work plan. At the moment the diagram looks like this: root(bom) -> childModule(pom) alsoRoot -> childModule(pom)

Harry Coder
  • 2,429
  • 2
  • 28
  • 32
Limbo1111
  • 9
  • 4

1 Answers1

0

First, try this link for your error.

Also, for your project unless it represents a whole microservice, it is fine. But, it seems like you have implemented many microservices in one project. Every microservice should be an isolated project with its own dependencies and release process. Each microservice project should be:

  • Independent
  • Autonomous
  • Easy to deploy individually
Harry Coder
  • 2,429
  • 2
  • 28
  • 32
  • In general, I understand what is the cause of the error, the question is a little different, did I correctly organize the project structure with dependencies in the parent pom for all child projects? Now I understand that no – Limbo1111 Feb 18 '23 at 06:58
  • Microservice is more about how you know well your domain and your ability to split your domain very well. It comes with many changes into your organization. For learning purpose, I will suggest you to split your project into different microservices and learn the basics of microservice from this. – Harry Coder Feb 18 '23 at 15:11