I want to know how to get a File Object from the resource url distributed as cdn.

0

First of all, we previously used a method of fragmenting video or audio files from our own server (S3FS) and sending them to the app and receiving them and playing them streaming on the app, but because of the increased server load, we want to change it to a method of creating a File object from the corresponding image url distributed on the CDN and sending it to the app. However, the problem occurred and the code part where the error occurred is as follows.

val filePath=URL("{cdnUrl}{midPath}{fileName}") val file = Paths.get(filePath.toURI().path.toFile()

Thereafter, a FileNotFoundException occurs in the file.exists().

If you directly access cdn pull from your browser, the video file will be downloaded. I'd appreciate it if you could answer which part is the problem.

posta 7 mesi fa151 visualizzazioni
1 Risposta
0

In order to create File Objects from Image URL distributed by CDN(CloudFront), I understand that you have deployed code provided which is running on Origin/Application. We understand that you need assistance in validating the code part which triggers error, unfortunately code support is not provided by AWS[1].

We would suggest you to analyze the logic being applied on your server to generate fragment URL’s from image URL and implement similar on your code.

Useful Link: [1] https://aws.amazon.com/premiumsupport/faqs/#:~:text=AWS%20Support%20does,accounts%20or%20systems

AWS
TECNICO DI SUPPORTO
con risposta 7 mesi fa

Accesso non effettuato. Accedi per postare una risposta.

Una buona risposta soddisfa chiaramente la domanda, fornisce un feedback costruttivo e incoraggia la crescita professionale del richiedente.

Linee guida per rispondere alle domande