title: How to tell what AWS credentials Spark is using to read S3 files?
body: <p>I am running an Oozie job that previously was running fine. And now I have a permission denied error when accessing S3 files. I am just trying to figure out which credentials it is using and where to fix them.</p>
  
  <p>As far as I can tell credentials seems to come from several locations and not sure the order of precedence (e.g. ~/.aws/credentials, environment variables, hadoop configuration, IAM role, etc). </p>
  
  <p>Is there a way to tell which is the active credentials being used? Is it possible to print the active AWS account key id in the spark logging?</p>