m_pcClientPtr = new std::shared_ptrAws::Lambda::LambdaClient;
if (NULL == m_pcClientPtr) {
ASSERT(FALSE);
return FALSE;
}
TRACE("CAWSManager::InitFunctions 2n");
Aws::Client::ClientConfiguration config;
config.region = "us-east-1";
config.disableIMDS = true;
// this credential only have access lamba function and s3 read/write to a certain bucket
Aws::Auth::AWSCredentials credentials("my accessKeyId", "my secretKey");
TRACE("CAWSManager::InitFunctions 3n");
*m_pcClientPtr = Aws::MakeSharedAws::Lambda::LambdaClient(ALLOCATION_TAG, credentials, config);
if (NULL == *m_pcClientPtr) {
ASSERT(FALSE);
return FALSE;
}
TRACE("CAWSManager::InitFunctions 4n");
When I run this code,
the logs
CAWSManager::InitFunctions 2 <<– gets stuck for 5 seconds before the next line gets printed
CAWSManager::InitFunctions 3
did anyone else encounter this? running on MacBook Pro Xcode using aws-cpp-sdk version 1.11.330 (from homebrew)
I’ve searched online and the only clue was config.disableIMDS = true;
but it dint work here.