Skip to content

Refresh auth token while app is uploading/download and log users out due to inactivity #17

@zfrantzen

Description

@zfrantzen

Refresh token while uploading/downloading

  • Create a new config value for the token refresh period
  • When upload/download are being performed, just short of every period (like 1 min less) make refresh token request to backend
  • Use this package for background timer (https://www.npmjs.com/package/react-native-background-timer). Can likely put the timer in the shared general upload/download component
  • If request fails, display alert and send user back to login screen ("Could not connect to server. Try again later.")

Inactivity

  • Use the same timer package. If the user exceeds the token refresh period without changing views, show an alert and send them to the login screen ("Logged out due to inactivity")
  • Inactivity should not apply while uploading or downloading. Cancel the timer when that is happening.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions