title: Upload images added to gallery to aws s3 folder automatically from background
body: <p>I have an android application which have integrated with aws cognito(user and identity pools) and aws s3.Sign up and sign in features are working fine and after signing in user can view the images in s3 bucket related to his/her folder in s3 bucket. When user is signing in a directory in s3 bucket is created.Currently images should be uploaded to the relevant folder manually through the aws s3 console.</p>
  <ul>
  <li><p>Now what I want to do is, when new images are added to the gallery(through camera or downloaded from somewhere) it should be uploaded to the user's relevant folder automatically even when the app is closed(similar like google photos app).</p>
  </li>
  <li><p>I don't know is there a method in android to get notified when new image(s) added to the gallery and get that image.(I don't want to delete the image in the s3 when an image is deleted in gallery)</p>
  </li>
  <li><p>And if notified can it be uploaded to the s3 bucket from background since in a token expiry situation user have to sign in again(as I know)?</p>
  </li>
  <li><p>What I want to know is, is this task possible to do?</p>
  </li>
  <li><p>If possible what is the preferred solution and basic steps I should follow to solve my problem?</p>
  </li>
  </ul>