opensergo / opensergo-java-sdk

OpenSergo Java SDK
Apache License 2.0
41 stars 24 forks source link

keep opensergoclient alive #7

Open jnan806 opened 2 years ago

jnan806 commented 2 years ago

To keep OpensergoClient always be alived.

In current version, when opensergo-control-plane was shutdown , opensergo-java-sdk could not reconnect to opensergo-control-plane. So i improved it.

1、add an enum to defined the status of OpensergoClient. 2、add a keepalive function which was invoked in the start process of OpensergoClient. 3、record and change status for the OpensergoClient instance.