Closed tmokmss closed 1 year ago
As an aside, your solution looks similar to the example @pooneh-m just sent a PR for (https://github.com/googleforgames/agones/pull/2499) except that you are using an Agones cluster w/ MCA for routing the requests instead of using cloud run.
That warning is coming from this line. It looks like after a successful allocation, the allocator service is trying to look up the game server in the local cluster and failing to find it (because it doesn't exist in the local cluster).
It feels to me like this lookup should be skipped if we know that the allocation was from a remote cluster. The function applyMultiClusterAllocation
doesn't currently return whether the allocation was done locally or not so the code site which calls setResponse
for the metrics can't hint at whether the game server should exist in the local cluster.
The good news is that this warning is benign. But it will take a bit of refactoring in the code to be able to skip the lookup when it shouldn't be done.
What happened: When I use multi-cluster allocation feature in the below configuration, where
Router
cluster is just dispatching allocation request toDGS clusters 1,2
, I'm getting invalid warnings from the agones-allocator pod onRouter
cluster. On each allocation, this kind of log appears.Printed logs are below. You can see warnings like
gameserver.agones.dev \"dgs-fleet-nf97g-pszwg\" not found
on every allocation.It seems Router cluster is trying to get information about gameserver on DGS clusters, resulting in
not found
errors.What you expected to happen: No warnings shown.
How to reproduce it (as minimally and precisely as possible): Don't know specifically how to repoduce this. At least I'm just using multi-cluster allocation in the way written in docs and warnings are always printed.
Anything else we need to know?:
Environment:
kubectl version
): 1.21.0