agones icon indicating copy to clipboard operation
agones copied to clipboard

0.3 seconds interval required for health check with REST interface

Open freegroup opened this issue 2 years ago • 4 comments

I have generated the Swagger definition binding for Python. Which is ok. However the "watch" does not work, because the OpenAPI generator cannot generate streams. Here you have to do it yourself.

The real problem is that with the REST interface I have to choose an extremely small interval for the health check. This is currently 0.3 seconds.

If I set it higher, e.g. 1 second, then the GameServer terminates after a short time. Obviously the SideCar has terminated, because it thinks that it does not get any Health messages in the required timeframe. What surprises me - the gRPC Variant with Go or NodeJS has here a much larger interval. Here are 2 seconds are good to go.

freegroup avatar Dec 17 '21 08:12 freegroup

Are you defining a non-default value for the spec.health.periodSeconds interval?

Health checking is described in https://agones.dev/site/docs/guides/health-checking/#sdk-api and I'm wondering if that documentation helps you at all.

roberthbailey avatar Dec 27 '21 07:12 roberthbailey

Hi,

yes - the documentation helps a lot and I'm reading it. I know the rtfm :-)

I set the the parameter in the fleet

.
.
.
      health:
        initialDelaySeconds: 20
        periodSeconds: 10

and the settings are propagated to the instantiated gameserver

spec:
  container: facedetector
  health:
    failureThreshold: 3
    initialDelaySeconds: 20
    periodSeconds: 10

But if I increment the period of the health call, the pod get unhealthy and agones remove them. Numbers bigger than 0.7 second do not work.

freegroup avatar Dec 27 '21 08:12 freegroup

Random thought: @domgreen when using the Unreal engine integration, you use the REST interface. Do you see the same behaviour?

markmandel avatar Jan 04 '22 18:01 markmandel

@freegroup when you use what you expect to work as the interval, can you turn on debug logging and show us the output of the sdk sidecar please? I wonder if it will give us some insight into what might be happening here.

markmandel avatar Jan 04 '22 18:01 markmandel

'This issue is marked as Stale due to inactivity for more than 30 days. To avoid being marked as 'stale' please add 'awaiting-maintainer' label or add a comment. Thank you for your contributions '

github-actions[bot] avatar Nov 01 '23 10:11 github-actions[bot]

This issue is marked as obsolete due to inactivity for last 60 days. To avoid issue getting closed in next 30 days, please add a comment or add 'awaiting-maintainer' label. Thank you for your contributions

github-actions[bot] avatar Dec 15 '23 02:12 github-actions[bot]