I am sending files (up to 100Mo on my android handled) using the Channel Api
.
I decided to create a handler to update the progress of the transfer to that the user is aware of the progress.
I use the Message Api
to send the file size to my handled and I update the progress checking each x milliseconds the size of the file.
The matter is that I don't know first if that's a good way of doing what I want, and second, due to the fact that it's asynchronous, I have to wait that I correctly received the file size in the onMessageReceived
before sending the file.