Commit graph

20 commits

Author SHA1 Message Date
Johann150 7458550f7a
server: fix some TS warnings 2024-04-01 18:26:15 +02:00
Johann150 f285281b5a
fixup! server: properly expire public key cache 2024-03-26 21:06:21 +01:00
Johann150 6501c542b2
server: only cache public keys for 15min
Some checks failed
ci/woodpecker/push/lint-backend Pipeline failed
ci/woodpecker/push/build Pipeline was successful
ci/woodpecker/push/lint-client Pipeline failed
ci/woodpecker/push/lint-foundkey-js Pipeline was successful
ci/woodpecker/push/lint-sw Pipeline failed
ci/woodpecker/push/test Pipeline failed
2024-03-19 19:16:07 +01:00
Johann150 fc733a4a86
server: properly expire public key cache
Changelog: Fixed
2024-03-19 18:40:34 +01:00
Johann150 101ea21747
server: don't cache users for infinity
Some checks failed
ci/woodpecker/push/lint-foundkey-js Pipeline was successful
ci/woodpecker/push/lint-backend Pipeline failed
ci/woodpecker/push/lint-sw Pipeline failed
ci/woodpecker/push/lint-client Pipeline failed
ci/woodpecker/push/build Pipeline was successful
ci/woodpecker/push/test Pipeline failed
If the cache runs for an infinite amount of time, the users may as well
be stored in memory directly.

Changelog: Fixed
2023-11-04 11:54:13 +01:00
Johann150 e75123602f
fix reference error from isNull 2023-05-23 22:44:15 +02:00
Johann150 4307010a9f
fix new occurences of isDeleted
Some checks failed
ci/woodpecker/push/lint-foundkey-js Pipeline was successful
ci/woodpecker/push/lint-client Pipeline failed
ci/woodpecker/push/lint-backend Pipeline failed
ci/woodpecker/push/build Pipeline was successful
ci/woodpecker/push/lint-sw Pipeline failed
ci/woodpecker/push/test Pipeline failed
2023-05-23 21:49:34 +02:00
Johann150 1516ddfc9b
refactor: remove CacheableUser & co
Some checks failed
ci/woodpecker/push/lint-foundkey-js Pipeline was successful
ci/woodpecker/push/lint-client Pipeline failed
ci/woodpecker/push/lint-backend Pipeline failed
ci/woodpecker/push/build Pipeline was successful
ci/woodpecker/push/lint-sw Pipeline failed
ci/woodpecker/push/test Pipeline failed
The CacheableUser, CacheableLocalUser and CacheableRemoteUser are
identical types to User, ILocalUser and IRemoteUser so it seems
nonsensical to have different types for them.
2023-05-18 13:25:57 +02:00
Johann150 b14f3e8cdc
server: properly handle logical deletion
All checks were successful
ci/woodpecker/push/lint-client Pipeline was successful
ci/woodpecker/push/lint-foundkey-js Pipeline was successful
ci/woodpecker/push/build Pipeline was successful
ci/woodpecker/push/lint-backend Pipeline was successful
ci/woodpecker/push/lint-sw Pipeline was successful
ci/woodpecker/push/test Pipeline was successful
closes #329
2023-04-15 19:04:07 +02:00
Johann150 71dfd229b0
remove unnecessary code 2023-04-15 18:56:46 +02:00
Norm 3cf673960b server: Fix typing for user token
Some checks failed
ci/woodpecker/push/lint-foundkey-js Pipeline was successful
ci/woodpecker/push/lint-backend Pipeline was successful
ci/woodpecker/push/lint-client Pipeline was successful
ci/woodpecker/push/build Pipeline was successful
ci/woodpecker/push/test Pipeline was successful
ci/woodpecker/pr/lint-foundkey-js Pipeline was successful
ci/woodpecker/pr/lint-backend Pipeline failed
ci/woodpecker/pr/lint-client Pipeline failed
ci/woodpecker/pr/test Pipeline failed
ci/woodpecker/pr/build Pipeline was successful
Also fix a comment in the User model that wrongly states that the token
is null if the user is local, when it's the opposite.
2022-12-08 23:20:41 -05:00
Norm cbfd866122 server: make fetcher key non-null 2022-12-08 23:19:39 -05:00
Norm 3dec9a47f0 server: fix various type errors in services 2022-12-08 23:18:45 -05:00
Norm b66f7550ab
server: auto-fix lints
All checks were successful
ci/woodpecker/push/build Pipeline was successful
ci/woodpecker/push/lint-client Pipeline was successful
ci/woodpecker/push/lint-backend Pipeline was successful
ci/woodpecker/push/lint-foundkey-js Pipeline was successful
ci/woodpecker/push/test Pipeline was successful
2022-12-07 13:39:21 -05:00
Johann150 d1ec058d5c
server: refactor Cache to hold fetcher as attribute
All checks were successful
ci/woodpecker/push/build Pipeline was successful
ci/woodpecker/push/lint-foundkey-js Pipeline was successful
ci/woodpecker/push/lint-client Pipeline was successful
ci/woodpecker/push/lint-backend Pipeline was successful
ci/woodpecker/push/test Pipeline was successful
Instead of having to pass the fetcher every time you want to fetch
something, the fetcher is stored in an attribute of the Cache.
2022-11-13 19:39:30 +01:00
Johann150 8d6476af2a
server: remove localUserByIdCache
The same data is stored in userByIdCache. Whether a user is local or not
can easily be determined from the cached object.
2022-11-13 18:03:22 +01:00
Johann150 e2bf2715a6
fix spelling error
Some checks failed
ci/woodpecker/push/lint-backend Pipeline was successful
ci/woodpecker/push/build Pipeline was successful
ci/woodpecker/push/lint-client Pipeline failed
ci/woodpecker/push/test Pipeline failed
2022-08-04 10:20:48 +02:00
Johann150 ba0236700d
chore: remove unused imports 2022-07-12 14:41:10 +02:00
syuilo 1c67c26bd8
refactor: migrate to typeorm 3.0 (#8443)
* wip

* wip

* wip

* Update following.ts

* wip

* wip

* wip

* Update resolve-user.ts

* maxQueryExecutionTime

* wip

* wip
2022-03-26 15:34:00 +09:00
syuilo ac8c66f5ab perf(server): refactor and performance improvements 2022-03-25 16:27:41 +09:00