Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Startup order dependencies problem #748

Open
Snob1337 opened this issue Feb 2, 2022 · 4 comments
Open

Startup order dependencies problem #748

Snob1337 opened this issue Feb 2, 2022 · 4 comments
Labels

Comments

@Snob1337
Copy link

Snob1337 commented Feb 2, 2022

Hi,

we are using the FROST-Server (v1.14.0) with kubernetes.

After investigating our last issues, it looks like the pods has to start in the correct order.

  1. Database
  2. HTTP
  3. MessageBus
  4. MQTT

If the Mqtt is starting before Database modul or MessageBus does, it failes and never try to reconnect again.
The only way to solve this issue is to restart the pod manually.

Is this a known Problem or wrong configured from our side?

Many thanks in advance.

Best regard,
Marc Beckord

@hylkevds
Copy link
Member

hylkevds commented Feb 3, 2022

Yes, it's a known issue. I've already improved it in the 2.0 branch. Maybe I can backport the improvements.
Note that the MessageBus should be on 2 (or together with the DB on 1)

@hylkevds hylkevds added the bug label Feb 3, 2022
@Snob1337
Copy link
Author

Snob1337 commented Feb 3, 2022

Thank you for the fast reply.

to start the pods in the correct order, we need to write an kubernetes-operator by our own.
Unfortunately Kubernetes is not able to setup service-dependencies like Docker Swarm does.

Would be great if you could keep me up to date about backporting the improvements.

Best,
Marc

@phertweck
Copy link
Contributor

Like mentioned by @hylkevds, this is a known issue. That's something that should be extended in the Kubernetes manifest files and the Helm chart. An operator is not needed in this case. It can be solved by using init-containers, that wait until the dependent services are available.

If you like, Pull requests are always welcome :-)

@oldluke92
Copy link

Hi!

Unfortunately init-containers only cover the initial startup - but we also observed issues where already running components (HTTP/MQTT) stopped working after others (DB/Message Bus) were restarted for example due to being moved to another node. This could be a different issue though ....

Best regards
Lukas

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants