question

bda2206@gmail.com avatar image
bda2206@gmail.com asked

C# requests hang no response

1 comment
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

bda2206@gmail.com avatar image bda2206@gmail.com commented ·

Hi,

Was happily testing my app, and then a cloudscript request just hung without coming back.

Now I can't get either iphone device to even get past loginwith IOS device ID, they just hang there.

Tried updating to latest SDK via nuget,,

have I hit a limit?

thanks

0 Likes 0 ·
Andy avatar image
Andy answered

My best guess right now, based on my understanding of the system, is that the client's device no longer has a valid endpoint in Amazon's SNS system (used by the PlayFab backend for messaging). I don't know precisely why this would happen in your scenario, though.

The workaround would be to call RegisterForIOSPushNotification again on the player's device. This would create a new endpoint and should eliminate the error we're getting back from SNS.

1 comment
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

bda2206@gmail.com avatar image bda2206@gmail.com commented ·

as it turned out, I had an async without await in front and the other thread was doing the wrong thing, hanging my app in between the debug lines before and after the web call. timing is everything lol.

took a bit to find it.

0 Likes 0 ·
bda2206@gmail.com avatar image
bda2206@gmail.com answered

downgraded from 1.33... to 1.27.. in nuget and it came good.

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

bda2206@gmail.com avatar image
bda2206@gmail.com answered

I'm still having random issues where the requests to the playfab server just hang the application. how can I catch this and recover?

3 comments
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

franklinchen avatar image franklinchen commented ·

Could you please share more details? Like cloud script, Title Id, API.

0 Likes 0 ·
bda2206@gmail.com avatar image bda2206@gmail.com franklinchen commented ·

Title ID is 65D6, cloud script is just sending a push message (works 99% of the time)

API version is 1.27.180529.

handlers.SendPushNotification = function (args,context){


jsonObjectIOS =
{
	"customData" : args.Message, // include any additional data here
	"content-available": 1
};
 
let jsonStringIOS = JSON.stringify(jsonObjectIOS);
 
let plattformIOS = "ApplePushNotificationService";


let pushNotificationResult = server.SendPushNotification
            ({
                Recipient: args.Recipient,
                AdvancedPlatformDelivery: [

                {
                    Json: jsonStringIOS,
                    Platform: plattformIOS
                }
            ]
            });


}

0 Likes 0 ·
bda2206@gmail.com avatar image bda2206@gmail.com commented ·

hmm

AcrossDebug:{"Result":{"APIRequestsIssued":1,"Error":{"Error":"CloudScriptAPIRequestError","Message":"The script called a PlayFab API, which returned an error. See the Error logs for details.","StackTrace":"Error
    at handlers.SendPushNotification (65D6-main.js:112:37)"},"ExecutionTimeSeconds":0.0398889,"FunctionName":"SendPushNotification","HttpRequestsIssued":0,"Logs":[{"Data":{"api":"/Server/SendPushNotification","request":{"Recipient":"5F95325C0FECE40D","AdvancedPlatformDelivery":[{"Json":"{\"customData\":\"message:MadeMove:SharedGroupId:sd-BF56F62DAD9797D8:OpponentName:Issi\",\"content-available\":1}","Platform":"ApplePushNotificationService"}]},"result":null,"apiError":{"code":400,"status":"BadRequest","error":"PushServiceError","errorCode":1095,"errorMessage":"iOS Push Notification Failed: InvalidParameter Invalid parameter: TargetArn Reason: No endpoint found for the target arn specified","errorHash":null,"errorDetails":null}},"Level":"Error","Message":"PlayFab API request error"}],"MemoryConsumedBytes":37840,"ProcessorTimeSeconds":0.0,"Revision":15}}

0 Likes 0 ·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.