299
Views
12
Comments
How to play media file from DB (entity)?
Application Type
Mobile, Reactive

GD, colleagues!

We've faced the following challenge with playing audio from DB. Will appreciate your ideas if someone had similar solved experience.

Our media files are stored in DB. They should be played at Client's side but w/o retrieving the whole file  - that's pretty time consuming.

We want to play the component directed to the stream, but facing the error occurred "501". Applying forge component "StreamBinaryData".

2021-09-30 18-38-59
Nuno Ricardo Rodrigues

Hello Anna Mashtalir ,

See this link to see if is this that you need:

https://personal-gxzlvs5j.outsystemscloud.com/PlayAudio/AudioFiles

If yes see the OML in attach.

Hope it helps,

Nuno R

PlayAudio.oml
2020-09-21 11-35-56
Sachin Waghmare

Hello Anna,

Please refer the below link. Hope you will get resolution.

https://www.outsystems.com/forums/discussion/72798/how-to-play-a-video-in-reactive-from-the-source-entity/

Thanks & Kind Regards,

Sachin

UserImage.jpg
Anna Mashtalir

@Nuno Ricardo Rodrigues / @Sachin Waghmare , colleagues, appreciate a lot your prompt replies!

Suppose I should make some additional precisions:

- no need to retrieve data to Client side;

- no need to bootstrap the whole track.


Sachin, yep, we've tried this logic (via your link) but it's a quite slowly and again Client engaging way.

Thnx and will be glad new ideas)


2021-09-30 18-38-59
Nuno Ricardo Rodrigues

Hello Anna Mashtalir,

I don't understand what do you mean by:

1) no need to retrieve data to Client side;

2) no need to bootstrap the whole track;

Do you see my example? The link and the OML?

Best Regards,

Nuno R

UserImage.jpg
Anna Mashtalir

Nuno,

I mean that media files are stored in DB (server side, caching service, fttp service,...) and bootstrapped incrementally while Client side's appealing.

So we want to build a stream on server and then reproduce also the stream at Client side.

yes, I see your link and OML, but it seems irrelevant for our case.

Anyway thnx for your time made.



2021-09-30 18-38-59
Nuno Ricardo Rodrigues

Hello Anna Mashtalir,

Why do you think is irrelevant  for our case? It´ s an example storing the MP3 file on a database in Binary Format and them play in the browser in Base64.

I really don't understand want you need. Maybe another developer can help you.

Best Regards,

Nuno R


UserImage.jpg
Anna Mashtalir

Colleagues, don't pass by! Your help's highly appreciated).

So if you have ideas how to build a binary data stream on server and then reproduce it on Client side, pls no hesitation to write me.

Thnx in advance!

2021-09-30 18-38-59
Nuno Ricardo Rodrigues

Hello Anna Mashtalir

The example that I provide upload the MP3 in binary format and they on client side play the MP3 by converting the Binary to Base64.

I still don't understand what is your issue.

Best Regards,

Nuno R

UserImage.jpg
Anna Mashtalir

Nuno, gd!

The way to convert BinarytoBase64, retrieve data to Client side and play - is comprehensive but irrelevant for us. We've tried it and didn't get desired result: interaction's time consuming and track's are randomly torn.

So we are trying to implement the idea of a binary data directed to stream: to include a stream into HTTPRequest and to get stream in HTTPResponse. But have not succeeded yet. 

I've found similar case discussed on forum but still w/o solution. Thus it's dated a year or two ago, so I hope some of colleagues' also faced such a challenge since then.

2021-09-30 18-38-59
Nuno Ricardo Rodrigues


Hello Anna Mashtalir,  

Now I understand the issue.

I will see if I can find a way to do that.

Best Regards,

Nuno R

2018-05-30 02-48-38
Rui Barbosa

Hi Anna,

Check out these components:

If I understood correctly the point is to serve the data in chunks, getting a 206 HTTP code typical of streaming.

Hope this helps

Cheers

 

2023-12-15 13-47-48
Marian-Vlad Man

Hi @Anna Mashtalir . Did you find any solution to your issue? I am currently in the same situation...


Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.