简体   繁体   中英

Getting error in uploading image with AFNetworking in Objective-C

Getting error in uploading image with AFNetworking in Objective-C:

Error Domain=com.alamofire.error.serialization.response Code=-1011 "Request failed: bad gateway (502)

Take a look at https://en.wikipedia.org/wiki/List_of_HTTP_status_codes

A 502 error indicates a problem with the server you're trying to upload to, and in particular, with one of its upstream servers. If you're not getting this error on other clients trying to upload to the same URL (eg, a web browser), in my experience the culprit is the gateway server and upstream server not dealing with headers the same way, but your mileage may vary.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM