question

mariogarranz avatar image
mariogarranz asked

Azure Function call failing

We were using CloudScript to directly call the Facebook API to send messages to players. However, because the Facebook API takes longer than the 1 second limit for Cloud Script to respond, most requests were failing.

We have decided to move this from the PlayFab CloudScript into a separate Azure function, but now I can't seem to call this function from PlayFab.

I did register it in PlayFab and then created a test Scheduled Task to verify it reaches Azure properly, however it always fails with no further explanation in the log. If I test the HTTP request directly against Azure using Postman it works.

Any idea on what is going on here?

image.png (78.1 KiB)
10 |1200

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

1 Answer

·
Seth Du avatar image
Seth Du answered
4 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.

mariogarranz avatar image mariogarranz commented ·

Thanks for your responde SethDu, but the issue is not with Facebook. I did not even implement the Facebook REST API call on the function.

The issue is I can't even get the Azure function fired from PlayFab. It just doesn't reach the Azure server and it doesn't provide any data on what's failing.

If I fire a HTTP request manually against the Azure function, I see the data incoming on the logs. If I try to fire it from PlayFab I see nothing on Azure, so it's not even reaching it.

0 Likes 0 ·
mariogarranz avatar image mariogarranz commented ·

Basically this is the code for my function right now. It's just listening for HTTP requests and logging the incoming data.

I wanted to make sure I could receive data before implementing the Azure to Facebook communication.


0 Likes 0 ·
mariogarranz avatar image mariogarranz commented ·

Sorry @SethDu the upload was from an undeployed change I made. This is the live vesion which sends the response.
It is still irelevant, since the problem is PlayFab not even reaching the Azure function at all.

0 Likes 0 ·
Seth Du avatar image Seth Du ♦ mariogarranz commented ·

Have you referred this documentation to implement Azure function?

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.