After we successfully connected DS in China, there will be a delay of 2-3 seconds in sending RPC messages, is there any solution? Thank you very much!
This delay problem occurred when we updated to AMS
Hi @user13,
We’ll investigate this further and need more information to determine the root cause.
- Has this issue occurred before, or did it suddenly start happening now?
- Can you share the session ID where this issue occurred?
1.yes
2.74351917598d4e2f9bbdd92dc9fcfb6e
Hi @user13,
FYI, we currently do not have a China’s AMS region. Additionally, we identified a few issues with your integration:
- Latency Issue: When creating a match ticket, you did not supply the latency, causing your game to connect to
us-east-2
. We recommend callingQosManager.GetAllServerLatencies
to gather latencies and include them in the match ticket to get the best region for your current location. Here is the guide: Unity Integrating Matchmaking. - DS Log Error: We found this error in your DS Log related to RPC. This could be causing the delayed RPC call:
2024-07-26T06:00:30.368Z NetworkManagerRPC:RpcSendSwitcherPrepared (BeardedManStudios.Forge.Networking.RpcArgs)
2024-07-26T06:00:30.368Z BeardedManStudios.Forge.Networking.Rpc/<>c__DisplayClass16_0:<Invoke>b__0 ()
2024-07-26T06:00:30.368Z BeardedManStudios.Forge.Networking.Unity.MainThreadManager:HandleActions (BeardedManStudios.Forge.Networking.Unity.MainThreadManager/UpdateType)
2024-07-26T06:00:30.368Z BeardedManStudios.Forge.Networking.Unity.MainThreadManager:FixedUpdate ()
2024-07-26T06:00:37.990Z Uploading Crash Report
2024-07-26T06:00:37.990Z NullReferenceException: Object reference not set to an instance of an object
2024-07-26T06:00:37.990Z at NetworkManagerRPC.RPCSyncYokaiSkinArmor (BeardedManStudios.Forge.Networking.RpcArgs args)
2024-07-26T06:00:37.990Z at BeardedManStudios.Forge.Networking.Rpc+<>c__DisplayClass16_0.<Invoke>b__0 ()
2024-07-26T06:00:37.990Z at BeardedManStudios.Forge.Networking.Unity.MainThreadManager.HandleActions (BeardedManStudios.Forge.Networking.Unity.MainThreadManager+UpdateType updateType)
2024-07-26T06:00:37.990Z at BeardedManStudios.Forge.Networking.Unity.MainThreadManager.FixedUpdate ()
Please address these issues first and let us know if they resolve your problems.
Thank you for your help, when I call GetAllServerLatencies it returns error messages:
{“Error”:{“Code”:“ServiceUnavailable”,“Message”:“The server is currently unable to handle the request due to a temporary overloading or maintenance of the server.”,“messageVariables”:null,“InnerError”:null},“Value”:null,“IsError”:true}
@Damar Please help me. Thank you!
Here’s how I call it
@Damar I also have a problem with GetAllServerLatenies, which takes me about 8 seconds to get a message after I call it
Hi @user13,
Please ensure that the Use AMS QoS Server Url
is set to true:
Additionally, if you are using a VPN, it may interfere with the UDP protocol in some cases. Other customers have reported this issue and are experiencing similar problems.
@Damar Ok thanks, I got a new question:
{“Error”:{“Code”:“NotFound”,“Message”:“The server has not found anything matching the Request-URI.”,“messageVariables”:null,“InnerError”:null},“Value”:null,“IsError”:true}
Hi @user13,
It is difficult to determine the problem without a log file. Can you share the text log file in our private message? Here is a guide on Unity - Manual: Log files.
If you are uncomfortable sharing the log file, you can filter out all the AccelByte logs and share those instead.
Thank you.
Thank you, after looking at the logs, it seems the function GetAllServerLatencies
was outdated and needs a fix. Meanwhile, please try to use GetServerLatencies
, it should be working.
@Damar Ok, thanks, but I get another error after calling GetServerLatencies:
Log:
Uploading Crash Report
SocketException: An invalid parameter was provided.
Rethrow as FormatException: An invalid IP address was specified.
at System.Net.IPAddressParser.Parse (System.ReadOnlySpan`1[T] ipSpan, System.Boolean tryParse) [0x0005e] in <23dfa41cc66a415bae1a3ceab34a2df9>:0
at System.Net.IPAddress.Parse (System.String ipString) [0x00014] in <23dfa41cc66a415bae1a3ceab34a2df9>:0
at AccelByte.Api.QosManager+d__3.MoveNext () [0x00091] in .\Library\PackageCache\com.accelbyte.unitysdk@b6ab04098e\Runtime\Api\QosManager.cs:48
at UnityEngine.SetupCoroutine.InvokeMoveNext (System.Collections.IEnumerator enumerator, System.IntPtr returnValueAddress) [0x00026] in <834804db60ae4eb981294088cf979056>:0
(Filename: ./Library/PackageCache/com.accelbyte.unitysdk@b6ab04098e/Runtime/Api/QosManager.cs Line: 48)
Hi @user13,
Apologies for the late reply. The QosManager error will be fixed soon on the next SDK version release.
Thank you.
Hi @user13 , we have released new SDK version to fix the QoS Manager error. Please find the version below :
https://github.com/AccelByte/accelbyte-unity-sdk/releases/tag/16.23.1
Release Notes :
Added a validation check to ensure that server addresses returned by QoS are valid before resolving. If a server address is in IP format, it will be used directly.
Please let us know if you still experiencing any issues.
Thank You
Okay, it’s working. Thank you very much!!