danikula / danikula/AndroidVideoCache

Long response to incorrect url

Open
#137 0 comments 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
Java
Stars
5.5k
Forks
1.2k
PR merge metrics
No merged PRs in 30d

Description

@liu-xiao-dong wrote in #136 :
> 04-28 10:04:00.515 5271-5271/com.example.android.uamp E/uamp_LocalPlayback: error url: http://www.baidu.cccc
04-28 10:04:00.521 5271-5271/com.example.android.uamp E/uamp_LocalPlayback: error proxyUrl set to media player: http://127.0.0.1:59393/http%3A%2F%2Fwww.baidu.cccc
04-28 10:04:31.193 5271-5271/com.example.android.uamp E/uamp_LocalPlayback: Media player error: what=1, extra=-2147483648
> I use Media Player to play music, if you set a wrong url to AndroidVideoCache, but also lead to the wrong url set to the Media Player, and this time, AndroidVideoCache soon occurred Exception, but after the internal try catch, the external can not accept To Error, and monitor the Media Player Error callback until 30 seconds after receiving the Error message, which will lead to the user can not quickly feedback, resulting in poor user experience.

@danikula:
> I got. In case of direct url network connection quickly reports 500 or 404 error code and MediaPlayer quickly process it. In case of proxied url AndroidVideoCache just closes connection if there is no cache. That is why MediaPlayer performs few attempts. I think exporting error listener is not the best choice. Instead AVD should forward real server's response to client somehow.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.