Swift-Amazon-S3-Uploading-Tutorial
Swift-Amazon-S3-Uploading-Tutorial copied to clipboard
Getting the below error. can you please help me to fix this.
AmazonS3Upload[7318:370039] Returning ENOTCONN because protocol has not yet been set up
AmazonS3Upload[7318:370039] Task <7E4BB0B5-4C03-4551-B9FD-06A314F6CE85>.<4> HTTP load failed (error code: -1005 [1:57])
Returning ENOTCONN because protocol has not yet been set up The operation couldn’t be completed. (com.amazonaws.AWSS3ErrorDomain error 0.) facing the same issue, reply soon
I have same issue since morning, plz suggest a solution.
Could someone please to share AWS keys to test it?
Yes .. I got same issues ... Returning ENOTCONN because protocol has not yet been set up
Task <CC4C0EEC-2E50-444F-8688-1CFC14767B74>.<1> HTTP load failed (error code: -1005 [1:57])
I solved the error. It has to do with the region of the S3. You have to set the correct region in order for it to work. Currently, it's hardcoded to USEast1
:
let configuration = AWSServiceConfiguration(region:AWSRegionType.USEast1, credentialsProvider:credentialsProvider)
So I changed it to the region of my S3 bucket:
let region = AWSRegionType.USWest1
// ...
let configuration = AWSServiceConfiguration(region: region, credentialsProvider:credentialsProvider)
Also: never share your AWS keys.