Amazon web services AWS.config.credentials.get()花费的时间太多

Amazon web services AWS.config.credentials.get()花费的时间太多,amazon-web-services,aws-sdk,amazon-cognito,Amazon Web Services,Aws Sdk,Amazon Cognito,我正在使用AWS.config.crendentials.update()来更新我的凭证,我需要最新的cognitoIdentityId,因此有必要调用AWS.config.crendentials的get()方法来获取最新的cognitoIdentityId,因为它花费了太多的时间,多达6-7秒 有没有办法避免get()调用

我正在使用
AWS.config.crendentials.update()
来更新我的凭证,我需要最新的cognitoIdentityId,因此有必要调用
AWS.config.crendentials
的get()方法来获取最新的cognitoIdentityId,因为它花费了太多的时间,多达6-7秒

有没有办法避免get()调用