Hi everyone,
I’m currently working on a project where I have two microservices that are tightly coupled—they both require each other to be up and running during startup, leading to a circular dependency issue. Both services call each other right at initialization, creating a deadlock situation.
I’ve heard some suggestions that Terraform could potentially solve this problem by ensuring both services are started simultaneously on their respective nodes, but I’m not convinced this would fully resolve the issue at the application level.
My question is: Can Terraform, or any of its features, really address this circular dependency at the code level between microservices? Or is this something that needs to be solved by restructuring the services themselves, for instance by introducing message queues, service discovery, or other mechanisms?
I would appreciate any insights or experiences from those who have faced similar challenges.
Thanks in advance!