亚洲国产日韩欧美一区二区三区,精品亚洲国产成人av在线,国产99视频精品免视看7,99国产精品久久久久久久成人热,欧美日韩亚洲国产综合乱

java - 微信開發(fā)遇到一個(gè) bug。。access_token 有關(guān)的
怪我咯
怪我咯 2017-04-18 10:54:32
0
1
717

通過微信提供的上傳下載多媒體文件文檔 的下載文件功能時(shí)候。從中控緩存 (單例模式把 access_token 存在內(nèi)存中每次用的時(shí)候去計(jì)算是否到期去刷新)中取 access_token 和從手機(jī)的上傳圖片后的得到 mediaid,直接字符串拼接形成這樣的的鏈接
http://file.api.weixin.qq.com...

這個(gè)鏈接直接通過瀏覽器去下載時(shí)候報(bào) 40001

可是我多刷新幾次后又有圖片出來了。。。

如果說 access_token 過期了應(yīng)該不管怎么刷新的也不行的啊,, 還是access_token刷新機(jī)制就是這樣的。

怪我咯
怪我咯

走同樣的路,發(fā)現(xiàn)不同的人生

reply all(1)
黃舟

I have encountered such a problem, I don’t know if it is the same as yours.

Because ACCESS_TOKEN is refreshed in other places, such as the production environment, the ACCESS_TOKEN in the development environment is invalid.
Vice versa.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template