Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Request Timed out with Code

Error Domain=NSURLErrorDomain Code=-1001 "The request timed out." UserInfo={NSUnderlyingError=0x608000244a70 {Error Domain=kCFErrorDomainCFNetwork Code=-1001 "(null)" UserInfo={_kCFStreamErrorCodeKey=-2102, _kCFStreamErrorDomainKey=4}}, NSErrorFailingURLStringKey=http://www.dfdd, NSErrorFailingURLKey=http://www.dfdd.com, _kCFStreamErrorDomainKey=4, _kCFStreamErrorCodeKey=-2102, NSLocalizedDescription=The request timed out.}

Am getting this response calling MY API.. am using alamofire to call the api.. Is any problem in alamofire or local API

like image 704
Amutha Kumari Avatar asked Oct 19 '25 14:10

Amutha Kumari


1 Answers

You have to following solution.

  1. Connect with fast internet connection because your request carry heavy data.
  2. Set request timeout to session manager

    manager.session.configuration.timeoutIntervalForRequest = 120

like image 86
KKRocks Avatar answered Oct 21 '25 04:10

KKRocks



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!