egametang/ET · warning · Exception
service discovery incremental register response mismatch sce
Error message
service discovery incremental register response mismatch scene: {sceneName}, actual: {rawResponse?.GetType().Name} What it means
Thrown at line 892 in TrySyncRegisterSceneAsync (incremental scene registration): the master responded with a type that is not ServiceRegisterResponse. The raw response is disposed and an exception is thrown, which is then caught by the surrounding try and handled as an incremental-sync failure (HandleIncrementalSyncFailure). It indicates the response contract does not match the request.
Source
Thrown at Packages/cn.etetet.servicediscovery/Scripts/Hotfix/Server/ServiceDiscoveryAgentSystem.cs:892
}
}
try
{
TimerComponent timer = self.Root().TimerComponent;
ETTask<IResponse> registerTask = self.MessageSender.Call(targetActorId, request);
IResponse rawResponse = await registerTask;
self = selfRef;
if (self == null)
{
(rawResponse as MessageObject)?.Dispose();
return false;
}
if (rawResponse is not ServiceRegisterResponse response)
{
(rawResponse as MessageObject)?.Dispose();
throw new Exception(
$"service discovery incremental register response mismatch scene: {sceneName}, actual: {rawResponse?.GetType().Name}");
}
if (response.Error != ErrorCode.ERR_Success)
{
int error = response.Error;
string message = response.Message;
response.Dispose();
throw new RpcException(error,
$"service discovery incremental register failed scene: {sceneName}, error: {error}, message: {message}");
}
response.Dispose();
self.MarkPublishedSceneSynced(sceneName, version);
return true;
}
catch (Exception e)
{View on GitHub (pinned to 5cab01f7a8)
Solutions
- Deploy matching message/assembly versions across all processes.
- Regenerate protocol definitions so ServiceRegisterResponse identity matches.
- Inspect logs for the actual response type to identify routing/version drift.
Defensive patterns
Strategy: type-guard
Validate before calling
// Confirm response type identity matches across builds before relying on incremental sync.
if (typeof(ServiceRegisterResponse).Assembly.Version != masterAssemblyVersion)
{
Log.Error("discovery assembly version mismatch; incremental sync will fail");
} Type guard
public static bool IsIncrementalRegisterResponse(IResponse r) => r is ServiceRegisterResponse;
Try / catch
// Already caught internally and logged as warning; re-register is triggered. // At the system level, monitor the warning rate and trigger a coordinated redeploy on mismatch.
Prevention
- Keep master and agent on identical message assembly versions.
- Regenerate proto definitions together.
- Monitor incremental-sync warning rates.
When it happens
Trigger: An incremental ServiceRegisterRequest is forwarded to the master, but the returned IResponse is not a ServiceRegisterResponse — e.g. an error/exception response, a mismatched response from an older/newer handler, or routing to the wrong actor. Caught and logged as a warning; triggers re-register.
Common situations: Version skew where master and agent disagree on ServiceRegisterResponse; the master returned a generic error response object; routing misconfiguration sending the register to the wrong handler.
Related errors
- service discovery response type mismatch, request: {requestN
- ERR_ServiceDiscoveryMasterUnavailable
- service discovery endpoint unavailable after resolve, reques
- service discovery response error, request: {requestName}, er
- service discovery request retry exhausted, request: {request
AI-assisted analysis of egametang/ET@5cab01f7a8 (2026-08-13).
Data as JSON: /api/errors/ea1f9923f45e041a.
Report an issue: GitHub.