Agora-Flutter-SDK icon indicating copy to clipboard operation
Agora-Flutter-SDK copied to clipboard

Agora Cloud Recording API Internal Server Error

Open bimomobile opened this issue 3 years ago • 7 comments

Hi, i had a issue when i implement cloud recording using this api

https://api.agora.io/v1/apps/{{APPID}}/cloud_recording/resourceid/{{resourceId}}/mode/{{mode-type}}/start

Steps to reproduce the behavior:

  1. Hit this api to get resourceid (Status code 200)

https://api.agora.io/v1/apps/{{APPID}}/cloud_recording/acquire

  1. After that start recording using this api (Status code 500)

https://api.agora.io/v1/apps/{{APPID}}/cloud_recording/resourceid/{{resourceId}}/mode/{{mode-type}}/start

{ "resourceId": "nUwUbQf9Zg6tsgtLslGnDg0lk8RYaUE09pqOuSIgwfyDM-G9-5eE37hZ21xKUaZaOGGH08JVoIVzk1SU7OD0y3vM_Qqxj-5PzUYDHhrDnXGRSbkP-iTuStEp5wwdDqrI9Z5m4gZaq0xqx756xMVoDVy0Ggn2X6aDWKcl4U9tpJhGxRt2y3j88Eh9LNiGIH4SPWclibiOeEvcThz9yxnOdmWHzJDdgxyxOKlUgoSqfyw2EeiH8cZGUK9CaXdav0l5oFG7c9BDA0tGLak0p8cYF4C2288fcvLFTD7zv0urSffX4wyznCJkX6TyEHKeRqGBCPFLzH-OvK8vOOWcEI8izRBWNxPz1VgMa3LTTBRLbhc", "sid": "", "code": 15 }

Based on documentation, i put all parameter for request body but i had that issue. It's weird because i can hit api for acquire but when i start recording, internal server error happened.

Im using flutter to create the project.

Can anyone explain what happened? Thank You

bimomobile avatar Sep 15 '22 03:09 bimomobile

@bimomobile could you pls provide a sample request body so that i can help take a look?

plutoless avatar Sep 19 '22 01:09 plutoless

@bimomobile could you pls provide a sample request body so that i can help take a look?

Hi @plutoless , this is my request body

{ "cname":"jQfYGZZt", "uid":"97103", "clientRequest":{ "token":"00639c0a7208b1843ab92d2f1d0a877e656IADyW2MY++/Rtndp2/a2MeASKNtb5Bv1cBqjFN8HToze6P0L0TqwNdBCIgBuIZYEmN0jYwQAAQAomiJjAgAomiJjAwAomiJjBAAomiJj", "recordingConfig":{ "maxIdleTime":120, "streamTypes":2, "audioProfile":1, "channelType":1, "videoStreamType":0, "transcodingConfig":{ "width":360, "height":640, "fps":30, "bitrate":600, "mixedVideoLayout":1, "maxResolutionUid":"1" } }, "storageConfig":{ "vendor":6, "region":6, "bucket":"test-mobile", "accessKey":"*******", "secretKey":"*******" } } }

bimomobile avatar Sep 19 '22 02:09 bimomobile

@bimomobile how did you get your google account ak/sk? code 15 means the sth is wrong with your storage config. make sure you are getting it from Interoperable storage access keys when creating new google cloud storage source.

plutoless avatar Sep 19 '22 02:09 plutoless

@bimomobile how did you get your google account ak/sk? code 15 means the sth is wrong with your storage config. make sure you are getting it from Interoperable storage access keys when creating new google cloud storage source.

@plutoless i got that ak/sk from our cloud engineer. Ok i will ask to our cloud engineer, and i will inform you later. Thank You

bimomobile avatar Sep 19 '22 02:09 bimomobile

