diff options
Diffstat (limited to 'server/src/constants.rs')
-rw-r--r-- | server/src/constants.rs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/server/src/constants.rs b/server/src/constants.rs new file mode 100644 index 0000000..0f603da --- /dev/null +++ b/server/src/constants.rs @@ -0,0 +1,6 @@ +pub const DB_FILE_NAME: &str = "notes.db"; +pub const DB_SCHEMA_VERSION: i64 = 1; + +pub const LOGIN_TOKEN_EXPIRE_SECS: i64 = 40 * 24 * 3600; +/// Upon a request less than this before the expiration time, the token is refreshed. +pub const LOGIN_TOKEN_REFRESH_MARGIN: i64 = 20 * 24 * 3600; |