Pergunta

I have recently become familiar with Erlang/OTP technology and I would like to apply it to monitor and supervise Java applications in terms of:

  • detecting their availability
  • starting and stopping them

In other words I would like Java applications to be seen by Erlang OTP supervisor infrastructure as a regular Erlang apps that can be managed by those supervisors (sending heartbeats, stopping and starting on demand). Is it feasible? If yes, what tools do I have to use?

For simplification, let's assume that a Java application is a simple jar with Main class specified. Instrumenting/extending those applications is allowed.

Foi útil?

Solução

Unless there's an existing Erlang application that you need to use, I'd suggest using the Akka library, which is greatly influenced by OTP and will let you create supervisor hierarchies using just JVMs.

Outras dicas

Another library you might check out is Sarge, which takes inspiration from Akka's supervision and applies the concept to any object.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top