Hi @plutoless i already add new ak/sk, and start recording successfully. But i had another issue when stop recording. I got this error with status code 404 { "resourceId": "nUwUbQf9Zg6tsgtLslGnDg0lk8RYaUE09pqOuSIgwfyDM-G9-5eE37hZ21xKUaZaOGGH08JVoIVzk1SU7OD0y3vM_Qqxj-5PzUYDHhrDnXE6YwovU4ZhDZhWgIuJeWq9JZW8KH-JuveNaGTW_Wp4wlxHHE6Fsnk09HqyQmxbfD9faw89u5vkzs_5M82WR4nzLvAY7JL0XKYaah2Edye_zX32LS41e8slz4BhvN54VIFAQg_44tYxIaK4-nOIuV-x8q5eM-NgU3BQyzqRxsaC-G_eRBHpct-Y6nNpst0rM335TWWH5zh4HiAtha-TjsCwLEFRCfWoBGiKN81lTTWmH5q2UR1217d62Ibq5I50w29LXGBCmGgEQqRTg8mL4o40", "sid": "7abe57914741842f8255e880caf21895", "code": 404, "serverResponse": { "command": "StopCloudRecorder", "payload": { "message": "Failed to find worker." }, "subscribeModeBitmask": 1, "vid": "990958" } }

What's wrong with this?

bimomobile avatar Sep 19 '22 07:09 bimomobile

it might be the worker has exited the channel already. maybe you can try integrating the notification service to see the reason why the recording exited after started.

https://docs.agora.io/en/cloud-recording/cloud_recording_callback_rest?platform=RESTful

plutoless avatar Sep 19 '22 09:09 plutoless

Hi @plutoless i already try integrating the notification service, but i didn't get the answer. For the storage im using google cloud, Is this error related to Google cloud?

bimomobile avatar Sep 23 '22 07:09 bimomobile

Hi please helpme to find out 404 issue

Ashoklamba01 avatar Jul 19 '23 11:07 Ashoklamba01

https://api.agora.io/v1/apps/{{APPID}}/cloud_recording/resourceid/{{resourceId}}/mode/{{mode-type}}/start

Ashoklamba01 avatar Jul 19 '23 11:07 Ashoklamba01

{ "cname": "KendradVKM32555", "uid": "123", "clientRequest": { "token": "3cWPeAHVGUek36K7sYQRJIuncwoJJJL1COWYs7hujwHfPitnoWRpWrfN5p3KznYxOzS-nMXGkap6htcl-jRMxjLip3Bw-Dwy8_LY9X2i4IlYhqcDP6FHkG4SbQeWsZT835cxTjYYkfPgfvXoXWhYbbZ9uH4hpX5vUKVnqxx3ccamGIbNeiY6Szx9g7v8HM9EgDWf78tSqhFg2NIPqJvOUbjHfUIlXwOc7CVEb6HjPNY", "recordingConfig": { "channelType": 0, "streamTypes": 2, "audioProfile": 1, "videoStreamType": 0, "maxIdleTime": 120, "transcodingConfig": { "width": 360, "height": 640, "fps": 30, "bitrate": 600, "maxResolutionUid": "1", "mixedVideoLayout": 1 } }, "storageConfig": { "vendor": 1, "region": "Asia Pacific (Mumbai) ap-south-1", "bucket": "s3", "accessKey": "XSSSSKJJKJKJKJ", "secretKey": "@@@@@@@@@@" } } }

Ashoklamba01 avatar Jul 19 '23 12:07 Ashoklamba01

how i play live recording m3u8 in our flutter app.

himanshudeveloper avatar Nov 06 '23 08:11 himanshudeveloper

Please submit a ticket to Agora Support for further investigation of this issue. If you have any conclusions, you can share them here which may help other developers. Thanks!

github-actions[bot] avatar Dec 07 '23 09:12 github-actions[bot]

Without additional information, we are unfortunately not sure how to resolve this issue. We are therefore reluctantly going to close this bug for now. If you find this problem please file a new issue with the same description, what happens, logs and the output. All system setups can be slightly different so it's always better to open new issues and reference the related ones. Thanks for your contribution.

github-actions[bot] avatar Dec 21 '23 09:12 github-actions[bot]

This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please raise a new issue.

github-actions[bot] avatar Dec 28 '23 10:12 github-actions[bot]