訪問AWS S3得到異常:無法從Android
Unable to execute HTTP request: Unable to resolve host "cognito-identity.eu-central-1.amazonaws.com": No address associated with hostname
Unable to resolve host "cognito-identity.eu-central-1.amazonaws.com": No address associated with hostname
的代碼如下:
// Initialize the Amazon Cognito credentials provider
CognitoCachingCredentialsProvider credentialsProvider = new CognitoCachingCredentialsProvider(
getApplicationContext(), // Application Context
getResources().getString(R.string.AWS_IdentityPoolId), // Identity Pool ID
Regions.EU_CENTRAL_1 // Region enum
);