1
0
mirror of https://github.com/immich-app/immich.git synced 2024-11-24 08:52:28 +02:00
Commit Graph

2031 Commits

Author SHA1 Message Date
Mert
8812c3afcf
fix(server): apply qsv and vaapi quality to video stream only (#9807)
apply quality to video stream only
2024-05-28 09:49:51 +01:00
Mert
fbc3790cb6
fix(server): video thumbnail generation failing when using qsv (#9808)
fix multiplier
2024-05-28 09:47:41 +01:00
Jason Rasmussen
0fc6d69824
feat(server): user preferences (#9736)
* refactor(server): user endpoints

* feat(server): user preferences

* mobile: user preference

* wording

---------

Co-authored-by: Alex <alex.tran1502@gmail.com>
2024-05-28 09:16:53 +07:00
Alex
1f9158c545
feat(server): album's email notification (#9439)
* feat(server): album's email notification

* same size button

* skeleton for album invite and album update event

* album invite content

* album update

* fix(server): smtp certificate validation (#9506)

* album update content

* send mail

* album invite with thumbnail

* pr feedback

* styling

* Send email to update album event

* better naming

* add tests

* Update album-invite.email.tsx

Co-authored-by: bo0tzz <git@bo0tzz.me>

* Update album-update.email.tsx

Co-authored-by: bo0tzz <git@bo0tzz.me>

* fix: unit tests

* typo

* Update server/src/services/notification.service.ts

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>

* PR feedback

* Update server/src/emails/album-update.email.tsx

Co-authored-by: Zack Pollard <zackpollard@ymail.com>

---------

Co-authored-by: Michel Heusschen <59014050+michelheusschen@users.noreply.github.com>
Co-authored-by: bo0tzz <git@bo0tzz.me>
Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
Co-authored-by: Zack Pollard <zackpollard@ymail.com>
2024-05-28 02:16:46 +00:00
Mert
dca420ef70
chore: refactor transcode config routing (#9800)
* chore: refactor transcode config

* rename parameter

* handle no /dev/dri

* prefer undefined
2024-05-27 15:20:07 -04:00
Mert
21bd20fd75
fix(server): nvenc not working when there are no filters (#9802)
don't add format=nv12
2024-05-27 15:18:01 -04:00
Mert
351dd647a9
feat(server): better video thumbnails (#9784) 2024-05-27 12:08:38 -04:00
Alex
6879bcb7a4
chore(server): duplication default settings (#9781) 2024-05-26 20:51:41 -04:00
Jason Rasmussen
75830a4878
refactor(server): user endpoints (#9730)
* refactor(server): user endpoints

* fix repos

* fix unit tests

---------

Co-authored-by: Daniel Dietzler <mail@ddietzler.dev>
Co-authored-by: Alex <alex.tran1502@gmail.com>
2024-05-27 05:15:52 +07:00
Mert
e7c8501930
fix(server): search duplicates of the same asset type (#9747)
* search by type

* make sql

---------

Co-authored-by: Alex <alex.tran1502@gmail.com>
2024-05-26 22:04:23 +00:00
safehome-jdev
4d4bb8b6a7
fix(server): Properly build ML predict URL (#9751)
New URL via URL constructor and not string concatenation
2024-05-26 08:21:10 -04:00
Michel Heusschen
8a7b0f66a4
fix(server): partner can view archived assets (#9750)
* fix(server): partner can view archived assets

* update sql queries
2024-05-25 06:53:57 -04:00
Jason Rasmussen
9e71256191
chore(server): remove unused code (#9746) 2024-05-25 12:15:07 +02:00
Min Idzelis
d5cf8e4bfe
refactor(server): move checkExistingAssets(), checkBulkUpdate() remove getAllAssets() (#9715)
* Refactor controller methods, non-breaking change

* Remove getAllAssets

* used imports

* sync:sql

* missing mock

* Removing remaining references

* chore: remove unused code

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-05-24 21:02:22 -04:00
Jason Rasmussen
95012dc19b
fix: config error logging (#9738) 2024-05-24 16:44:50 -04:00
Lukas
f197f5d530
fix(server): use correct file extension for motion photo videos (#8659)
* fix(server): use mp4 file extension for motion photo videos in archive download

* always use mp4 for videos

* get file extension from originalPath

* remove console log

* store motion assets with mp4 extension

* add migration

* set originalFileName for live photo asset stubs

* leave down migration empty

* only set originalFileName for livePhotoStillAsset

* use separate stub

* shorter stub name
2024-05-24 16:38:18 -04:00
Jason Rasmussen
7168707395
refactor(server): remove unused code (#9737) 2024-05-24 16:37:29 -04:00
Zack Pollard
39d2c4f37b
chore: remove all deprecated endpoints/properties from server and mobile app (#9724)
* chore: remove deprecated title property from MemoryLaneResponseDto

* chore: remove deprecated webpPath and resizePath from MetadataSearchDto

* chore: remove deprecated sharedUserIds property from Album AddUsersDto

* chore: remove deprecated sharedUsers property from AlbumResponseDto

* chore: remove deprecated sharedWithUserIds property from CreateAlbumDto

* chore: remove deprecated isExternal and isReadOnly properties from AssetResponseDto

* chore: remove deprecated /server-info endpoint

* chore: bloody linters
2024-05-24 15:37:01 +01:00
Mert
69b5eb005f
fix(server): use qsv format for hwmap (#9722)
use qsv format for hwmap
2024-05-24 09:50:28 +01:00
Min Idzelis
4f21f6a2e1
feat: API operation replaceAsset, POST /api/asset/:id/file (#9684)
* impl and unit tests for replaceAsset

* Remove it.only

* Typo in generated spec +regen

* Remove unused dtos

* Dto removal fallout/bugfix

* fix - missed a line

* sql:generate

* Review comments

* Unused imports

* chore: clean up

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-05-23 20:26:22 -04:00
Alex
57d94bce68
feat(web): deduplication UI (#9540) 2024-05-23 12:57:25 -05:00
Jason Rasmussen
e7aa50425c
test: sync open api spec (#9687)
test: sync spec file
2024-05-23 07:40:57 -04:00
Mert
a5e8b451b2
feat(server): qsv hardware decoding and tone-mapping (#9689)
* qsv hw decoding and tone-mapping

* fix vaapi

* add tests

* formatting

* handle device name without path
2024-05-23 03:58:29 +00:00
Jason Rasmussen
13cbdf6851
refactor(server): cli service (#9672) 2024-05-22 22:23:47 +02:00
Jason Rasmussen
967d195a05
chore(server): remove unused code (#9670) 2024-05-22 15:53:57 -04:00
Jason Rasmussen
8f37784eae
refactor(server): /user profile endpoint (#9669)
* refactor(server): user profile endpoint

* chore: open api
2024-05-22 14:31:12 -04:00
Jason Rasmussen
ecd018a826
refactor(server): user info endpoint (#9668)
* refactor(server): user info endpoint

* chore: open api
2024-05-22 14:15:33 -04:00
Jason Rasmussen
202745f14b
refactor(server): plural endpoints (#9667) 2024-05-22 13:24:57 -04:00
CodaBool
6a4c2e97c0
feat: add docker healthchecks to server and ml (#9583)
* add healthcheck

* format, import, IMMICH_PORT, and eslint change

* chore: clean up nodejs healthcheck

* fix ruff formating

* add healthcheck

* format, import, IMMICH_PORT, and eslint change

* chore: clean up nodejs healthcheck

* fix ruff formating

* add healthcheck to dockerfile

* poetry run ruff check --fix

* removed 2 of 3 console calls

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-05-22 16:54:29 +00:00
Jason Rasmussen
06ce8247cc
feat(server): user metadata (#9650)
* feat(server): user metadata

* add missing method to user mock

* update migration to include cascades

* update sql files

* test: fix e2e

* chore: clean up

---------

Co-authored-by: Daniel Dietzler <mail@ddietzler.dev>
2024-05-22 08:13:36 -04:00
Zack Pollard
a3e7e8cc31
refactor: deprecate /server-info and replace with /server-info/storage (#9645) 2024-05-22 10:25:55 +01:00
Jason Rasmussen
a3489d604b
chore: remove unused stubs (#9647) 2024-05-21 18:35:26 +02:00
renovate[bot]
00b5ad3421
chore(deps): update dependency @types/lodash to v4.17.3 (#9644)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-05-21 16:18:35 +00:00
Jason Rasmussen
91b835cfeb
fix: auth sub override (#9635) 2024-05-21 09:07:34 -04:00
renovate[bot]
bb79df655d
fix(deps): update dependency sharp to v0.33.4 (#9633)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-05-21 13:54:56 +01:00
renovate[bot]
0963a32a95
chore(deps): update base-image to v20240521 (major) (#9632)
chore(deps): update base-image to v20240521

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-05-21 11:53:47 +00:00
Alex
4f838eabbe
fix(server): semver in development (#9620) 2024-05-20 23:03:28 -04:00
renovate[bot]
143b9d6828
fix(deps): update typescript-projects (#9617)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-05-21 00:32:18 +00:00
Jason Rasmussen
1df7be8436
refactor(server): version logic (#9615)
* refactor(server): version

* test: better version and log checks
2024-05-20 20:31:36 -04:00
Jason Rasmussen
84d824d6a7
refactor: library type (#9525) 2024-05-20 18:09:10 -04:00
Alex
60427f18ce
chore(server): return duplicate assets as group (#9576)
* chore(server): return duplicate assets as group

* file name
2024-05-18 13:15:56 -05:00
Nicholas Flamy
975f2351ec
fix(server): Disable duplicate detection when smart search disabled (#9565) 2024-05-17 16:37:26 -04:00
Jason Rasmussen
2e62c7b417
refactor: node_env => immich_env (#9561) 2024-05-17 13:30:05 -04:00
Alex
2689178a35
chore(server): openapi generation for Duplicate controller (#9560) 2024-05-17 12:05:23 -05:00
Jason Rasmussen
d61418886f
refactor!: port env (#9559)
refactor: port env
2024-05-17 12:59:05 -04:00
Jason Rasmussen
c03981ac1d
refactor(server): new version check (#9555) 2024-05-17 12:22:39 -04:00
Jason Rasmussen
4807fc40a6
refactor!: LOG_LEVEL => IMMICH_LOG_LEVEL (#9557)
refactor: LOG_LEVEL => IMMICH_LOG_LEVEL
2024-05-17 11:44:22 -04:00
Zack Pollard
c8aa6a62c2
fix: when using old script args, just set the workers include var (#9552)
* fix: when using old script args, just set the workers include var and move on

* fix: set process.title when using new bootstrap worker startup method
2024-05-17 15:10:57 +01:00
Zack Pollard
85aca2bb54
feat: microservices be gone (#9551)
* feat: microservices be gone and api is a worker now too

* chore: remove very old startup scripts, surely nobody is using these anymore, right?

right?....
2024-05-17 14:44:30 +01:00
Mert
ff52300624
refactor(server): duplicate controller and service (#9542)
* duplicate controller and service

* change endpoint name

* fix search tests

* remove unused import

* add to index
2024-05-16 19:39:33 -04:00
Jason Rasmussen
936a46b4ed
fix(server): use jasonnnnnnnnnb (#9539) 2024-05-16 17:24:54 -04:00
Mert
d8eca168ca
feat(server): fully accelerated nvenc (#9452)
* use arrayContaining

* libplacebo for nvenc

update dockerfile

* tweaks

* update nvenc options

* tweak settings

* refactor

* toggle for hardware decoding, software / hardware decoding for nvenc and rkmpp

* fix software tone-mapping not being applied

* separate configs for hw/sw

* update api

* add hw decode toggle

* fix mutating config

* remove `version` flag

* fix config type

* remove submodule

* handle temporal AQ

* remove duplicate tests

* use `tonemap_opencl`

* wording

* update docs
2024-05-16 13:30:26 -04:00
Mert
64636c0618
feat(server): near-duplicate detection (#8228)
* duplicate detection job, entity, config

* queueing

* job panel, update api

* use embedding in db instead of fetching

* disable concurrency

* only queue visible assets

* handle multiple duplicateIds

* update concurrent queue check

* add provider

* add web placeholder, server endpoint, migration, various fixes

* update sql

* select embedding by default

* rename variable

* simplify

* remove separate entity, handle re-running with different threshold, set default back to 0.02

* fix tests

* add tests

* add index to entity

* formatting

* update asset mock

* fix `upsertJobStatus` signature

* update sql

* formatting

* default to 0.03

* optimize clustering

* use asset's `duplicateId` if present

* update sql

* update tests

* expose admin setting

* refactor

* formatting

* skip if ml is disabled

* debug trash e2e

* remove from web

* remove from sidebar

* test if ml is disabled

* update sql

* separate duplicate detection from clip in config, disable by default for now

* fix doc

* lower minimum `maxDistance`

* update api

* Add and Use Duplicate Detection Feature Flag (#9364)

* Add Duplicate Detection Flag

* Use Duplicate Detection Flag

* Attempt Fixes for Failing Checks

* lower minimum `maxDistance`

* fix tests

---------

Co-authored-by: mertalev <101130780+mertalev@users.noreply.github.com>

* chore: fixes and additions after rebase

* chore: update api (remove new Role enum)

* fix: left join smart search so getAll works without machine learning

* test: trash e2e go back to checking length of assets is zero

* chore: regen api after rebase

* test: fix tests after rebase

* redundant join

---------

Co-authored-by: Nicholas Flamy <30300649+NicholasFlamy@users.noreply.github.com>
Co-authored-by: Zack Pollard <zackpollard@ymail.com>
Co-authored-by: Zack Pollard <zack@futo.org>
2024-05-16 18:08:37 +01:00
Jason Rasmussen
984aa8fb41
refactor(server): system config (#9517) 2024-05-15 18:58:23 -04:00
renovate[bot]
7f0f016f2e
chore(deps): update dependency eslint-plugin-unicorn to v53 (#9502)
* chore(deps): update dependency eslint-plugin-unicorn to v53

* use structured clone to match new eslint rules

* use raw string instead of escaping slash

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Daniel Dietzler <mail@ddietzler.dev>
2024-05-15 18:06:25 -04:00
Jason Rasmussen
73bf8f343a
chore(server): remove unused property (#9521) 2024-05-15 15:17:48 -04:00
Michel Heusschen
581b467b4b
fix(server): smtp certificate validation (#9506) 2024-05-15 07:21:35 -04:00
Alex The Bot
88d4338348 Version v1.105.1 2024-05-14 21:31:24 +00:00
Jason Rasmussen
ce7bbe88f9
fix(server): skip originals when deleting a library (#9496) 2024-05-14 16:29:57 -05:00
Jason Rasmussen
0f129cae4a
refactor(server): feature flags (#9492) 2024-05-14 15:31:36 -04:00
Jason Rasmussen
7b1112f3e3
refactor(server): system config (#9484) 2024-05-14 14:43:49 -04:00
Alex The Bot
596ab39293 Version v1.105.0 2024-05-14 17:07:25 +00:00
Alex
f28b4e7c99
fix(server): sync issue when delete remotes assets (#9479) 2024-05-14 11:51:15 -05:00
Fynn Petersen-Frey
4d7aa7effd
fix(server): new full sync return stacked assets individually (#9189)
* fix(server): new full sync return stacked assets individually

* return archived partner assets (like old getAllAssets)

* fix

* fix test

---------

Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
2024-05-14 10:30:33 -05:00
Zack Pollard
1ea55d642e
feat(server): run microservices in worker thread (#9426)
feat: start microservices in worker thread and add internal microservices for the server
2024-05-14 15:28:20 +01:00
renovate[bot]
3d5e55bdaa
chore(deps): update base-image to v20240514 (major) (#9469)
chore(deps): update base-image to v20240514

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-05-14 08:55:09 -04:00
Jason Rasmussen
46868b3336
refactor(server): logger (#9472) 2024-05-14 08:48:49 -04:00
renovate[bot]
3d4ae9c210
chore(deps): update node.js to 53108f6 (#9450)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-05-14 10:53:04 +01:00
Eric Barch
6fd6a8ba15
fix(server): addAssets and removeAssets handle duplicate assetIds (#9436)
* fix(server): addAssets and removeAssets handle duplicate assetIds

* chore(server): Add e2e tests for duplicate album additions and removals
2024-05-14 03:29:32 +00:00
renovate[bot]
bf036f2f58
fix(deps): update typescript-projects (#9454)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-05-13 21:42:48 -04:00
Sushain Cherivirala
4e6aeeda4d
fix(server): support special characters in library paths (#9385)
Support special characters in library paths
2024-05-13 21:44:21 +00:00
Jason Rasmussen
844f5a16a1
chore(server): remove unused column (#9431)
* chore(server): remove unused column

* fix: broken migrations
2024-05-13 16:40:16 -04:00
Jason Rasmussen
1bebc7368c
fix(server): regenerate (extract) motion videos (#9438) 2024-05-13 16:38:11 -04:00
Alex The Bot
a6f557c24c Version v1.104.0 2024-05-13 18:31:57 +00:00
Jason Rasmussen
9c5a2b97bf
fix(server): put system config (#9425) 2024-05-13 16:29:39 +00:00
Alex
06402aa9fb
chore(server): email notification button png (#9423)
* chore(server): email notification button png

* valid user name

---------

Co-authored-by: Daniel Dietzler <mail@ddietzler.dev>
2024-05-13 15:36:35 +00:00
Andreas Gerstmayr
48927f5fb9
feat(server, web): include pictures of shared albums on map (#7439)
* feat(server, web): include pictures of shared albums on map

* run prettier

* re-create api clients

* implement suggestions from code review

* shared from partner -> shared from partners

* rename to 'include shared partner assets'

* chore: fix tsc error in server and prettier in web

* fix: include assets shared via owner albums

---------

Co-authored-by: Zack Pollard <zackpollard@ymail.com>
Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-05-13 09:28:57 -04:00
renovate[bot]
d121903b38
fix(deps): update dependency nestjs-otel to v6 (#9415)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-05-13 08:23:12 -04:00
Mert
f667c9597b
chore(server): less rigid transcoding tests (#9401)
* use arrayContaining

* clean up
2024-05-12 00:04:31 -04:00
Mert
bb4843747b
perf: cache transcoding devices (#9381)
cache transcoding devices
2024-05-10 15:03:47 -04:00
Mert
f3fbb9b588
perf: cache getConfig (#9377)
* cache `getConfig`

* critical fix

Co-authored-by: Daniel Dietzler <36593685+danieldietzler@users.noreply.github.com>

---------

Co-authored-by: Daniel Dietzler <36593685+danieldietzler@users.noreply.github.com>
2024-05-10 18:15:25 +00:00
Jason Rasmussen
8743e17528
refactor(server): auth route metadata (#9344) 2024-05-09 13:58:44 -04:00
Jason Rasmussen
8e9895df27
chore(server): remove unused deps (#9334) 2024-05-08 16:39:35 -04:00
Mert
1167f0f2b7
feat(server): optimize person thumbnail generation (#7513)
* do crop and resize together

* redundant `pipelineColorspace` call

* formatting

* fix rebase

* handle orientation

* remove unused import

* formatting

* use oriented dimensions for half size calculation

* default case for orientation

* simplify orientation code

---------

Co-authored-by: Alex <alex.tran1502@gmail.com>
2024-05-08 08:09:34 -05:00
Jason Rasmussen
4e7966c8e8
chore: move test assets submodule (#9321) 2024-05-07 22:33:17 -05:00
Jan
535c7a8618
Random Endpoint use querybuilder and return exifInfo (#9301)
* Random Endpoint use querybuilder and return exifInfo

* Add GenerateSql

* Commit missing sql changes
2024-05-07 23:14:04 -04:00
renovate[bot]
8c54c13307
chore(deps): update node.js to fe31b16 (#9318)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-05-07 23:01:04 -04:00
Jason Rasmussen
e79d1b1ec2
refactor: create album users (#9315) 2024-05-07 16:38:09 -04:00
Alex
ee6995783f
fix(mobile): add user to album using new dto property (#9312)
* fix(mobile): add user to album using new DTO property

* fix(mobile): add user to album using new DTO property
2024-05-07 20:00:38 +00:00
renovate[bot]
78b5990d2a
chore(deps): update dependency @types/nodemailer to v6.4.15 (#9309)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-05-07 15:15:24 -04:00
renovate[bot]
f13100e261
fix(deps): update dependency exiftool-vendored to v26 (#9294)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-05-07 15:14:49 -04:00
renovate[bot]
21fe829a2c
chore(deps): update base-image to v20240507 (major) (#9303)
chore(deps): update base-image to v20240507

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-05-07 11:10:21 -04:00
renovate[bot]
ad404d79d4
fix(deps): update typescript-projects (#9293)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-05-07 11:07:50 -04:00
Alex
bbb9453e1a
fix(server): show partners archived photos on mobile timeline (#9194)
fix(mobile): show partners archived photos on timeline
2024-05-06 22:49:56 -05:00
martin
cf79bc9ed7
fix(server, web): reassigning faces (#9265)
* fix: reassiging faces

* fix: rename
2024-05-05 13:16:44 -05:00
Jason Rasmussen
5b87abb021
feat(server): read-write external assets (#9235)
* refactor: remove isReadOnly and isExternal usages

* chore: open api

* fix: linting

* remove mobile isReadOnly dependency

---------

Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
2024-05-03 15:34:57 -04:00
Jason Rasmussen
ec4eb7cd19
feat(server): immich checksum header (#9229)
* feat: dedupe by checksum header

* chore: open api
2024-05-02 15:42:26 -04:00
Nicolò
9bce3417e9
feat(server): email notifications (#8447)
* feat(server): add `react-mail` as mail template engine and `nodemailer`

* feat(server): add `smtp` related configs to `SystemConfig`

* feat(web): add page for SMTP settings

* feat(server): add `react-email.adapter`

This adapter render the React-Email into HTML and plain/text email.
The output is set as the body of the email.

* feat(server): add `MailRepository` and `MailService`

Allow to use the NestJS-modules-mailer module to send SMTP emails.
This is the base transport for the `NotificationRepository`

* feat(server): register the job dispatcher and Job for async email

This allows to queue email sending jobs for the `EmailService`.

* feat(server): add `NotificationRepository` and `NotificationService`

This act as a middleware to properly route the notification to the right transport.
As POC I've only implemented a simple SMTP transport.

* feat(server): add `welcome` email template

* feat(server): add the first notification on `createUser` in `UserService`

This trigger an event for the `NotificationRepository` that once processes
by using the global config and per-user config will carry the payload to the right notification transport.

* chore: clean up

* chore: clean up web

* fix: type errors"

* fix package lock

* fix mail sending, option to ignore certs

* chore: open api

* chore: clean up

* remove unused import

* feat: email feature flag

* chore: remove unused interface

* small styling

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
Co-authored-by: Daniel Dietzler <mail@ddietzler.dev>
Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
2024-05-02 15:43:18 +01:00
Mert
a0c43a2b5a fix(server): person thumbnails not being queued during thumbnail generation (#9195)
use face id instead of asset id
2024-05-02 01:33:17 +01:00
renovate[bot]
ef09fc4157 fix(deps): update typescript-projects (#9187)
* fix(deps): update typescript-projects

* chore: missing dependency

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-05-02 01:33:17 +01:00
Zack Pollard
0a598ae1b8
chore: fvm and node dependency updates and pinning (#9203)
* chore(mobile): ignore .fvm directory and update .fvmrc version

* chore(cli): add nvm and volta node versioning files/config

* chore(docs): add nvm and volta node versioning files/config, bump to node v20

* chore(server): add nvm node versioning file

* chore(web): add nvm and volta node versioning files/config

* chore(e2e): add nvm and volta node versioning files/config
2024-05-01 14:05:18 +01:00
renovate[bot]
eba42b245d
chore(deps): update base-image to v20240430 (major) (#9179)
chore(deps): update base-image to v20240430

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-30 22:04:28 -04:00
renovate[bot]
9e79a23bbe
fix(deps): update typescript-projects (#9169)
* fix(deps): update typescript-projects

* fix: type error

* fix: more imports

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-04-30 09:49:14 -04:00
renovate[bot]
4f097d9106
chore(deps): update node.js to 142644a (#9165)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-29 22:15:22 -04:00
Alex The Bot
ba18776fc2 Version v1.103.1 2024-04-29 17:53:49 +00:00
Alex The Bot
4291b38769 Version v1.103.0 2024-04-29 14:42:49 +00:00
Jason Rasmussen
59caf1fce4
chore: lifecycle metadata (#9103)
feat(server): track endpoint lifecycle
2024-04-29 13:48:28 +00:00
Fynn Petersen-Frey
32e7cfea3d
fix(server): stacked assets for full sync, userIds as array for delta sync (#9100)
* fix(server): stacked assets for full sync, userIds as array for delta sync

* refactor(server): sync

* fix getDeltaSync after partner removal

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-04-28 23:24:21 -04:00
Hermes Espínola González
4bb7d2df49
fix(server): Improve reverse geocoded location metadata (#9051)
* fix: improve reverse geocoding

* fix: update tests referencing states

* fix: expect state suggestion in any order

---------

Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
2024-04-28 21:29:08 +01:00
Mert
2648032163
fix(server): untracked thumbnail and preview images (#9126)
* delete old thumbnails

* add tests

* revert invisible asset handling
2024-04-27 18:43:05 -04:00
Jason Rasmussen
034c928d9e
feat(server): remove inactive sessions (#9121)
* feat(server): remove inactive sessions

* add rudimentary unit test

---------

Co-authored-by: Daniel Dietzler <mail@ddietzler.dev>
2024-04-27 16:45:16 -04:00
Nguyễn Hoàng Đức
833a78181b
fix(server): asset count on meta tag of shared links (#9107)
* fix asset count on meta tag of shared links

* fix lint

* fix style

* add e2e tests
2024-04-27 14:56:13 -04:00
Daniel Dietzler
90882a9b26
refactor(server): repositories (#9119)
refactor repos
2024-04-27 13:52:05 -04:00
Jason Rasmussen
7ea539b753
chore(server): default postgres hostname to compose service name (#9118) 2024-04-27 13:43:45 -04:00
Jason Rasmussen
0d8a04b43c
chore: for redis, use service name as the default (#9109)
chore: use service name as default redis hostname
2024-04-27 11:04:23 -04:00
Jason Rasmussen
5a49de5592
chore(server): remove old asset search (#9104)
* chore(server): remove old asset search

* chore: remove more unused search code
2024-04-27 12:57:39 +00:00
Jason Rasmussen
69f8bfe874
fix(server): default host binding (#9090) 2024-04-26 01:02:19 -05:00
Alex
1d15cfb5f3
chore(server): remove unusuned endpoint/service/interface in asset-v1 (#9086) 2024-04-26 01:02:04 -05:00
martin
c9dcb5c624
fix(server): activity with deleted assets / users (#9068)
fix: activity with deleted assets / users
2024-04-25 17:45:15 -04:00
mgabor
2943f93098
feat: readonly album sharing (#8720)
* rename albums_shared_users_users to album_permissions and add readonly column

* disable synchronize on the original join table

* remove unnecessary FK names

* set readonly=true as default for new album shares

* separate and implement album READ and WRITE permission

* expose albumPermissions on the API, deprecate sharedUsers

* generate openapi

* create readonly view on frontend

* ??? move slideshow button out from ellipsis menu so that non-owners can have access too

* correct sharedUsers joins

* add album permission repository

* remove a log

* fix assetCount getting reset when adding users

* fix lint

* add set permission endpoint and UI

* sort users

* remove log

* Revert "??? move slideshow button out from ellipsis menu so that non-owners can have access too"

This reverts commit 1343bfa311.

* rename stuff

* fix db schema annotations

* sql generate

* change readonly default to follow migration

* fix deprecation notice

* change readonly boolean to role enum

* fix joincolumn as primary key

* rename albumUserRepository in album service

* clean up userId and albumId

* add write access to shared link

* fix existing tests

* switch to vitest

* format and fix tests on web

* add new test

* fix one e2e test

* rename new API field to albumUsers

* capitalize serverside enum

* remove unused ReadWrite type

* missed rename from previous commit

* rename to albumUsers in album entity as well

* remove outdated Equals calls

* unnecessary relation

* rename to updateUser in album service

* minor renamery

* move sorting to backend

* rename and separate ALBUM_WRITE as ADD_ASSET and REMOVE_ASSET

* fix tests

* fix "should migrate single moving picture" test failing on European system timezone

* generated changes after merge

* lint fix

* fix correct page to open after removing user from album

* fix e2e tests and some bugs

* rename updateAlbumUser rest endpoint

* add new e2e tests for updateAlbumUser endpoint

* small optimizations

* refactor album e2e test, add new album shared with viewer

* add new test to check if viewer can see the album

* add new e2e tests for readonly share

* failing test: User delete doesn't cascade to UserAlbum entity

* fix: handle deleted users

* use lodash for sort

* add role to addUsersToAlbum endpoint

* add UI for adding editors

* lint fixes

* change role back to editor as DB default

* fix server tests

* redesign user selection modal editor selector

* style tweaks

* fix type error

* Revert "style tweaks"

This reverts commit ab604f4c8f.

* Revert "redesign user selection modal editor selector"

This reverts commit e6f344856c.

* chore: cleanup and improve add user modal

* chore: open api

* small styling

---------

Co-authored-by: mgabor <>
Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
2024-04-25 04:19:49 +00:00
Mert
466451abc9
feat(server): env variable to skip migrations on startup (#9069)
* env variable to skip migrations

* update docs

* update env doc
2024-04-24 22:52:38 -04:00
renovate[bot]
f0f9053115
chore(deps): update base-image to v20240423 (major) (#9064)
chore(deps): update base-image to v20240423

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-24 17:31:29 -04:00
renovate[bot]
0466da03ae
fix(deps): update typescript-projects (#9028)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-23 16:50:18 -04:00
Adam Jackson
661540c886
refactor(server, web, mobile): Change wording of memory titles (#9025)
Change wording of memory titles
2024-04-23 15:08:02 +00:00
Daniel Dietzler
7f1651df71
chore(server): enable swagger to take class validator rules into account (#9022)
* enable swagger to take class validator rules into account

* chore: open api
2024-04-22 18:13:44 -04:00
Mert
c30cd3b378
chore: test more formats in e2e (#9001) 2024-04-22 01:35:27 -04:00
Jason Rasmussen
a93534fc3c
refactor(server): session interface types (#8977) 2024-04-20 23:45:55 -04:00
Alex The Bot
a2180a467d Version v1.102.3 2024-04-20 20:17:39 +00:00
Jason Rasmussen
1e3dceea4d
fix(server): session refresh (#8974) 2024-04-20 15:15:25 -05:00
Mert
fd4514711f
feat(server): enable AV1 encoding for NVENC (#8959)
allow av1 for nvenc
2024-04-20 14:52:50 -04:00
Alex The Bot
25549b87c9 Version v1.102.2 2024-04-20 15:55:32 +00:00
Jaryl Chng
caf76f0713
feat(server): enable AV1 encoding for QSV (#8942) 2024-04-20 10:36:00 -04:00
Alex The Bot
6eb1b82541 Version v1.102.1 2024-04-20 13:43:46 +00:00
Jason Rasmussen
171b6bb0a6
refactor: system metadata (#8923)
refactor(server): system metadata
2024-04-19 20:36:15 -04:00
Daniel Dietzler
78c7ff855d
refactor(server): move file file report endpoints to their own controller (#8925)
* move file report to its own controller

* chore: open api
2024-04-19 20:35:54 -04:00
Alex The Bot
886e07604e Version v1.102.0 2024-04-19 20:08:02 +00:00
Mert
431ffebddd
feat(server): use embedded preview from raw images (#8773)
* extract embedded

* update api

* add tests

* move temp file logic outside of media repo

* formatting

* revert `toSorted`

* disable by default

* clarify setting description

* wording

* wording

* update docs

* check extracted image dimensions

* test that it unlinks

* formatting

---------

Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
2024-04-19 10:50:13 -05:00
Jason Rasmussen
74c921148b
refactor(server): cookies (#8920) 2024-04-19 11:19:23 -04:00
Jason Rasmussen
4478e524f8
refactor(server): sessions (#8915)
* refactor: auth device => sessions

* chore: open api
2024-04-19 06:47:29 -04:00
Mert
596c35dc00
fix(server): skip invisible assets for thumbnail generation and ml (#8891)
* skip invisible assets for thumbnail generation and ml

* no need to update job status

* fix thumbhash check order

* linting
2024-04-19 01:37:55 +00:00
Mert
8573c84605
fix(server): include archived images in face detection (#8892) 2024-04-17 23:47:24 -04:00
Jason Rasmussen
3a9df6dae8
refactor(server): immich-admin list-users (#8862) 2024-04-17 12:27:04 +00:00
renovate[bot]
b21566c2fc
chore(deps): update node.js to d328c7b (#8829)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-17 07:52:29 -04:00
Kevin Huang
17dc12cf7d
fix(server): storage usage calculation for motion photos (#8722)
* ignore non external assets in external libraries during syncUsage

* only update storage usage if asset is from internal libraries

* update storage usage on motion photo video asset creation

* updated metadata service tests

* added a test

* simplified syncUsage condition

* check for library type upload instead of not external

* fixed broken sql

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-04-17 03:04:59 +00:00
renovate[bot]
6d4d0f86cf
chore(deps): update base-image to v20240416 (major) (#8660)
* chore(deps): update base-image to v20240416

* fix e2e

* rename variable

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: mertalev <101130780+mertalev@users.noreply.github.com>
2024-04-16 22:55:05 -04:00
Jason Rasmussen
14b1425e98
feat(server): logging interceptor (#8859) 2024-04-16 19:21:57 -04:00
renovate[bot]
18fa6018c0
fix(deps): update typescript-projects (#8834)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-16 17:45:14 -04:00
Jason Rasmussen
47fb9bd213
fix(server): correlationId (#8858) 2024-04-16 17:31:49 -04:00
AmAn Sharma
6e6deec40c
feat: use ILoggerRepository (#8855)
* Migrate ImmichLogger over to injected ILoggerRepository

* chore: cleanup and tests

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-04-16 17:30:31 -04:00
Jason Rasmussen
877207a2e6
chore(server): delete swap file (#8856) 2024-04-16 22:13:03 +02:00
Jason Rasmussen
50c9bc0336
chore: migrate to vitest (#7156)
* chore: jest => vitest

* chore: replace jest-when
2024-04-16 10:44:45 -04:00
Fynn Petersen-Frey
103cb60a57
feat(server): efficient full app sync (#8755)
* feat(server): efficient full app sync

* add SQL, fix test compile issues

* fix linter warning

* new sync controller+service, add tests

* enable new sync controller+service

* Update server/src/services/sync.service.ts

Co-authored-by: Daniel Dietzler <36593685+danieldietzler@users.noreply.github.com>

---------

Co-authored-by: Daniel Dietzler <36593685+danieldietzler@users.noreply.github.com>
2024-04-16 07:26:37 +02:00
Jason Rasmussen
dba365634a
chore(server): cleanup library watching (#8835)
chore: clean up library watching
2024-04-15 23:05:08 -04:00
Jason Rasmussen
2db76034b1
feat(server): correlation id via injected logger (#8823)
* feat(server): correlation id via injected logger

* feat: cid response header
2024-04-15 23:39:06 +00:00
renovate[bot]
3deaaf14c0
fix(deps): update dependency reflect-metadata to ^0.2.0 (#8784)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-15 16:02:49 -07:00
yparitcher
ed74213c63
feat(server): server host binding (#8800)
* Allow setting the host address for the server & microservices

Default to listen on all interfaces as per the current behavior.

* (Docs) format: fix lint
2024-04-15 14:24:13 -04:00
Kevin Huang
85df3f1e99
fix(server): external library motion photo video asset handling (#8721)
* added "isExternal" to the getLibraryAssetPaths query

* handleQueueAssetRefresh skip "non external" video asset, closes #8562

* correctly implements live photo deletion for external library

* use "external asset" for external library tests

* minor: external library asset checksum is "path hash" not file hash

* renamed to getExternalLibraryAssetPaths and added isExternal where clause

* generated sql

* reverted leftover change
2024-04-14 19:55:44 -04:00
Jason Rasmussen
14b798fcc4
refactor: library e2e (#8693)
* refactor: library e2e

* migrate and refactor library e2e

---------

Co-authored-by: Daniel Dietzler <mail@ddietzler.dev>
2024-04-12 21:15:41 +02:00
Kevin Huang
58346465aa
fix(server): link motion photo with existing video asset (#8724)
* added motion photo linking

* added tests
2024-04-11 09:49:21 -04:00
Kevin Huang
ec76e5ef23
fix(server): prevent cross-library motion photo linking, made getByChecksum library specific (#8719)
prevent cross linking
2024-04-11 09:41:30 -04:00
N00MKRAD
f1ca1794a1
Add AV1 transcoding support (#8491)
* Add AV1 transcoding support

- AV1 encoding on CPU via SVT-AV1 (libsvtav1 in ffmpeg)
- Supports CRF and optionally capped CRF (max bitrate)
- Tested playback successfully in Chrome Win+Android, Firefox Win+Linux, Android app

* AV1: Add support for encoding threads option

* Revert previous commit; specifying params multiple times is bad

We need to specify all svtav1-params at once, so putting the thread option into getThreadOptions is not possible.

* AV1: Override VAAPI getSupportedCodecs as it does not yet support AV1 unlike nvenc, qsv, amf

* Change BaseHWConfig supported codecs to only H264/HEVC

Configs that support VP9 and/or AV1 need to override getSupportedCodecs()

* Set SVT-AV1 threads with svtav1-params, remove duplicate block in NVENCConfig

* AV1Config: Fix empty svtav1-params array being added to options

* add tests

* update api

* allow crf-based two-pass mode

* formatting

* suggest 35

---------

Co-authored-by: mertalev <101130780+mertalev@users.noreply.github.com>
2024-04-11 05:26:27 +00:00
Daniel Dietzler
ad5d115abe
fix(server): require asset permission when creating an album with them (#8686)
require asset permission when creating an album with them
2024-04-10 13:41:22 -04:00
renovate[bot]
321868963d
fix(deps): update typescript-projects (#8651)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-09 21:08:37 +02:00
Alex
327b9bd59c
Revert "fix(deps): update typescript-projects (#8647)" (#8650)
This reverts commit 301c217303.
2024-04-09 06:53:48 +02:00
renovate[bot]
301c217303
fix(deps): update typescript-projects (#8647)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-08 23:44:48 -04:00
renovate[bot]
6631e6eedc
chore(deps): update node.js to 3fb85a6 (#8643)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-08 22:33:50 -04:00
Jason Rasmussen
369bd17c8b
chore(server): remove unused method (#8639) 2024-04-08 17:23:45 -04:00
Daniel Dietzler
7b1562c050
fix(server): remove isWatched from DTO (#8598)
* fix: remove isWatched

* chore: open api
2024-04-08 16:00:08 -04:00
Kevin Huang
7a16233584
fix(server): delete thumbnail for readonly asset (#8593)
* delete thumbnail and other generated files even for readonly asset

* updated test

* don't delete sidecar file for readonly file

* fixed test

* improved external detection
2024-04-08 12:54:10 -04:00
renovate[bot]
fff12e3d78
chore(deps): update dependency eslint-plugin-unicorn to v52 (#8629)
* chore(deps): update dependency eslint-plugin-unicorn to v52

* chore: linting

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-04-08 12:45:46 -04:00
Jelle Dekker
29e47dd7c1
fix: npm i on Windows … (#8619) 2024-04-08 10:53:27 -04:00
Mert
105a74caca
feat(server,web): configure image format (#8581) 2024-04-07 12:44:34 -04:00
Mert
55b9acca78
fix(server): hevc tag being set when copying a non-hevc stream (#8582) 2024-04-07 12:44:09 -04:00
Mert
0d130b8957
fix(server): x264/x265 params not being set correctly (#8587) 2024-04-07 12:43:50 -04:00
Mert
335c03d0b8
chore(server): better typing for system config key (#8580)
* config type safety

* typeorm fix

* typing fixes

* don't use enum in db

* add todo
2024-04-07 01:47:33 +00:00
Mert
4681ff88d0
fix(server): image config not being updated (#8579)
update system config key
2024-04-06 21:06:26 -04:00
Alex The Bot
3b0fff3b3d Version v1.101.0 2024-04-05 02:39:51 +00:00
renovate[bot]
15a2e6feeb
fix(deps): update typescript-projects (#8471)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-03 10:17:17 -04:00
Ben McCann
62d307321a
docs: add some details for getting started as a developer (#8468) 2024-04-02 11:56:33 -05:00
renovate[bot]
97c340b8a4
chore(deps): update node.js to fa5d3cf (#8450)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-02 14:26:55 +00:00
renovate[bot]
7b1d4a6787
fix(deps): update typescript-projects to v10.3.7 (#8461)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-02 14:26:47 +00:00
Jason Rasmussen
cd0e537e3e
feat: persistent memories (#8330)
* feat: persistent memories

* refactor: use new add/remove asset utility
2024-04-02 10:23:17 -04:00
renovate[bot]
0849dbd1af
fix(deps): update typescript-projects (#8451)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-04-02 02:20:52 -04:00
Mert
8edc2fb46f
refactor(server): decouple generated images from image formats (#8246)
* rename

thumbnail config

update target paths, fix tests

rename to image settings

replace legacy enum

better typing

update sql

update api

remove config option

fix

* update docs

* update other thumbnail configs in migration

* keep legacy enum for now

* fix jumbled job names

* fix jumbled job names in tests

* rename thumbhash job

* rename dto

* fix tests

* preserve order

* remove unused import

* keep old fields in dto, marked deprecated

* update sql

---------

Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
2024-04-02 04:56:56 +00:00
ZlabiDev
ee4d9fff16
fixes issue #8352 (#8432)
fixed issue #8352
2024-04-01 16:06:25 +00:00
Mert
5bc9158724
fix(server): penalize null geodata fields when searching places (#8408) 2024-03-31 10:59:11 -04:00
Pablo Diz
6a4bc777a2
Fix external library path validation #8319 (#8366)
* Fix isImmichPath

* prettier write

* Fis isImmichPath code comment

* Refactor isImmichPath function based on team suggestions

* Test isImmichPath

* fix: clean comments

* Refactor isImmichPath test based on team suggestions

* Clean code with lintern suggestions
2024-03-31 10:47:03 -04:00
mmomjian
b6af7788e1
feat(server): extensions for MPEG and 3GP (#8400)
* Update mime-types.spec.ts

* Update mime-types.ts
2024-03-30 21:48:01 -05:00
Jason Rasmussen
4b39d37cae
fix: sql generation issues (#8361)
chore: fix sql gen issues
2024-03-30 00:16:06 -04:00
Daniel Dietzler
6f677b4fae
refactor(server): extract add/remove assets logic to utility function (#8329)
extract add/remove assets logic to utility function

fix tests

chore: generate sql

foo
2024-03-29 07:56:16 -04:00
Daniel Dietzler
b8c5363a15
refactor(server): move timeline operations to their own controller/service (#8325)
* move timeline operations to their own controller/service

* chore: open api

* move e2e tests
2024-03-28 23:20:40 -04:00
Daniel Dietzler
b8b3c487d4
fix(server): map style not being available for shared assets (#8341)
* fix map style not being available for shared assets

* add e2e test
2024-03-28 23:19:05 -04:00
Jonathan Jogenfors
ec48fccb30
fix(server): add missing file extensions to library files (#8342)
* fix file extensions

* fix tests

* fix formatting

* fixed bug

* fix merts comments
2024-03-28 22:51:07 -04:00
Alex The Bot
16513b4a6e Version v1.100.0 2024-03-28 18:36:38 +00:00
Alex
9b705e4450
chore(server): open-api memory lane number generation (#8314)
chore(server): openaapi memory lane number generation
2024-03-27 22:27:26 -05:00
Jason Rasmussen
9fe80c25eb
fix: memory lane assets in ascending order (#8309)
* fix: memory lane asset order

* chore: deprecate title

* chore: open-api

* chore: rename years => yearsAgo
2024-03-27 16:14:29 -04:00
renovate[bot]
916603d2d4
fix(deps): update typescript-projects (#8287)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-03-27 12:07:49 -04:00
renovate[bot]
6295edcdb7
chore(deps): update base-image to v20240326 (major) (#8291)
chore(deps): update base-image to v20240326

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-03-26 09:17:48 -04:00
renovate[bot]
1ad893ded4
fix(deps): update typescript-projects (#8281)
* fix(deps): update typescript-projects

* chore: regenerate sql

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-03-26 02:39:57 +00:00
Mert
c45e28ab53
refactor(server): metric repo (#8278)
* refactor

* redundant `implements`

* simplify

* remove `enabled`
2024-03-25 23:15:11 +00:00
Daniel Dietzler
c56c04a82b
refactor(server): rename filesystem provider -> storage repo (#8277)
rename filesystem provider -> storage repo
2024-03-25 20:45:21 +00:00
Daniel Dietzler
1694dd146e
feat(server): add immich cli to container (#8239)
add immich cli to server container
2024-03-25 08:18:33 -04:00
Mert
4a6a0aa142
fix(server): places page not working with partner sharing (#8257) 2024-03-25 01:59:11 -04:00
Mert
c58a70ac8f
feat(server): job metrics (#8255)
* metric repo

* add metric repo

* remove unused import

* formatting

* fix

* try disabling job metrics for e2e

* import otel in test module
2024-03-24 23:02:04 -04:00
Jason Rasmussen
a771c563ba
chore(server): remove pre-installed cli (#8224) 2024-03-23 16:07:39 -04:00
Mert
b07a565e34
chore(server): change upsert signature for search repo (#8210)
* upsert embedding

* remove unused imports
2024-03-23 14:37:06 -04:00
Jason Rasmussen
787eebcf1e
refactor(server): new password repo method (#8208) 2024-03-23 14:33:25 -04:00
Mert
604b8ff17c
chore(server): remove getByDate from asset repo (#8211)
* remove getByDate

* remove unused import
2024-03-22 23:20:16 -05:00
Jason Rasmussen
6e93ddf2f1
refactor: server events (#8204)
* refactor: server events

* fix typo

---------

Co-authored-by: Daniel Dietzler <36593685+danieldietzler@users.noreply.github.com>
2024-03-22 18:24:02 -04:00
Jason Rasmussen
b6e4be72f0
chore(server): consolidate dto files (#8201)
chore: conoslidate dto files
2024-03-22 16:36:20 -04:00
Daniel Dietzler
d6823b128c
fix(server): validation events actually throwing an error (#8172)
* fix validation events

* add e2e test
2024-03-21 17:59:21 -05:00
Jason Rasmussen
dc3c329431
chore: remove unused type (#8157) 2024-03-21 14:36:10 +00:00
Jason Rasmussen
2a9f2b4515
refactor: app modules, main.ts (#8156) 2024-03-21 10:08:29 -04:00
Jason Rasmussen
382b63954c
refactor: asset v1, app.utils (#8152) 2024-03-21 09:07:47 -04:00
Daniel Dietzler
b588a87d4a
chore(server): rename domain repositories -> interfaces (#8147)
rename domain repositories
2024-03-21 06:59:49 -05:00
Jason Rasmussen
16d0df796c
refactor: infra folder (#8138) 2024-03-20 23:15:09 -04:00
Daniel Dietzler
ef4a492cb1
chore(server): move services (#8133)
move services
2024-03-20 18:07:30 -05:00
Daniel Dietzler
6d9e7694b1
chore(server): move dtos (#8131)
move dtos
2024-03-20 23:53:07 +01:00
Jason Rasmussen
0c13c63bb6
refactor: infra/domain module (#8130) 2024-03-20 16:46:59 -05:00
Jason Rasmussen
907eb869bc
chore: move apps and test utils (#8129) 2024-03-20 17:22:47 -04:00
Jason Rasmussen
c1402eee8e
chore: migrate database files (#8126) 2024-03-20 21:02:51 +00:00
Daniel Dietzler
84f7ca855a
chore(server): move domain interfaces (#8124)
move domain interfaces
2024-03-20 16:42:58 -04:00
Daniel Dietzler
2dcce03352
chore(server): move commands (#8121)
move commands
2024-03-20 20:25:33 +00:00
renovate[bot]
96a22ec3c1
chore(deps): update base-image to v20240319 (major) (#8115)
chore(deps): update base-image to v20240319

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-03-20 16:21:27 -04:00
Daniel Dietzler
4b29bccc7c
chore(server): move cores (#8120)
move cores
2024-03-20 20:20:38 +00:00
Jason Rasmussen
40e079a247
chore: move controllers and middleware (#8119) 2024-03-20 16:15:01 -04:00
Jason Rasmussen
81f0265095
chore: organize config, validation, decorators (#8118)
* refactor: validation

* refactor: utilities

* refactor: config
2024-03-20 16:04:03 -04:00
renovate[bot]
3f0d54c752
fix(deps): update server (#8067)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-03-20 15:34:12 -04:00
renovate[bot]
2267ca1949
chore(deps): update node.js to 8765147 (#8058)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-03-20 14:38:28 -04:00
Daniel Dietzler
30f499cf2e
chore(server): use absolute import paths (#8080)
update server to use absolute import paths
2024-03-20 14:32:04 -04:00
Alex The Bot
5b314ffd46 Version v1.99.0 2024-03-20 14:50:57 +00:00
Jonathan Jogenfors
e6f2bb9f89
fix(server): use extension in originalFileName for libraries (#8083)
* use file base

* fix: test

* fix: e2e-job tests

---------

Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
2024-03-19 23:40:28 -05:00
Mert
f392fe7702
fix(server): "view all" for cities only showing 12 cities (#8035)
* view all cities

* increase limit

* rename endpoint

* optimize query

* remove pagination

* update sql

* linting

* revert sort by count in explore page for now

* fix query

* fix

* update sql

* move to search, add partner support

* update sql

* pr feedback

* euphemism

* parameters as separate variable

* move comment

* update sql

* linting
2024-03-20 03:23:57 +00:00
Mert
2daed747cd
chore(server): change save -> update in asset repository (#8055)
* `save` -> `update`

* change return type

* include relations

* fix tests

* remove when mocks

* fix

* stricter typing

* simpler type
2024-03-19 22:42:10 -04:00
Jason Rasmussen
40262c30cb
refactor(server): library service (#8050)
* refactor: library service

* chore: open api

* fix: checks
2024-03-18 16:59:53 -04:00
Alex
761e7fdd2d
feat(server): memory includes partners assets on timeline (#7993)
* feat(server): memory includes partners assets on timeline

* remove unsued code, generate sql

* fix test

* add test
2024-03-18 14:46:52 -05:00
Daniel Dietzler
148428a564
feat(server): use nestjs events to validate config (#7986)
* use events for config validation

* chore: better types

* add unit tests

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-03-17 20:16:02 +01:00
Mert
a9438a9c2d
fix(server): prevent feedback loop during library scan (#7944)
* prevent feedback loop

* add nesting

* made nesting less ugly

---------

Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
2024-03-15 22:01:58 +00:00
renovate[bot]
8c24a994e1
fix(deps): update exiftool (#7879)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-03-15 15:40:32 -05:00
sevtdy
64f53e674c
feat(web): add millisecond options to storage template settings (#7942)
* feat(web): add millisecond options storage template settings

* fix(web): fix test

---------

Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
2024-03-15 20:13:08 +00:00
Jason Rasmussen
2a0e1c0d3c
refactor: global validation pipe (#7985)
* refactor: global validation pipe

* chore: formatting
2024-03-15 12:51:08 -04:00
DeclanE
0f79c4ff46
feat(server): added support for SVG files (#7960)
* Added SVG Support

* Removed comment

* Server Test fixes

* Sorted the mimetypes

* Reverted mimetypes.assettype

* Lint

* fix test

---------

Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
2024-03-15 16:02:31 +00:00
Daniel Dietzler
a46366d336
chore(server): introduce proper job status (#7932)
* introduce proper job status

* fix condition for onDone jobs

* fix tests
2024-03-15 09:16:54 -04:00
Jason Rasmussen
07e8f79563
refactor: library e2e (#7969) 2024-03-15 09:16:08 -04:00
Jason Rasmussen
0b8edb7671
chore: remove unused dep (#7957) 2024-03-14 16:18:55 -04:00
martin
31f7e1aca3
feat(server, web): album orders (#7819)
* feat: album orders

* fix: tests

* pr feedback

* pr feedback

* pr feedback

* fix: tests

* add comment

* pr feedback

* fix: rendering issue

* wording

* fix: order value doesn't change

---------

Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
2024-03-14 11:45:03 -05:00
Jonathan Jogenfors
ba38713fbc
fix(server): queue library asset refresh in batches (#7914)
* add debug logs

* scan assets in batches

* Cleanup

* don't normalize

* Removing extra log

* remove unneeded code

* change log levels
2024-03-14 14:43:05 +01:00
Mert
ee8e8a0c0f
perf(server): optimize getByIds query (#7918)
* clean up usage

* i'm not updating all these tests

* update tests

* add indices

* add indices to entities

remove index from person entity

add to face entity

fix

* simplify query

* update sql

* missing await

* remove synchronize false
2024-03-14 01:58:09 -04:00
Mert
d67cc00e4e
feat(server): lower library scan memory usage (#7939)
* use trie

* update tests

* formatting

* pr feedback

* linting
2024-03-14 01:52:30 -04:00
Kokul Shanmugharajah
29c3a826c5
feat(server): Update XMP sidecar search to look for both photo.ext.xmp and photo.xmp (#7813)
* Add support for photo.xmp sidecars

* format

* Add comment

* Proper handling

* Handle mocking better

* Address PR feedback

* Add test coverage if both xmp files exist

* Update server/src/domain/metadata/metadata.service.ts

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>

* Update server/src/domain/metadata/metadata.service.ts

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>

* Update server/src/domain/metadata/metadata.service.ts

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>

---------

Co-authored-by: Alex <alex.tran1502@gmail.com>
Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-03-13 12:14:26 -05:00
renovate[bot]
d67a6b7293
fix(deps): update server (#7898)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-03-13 12:54:46 -04:00
bo0tzz
72f9295490
feat(server): YAML config file support (#7894)
* test(server): Load config from yaml

* docs: YAML config support

* feat(server): YAML config file support

* fix format

---------

Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
2024-03-12 16:29:49 +01:00
renovate[bot]
1683bb75e1
fix(deps): update server (#7880) 2024-03-12 11:28:45 -04:00
renovate[bot]
3cd232f571
chore(deps): update base-image to v20240312 (major) (#7892)
chore(deps): update base-image to v20240312

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-03-12 08:07:56 -04:00
Mert
a097e903c9
feat(server): OpenTelemetry integration (#7356)
* wip

* span class decorator

fix typing

* improvements

* noisy postgres logs

formatting

* add source

* strict string comparison

Co-authored-by: Daniel Dietzler <36593685+danieldietzler@users.noreply.github.com>

* remove debug code

* execution time histogram

* remove prometheus stuff

remove prometheus data

* disable by default

disable nestjs-otel stuff by default

update imports

* re-add postgres instrumentation

formatting

formatting

* refactor: execution time histogram

* decorator alias

* formatting

* keep original method order in filesystem repo

* linting

* enable otel sdk in e2e

* actually enable otel sdk in e2e

* share exclude paths

* formatting

* fix rebase

* more buckets

* add example setup

* add envs

fix

actual fix

* linting

* update comments

* update docker env

* use more specific env

---------

Co-authored-by: Daniel Dietzler <36593685+danieldietzler@users.noreply.github.com>
Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-03-12 05:19:12 +00:00
Dhrumil Shah
bbed14a9ff
feat(server): Add OAuth auto-redirect enable/disable CLI commands (#7841)
* Rebase

* format fix

* docs format

* Change to enable/disable oauth master

* spell change for oauth

* Fix filename
2024-03-11 23:32:00 -04:00
renovate[bot]
4b6206b32d
chore(deps): update server (#7869)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-03-11 23:22:55 -04:00
Ben McCann
078da36f20
fix(server): serve static directory only if it exists (#7857)
* fix(server): serve static directory only if it exists

* update

* refactor: web root

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-03-11 13:06:04 -04:00
Mert
8dc62bd29a
fix(server): face search results not always sorted (#7839)
* order by

* update sql
2024-03-11 09:19:20 -05:00
Alex The Bot
4027cba4eb Version v1.98.2 2024-03-11 14:17:12 +00:00
Mert
5bd597f14b
fix(server): external library sync not working for large libraries (#7759) 2024-03-10 22:30:57 -04:00
Daniel Dietzler
ec8fb0be83
chore(server): remove unused storage repository variable from microservices app service (#7797)
remove unused storage repository from microservices app service
2024-03-09 16:06:31 -05:00
Jason Rasmussen
30b0b2474e
refactor: asset e2e (#7769) 2024-03-09 12:51:58 -05:00
Fynn Petersen-Frey
3f1d37e556
feat(server): hardware HDR tonemapping for RKMPP (#7655)
* feat(server): hardware HDR tonemapping for RKMPP

* review feedback
2024-03-08 21:17:26 -05:00
Ben McCann
ba55e867e0
perf: precompress and cache assets (#7757)
* perf: precompress and cache assets

* fix cache header

* use startswith

---------

Co-authored-by: mertalev <101130780+mertalev@users.noreply.github.com>
2024-03-08 21:15:38 -05:00
Alex The Bot
430561d692 Version v1.98.1 2024-03-08 23:44:13 +00:00
Alex
e8fb529026
fix(server): getAllAssets doesn't return all assets (#7752)
* fix(server): getAllAssets doesn't return all assets

* try reverting

* fix: archive and remove unused method

* update sql

* remove unused code

* linting
2024-03-08 17:16:32 -06:00
Sam Holton
7a4ae7d142
feat(server,web): add force delete to immediately remove user (#7681)
* feat(server,web): add force delete to immediately remove user

* update wording on force delete confirmation

* fix force delete css

* PR feedback

* cleanup user service delete for force

* adding user status column

* some cleanup and tests

* more test fixes

* run npm run sql:generate

* chore: cleanup and websocket

* chore: linting

* userRepository.restore

* removed bad color class from delete-confirm-dialoge

* additional confirmation for user force delete

* shorten confirmation message

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-03-08 17:49:39 -05:00
Jason Rasmussen
89f6190fb0
refactor: search e2e (#7732) 2024-03-08 11:20:54 -05:00
Jason Rasmussen
a50f125dd1
refactor: api validators (boolean and date) (#7709)
* refactor: api validators (boolean and date)

* chore: open api

* revert: time bucket change
2024-03-07 22:59:02 -05:00
Sam Holton
dbb6a8dc2a
fix(server): remove shared links during user delete (#7696)
* fix(server): remove shared links during user delete

* add delete cascade for shared links
2024-03-07 17:21:23 -05:00
Jason Rasmussen
661409bac7
feat(server): create a person with optional values (#7706)
* feat: create person dto

* chore: open api

* fix: e2e

* fix: web usage
2024-03-07 15:34:57 -05:00
Jonathan Jogenfors
f1a8e385e9
deps(server): CVE-2024-28176 (#7717)
bumpety bump
2024-03-07 15:34:10 -05:00
Alex The Bot
7dc5e0cc4f Version v1.98.0 2024-03-07 19:22:14 +00:00
Alex Tran
ba5d5256b1 Revert "Version v1.98.0"
This reverts commit 9b1a379fa6.
2024-03-07 12:04:54 -06:00
Alex Tran
307ffc990d fix(server): admin access to edit library 2024-03-07 12:03:21 -06:00
Alex The Bot
9b1a379fa6 Version v1.98.0 2024-03-07 17:40:40 +00:00
Jonathan Jogenfors
4cb0f37918
chore(server): Move library watcher to microservices (#7533)
* move watcher init to micro

* document watcher recovery

* chore: fix lint

* add try lock

* use global library watch lock

* fix: ensure lock stays on

* fix: mocks

* unit test for library watch lock

* move statement to correct test

* fix: correct return type of try lock

* fix: tests

* add library teardown

* add chokidar error handler

* make event strings an enum

* wait for event refactor

* refactor event type mocks

* expect correct error

* don't release lock in teardown

* chore: lint

* use enum

* fix mock

* fix lint

* fix watcher await

* remove await

* simplify typing

* remove async

* Revert "remove async"

This reverts commit 84ab5abac4.

* can now change watch settings at runtime

* fix lint

* only watch libraries if enabled

---------

Co-authored-by: mertalev <101130780+mertalev@users.noreply.github.com>
Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
2024-03-07 11:36:53 -06:00
Michel Heusschen
2dcd0e516f
fix(server): add extension to filename migration (#7697) 2024-03-07 09:33:56 -05:00
Alex
e823b39579
fix(server): access face count when the value is undefined (#7694) 2024-03-06 23:21:10 -05:00
Alex
1eea547aa2
chore(server): search filename using originalFileName (#7691) 2024-03-06 22:36:08 -05:00
Mert
1ec5d612fa
perf(server): use queries to refresh library assets (#7685)
* use queries instead of js

* missing await

* add mock methods

* fix test

* update sql

* linting
2024-03-06 21:23:10 -06:00
renovate[bot]
fcb990665c
chore(deps): update base-image to v20240305 (major) (#7682)
chore(deps): update base-image to v20240305

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-03-06 22:22:55 -05:00
Mert
ffaa08e7ea
chore(server): lower default max recognition distance for facial recognition (#7689)
lower default to 0.5
2024-03-06 22:20:38 -05:00
Alex
3da2b05428
chore(server): save original file name with extension (#7679)
* chore(server): save original file name with extension

* extract extension

* update e2e test

* update e2e test

* download archive

* fix download archive appending name

* pr feedback

* remove unused code

* test

* unit test

* remove unused code

* migration

* noops

* pr feedback

* Update server/src/domain/download/download.service.ts

Co-authored-by: Mert <101130780+mertalev@users.noreply.github.com>

---------

Co-authored-by: Mert <101130780+mertalev@users.noreply.github.com>
2024-03-07 02:34:55 +00:00
Sam Holton
9125999d1a
feat(server,web): make user deletion delay configurable (#7663)
* feat(server,web): make user deletion delay configurable

* alphabetical order

* add min for user.deleteDelay in SettingInputField

* make config.user.deleteDelay SettingInputField min consistent format

* fix e2e test

* update description on user delete delay
2024-03-05 23:45:40 -06:00
Alex
52dfe5fc92
fix(server): stack info in asset response for mobile (#7346)
* fix(server): stack info in asset response for mobile

* fix(server): getAllAssets - do not filter by stack ID

* tet(server): GET /assets stack e2e

* chore(server): fix checks

* stack asset height

---------

Co-authored-by: shenlong-tanwen <139912620+shalong-tanwen@users.noreply.github.com>
2024-03-06 05:44:56 +00:00
Alex
2f53f6a62c
feat(web): search by filename (#7624)
* Toggle to search by filename

* wild card search and pr feedback

* Pr feedback

* naming

* placeholder

* Create index

* pr feedback

* pr feedback

* Update web/src/lib/components/shared-components/search-bar/search-text-section.svelte

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>

* pr feedback

* pr feedback

* pr feedback

* pr feedback

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-03-05 17:08:35 -06:00
renovate[bot]
51f6b8f23b
chore(deps): update dependency @types/cookie-parser to v1.4.7 (#7661)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-03-05 17:31:26 -05:00
Jonathan Jogenfors
5d377e5b0f
chore(server): eslint await-thenable (#7545)
* await-thenable

* fix library watchers

* moar eslint

* fix test

* fix typo

* try to remove check void return

* fix checksVoidReturn

* move to domain utils

* remove eslint ignores

* chore: cleanup types

* chore: use logger

* fix: e2e

---------

Co-authored-by: Ben McCann <322311+benmccann@users.noreply.github.com>
Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-03-05 17:23:06 -05:00
Jason Rasmussen
972d5a3411
feat(server): deterministic download order (#7658) 2024-03-05 15:04:43 -06:00
renovate[bot]
8df63b7c94
fix(deps): update dependency archiver to v7 (#7622)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-03-05 12:26:54 -05:00
renovate[bot]
ee3b2a0cf5
chore(deps): update server (#7652)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-03-05 12:16:41 -05:00
renovate[bot]
a5d19bc945
fix(deps): update server (#7635)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-03-05 03:48:00 +00:00
martin
6ab404597c
fix(server): incorrect number of assets for a person (#7602)
* fix: incorrect number of assets

* fix: tests

* pr feedback

* fix: e2e test

* fix: e2e test

* fix: e2e test

* feat: more tests
2024-03-04 18:11:54 -05:00
Robert Vollmer
de71d8e0a3
fix(server): regular version check (#7620)
`dt.diffNow()` equals `dt.diff(DateTime.now())`, so it returns a
negative number when `dt` is in the past (which it always is in this
case).

Therefore we could only get over the condition during startup (when
`this.releaseVersionCheckedAt` isn't set yet), effectively breaking
update notifications while the server is running.
2024-03-04 08:42:22 -06:00
Sam Holton
7ef202c8b2
feat(server, web): add checkbox to create user screen for shouldChang… (#7598)
feat(server, web): add checkbox to create user screen for shouldChangePassword
2024-03-03 23:40:03 -06:00
Mert
2fa10a254c
feat(web): improve alt text (#7596)
* alt text

* memory lane alt text

* revert sql generator change

* use getAltText

* oops

* handle large number of people in asset

* nit

* add aria-label to search button

* update api

* fixed tests

* fixed typing

* fixed spacing

* fix displaying null
2024-03-03 16:42:17 -05:00
martin
ebe7a14c14
fix(server): prevent leaking isFavorite and isArchived info (#7580)
* fix: prevent leaking favorites info

* add e2e test

* fix: e2e test

* fix: isArchived

* fix: keep old version
2024-03-02 18:01:24 -05:00
Sam Holton
f03381a5b1
feat(server): allow oauth claim to set 0 for no quota (#7581)
* feat(server): allow oauth claim to set 0 for no quota

* PR feedback to remove extra objects from user.stub.ts
2024-03-02 14:18:56 -06:00
Sam Holton
7303fab9d9
feat(server/web): add oauth defaultStorageQuota and storageQuotaClaim (#7548)
* feat(server/web): add oauth defaultStorageQuota and storageQuotaClaim

* feat(server/web): fix format and use domain.util constants

* address some pr feedback

* simplify oauth storage quota logic

* adding tests and pr feedback

* chore: cleanup

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-03-01 19:46:07 -05:00
Simon Séhier
3e06062974
fix(immich-admin): only 1st argument was passed (#7552) 2024-03-01 07:34:59 -05:00
Michel Heusschen
c89d91e006
feat: filter people when using smart search (#7521) 2024-02-29 16:14:48 -05:00
Jason Rasmussen
15a4a4aaaa
chore: remove unused upload property (#7535)
* chore: remove isExternal

* chore: open-api
2024-02-29 16:02:08 -05:00
Jason Rasmussen
3d25d91e77
refactor: library e2e (#7538)
* refactor: library e2e

* refactor: remove before each usages
2024-02-29 15:10:08 -05:00
Jonathan Jogenfors
efa6efd200
feat(server,web): remove external path nonsense and make libraries admin-only (#7237)
* remove external path

* open-api

* make sql

* move library settings to admin panel

* Add documentation

* show external libraries only

* fix library list

* make user library settings look good

* fix test

* fix tests

* fix tests

* can pick user for library

* fix tests

* fix e2e

* chore: make sql

* Use unauth exception

* delete user library list

* cleanup

* fix e2e

* fix await lint

* chore: remove unused code

* chore: cleanup

* revert docs

* fix: is admin stuff

* table alignment

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
2024-02-29 12:35:37 -06:00
Jason Rasmussen
af0de1a768
chore: linting (#7532)
* chore: linting

* fix: broken tests

* fix: formatting
2024-02-29 11:26:55 -05:00
Jason Rasmussen
bb3d81bfc5
chore: build tweaks (#7484) 2024-02-29 09:22:25 -05:00
Mert
dc7a329cc8
fix(server): only queue ml / transcoding jobs after thumbnail generation on upload (#7516) 2024-02-28 23:23:21 -05:00
Mert
11de526bcf
fix(server): re-add mimalloc (#7511)
add mimalloc
2024-02-28 18:23:48 -05:00
Alex The Bot
6f53e83d49 Version v1.97.0 2024-02-28 22:34:00 +00:00
Jonathan Jogenfors
e4f32a045d
chore: remove watcher polling option (#7480)
* remove watcher polling

* fix lint

* add db migration
2024-02-28 21:20:10 +01:00
Jason Rasmussen
74d431f881
refactor(server): format and metadata e2e (#7477)
* refactor(server): format and metadata e2e

* refactor: on upload success waiting
2024-02-28 10:21:31 +01:00
Fynn Petersen-Frey
87a7825cbc
feat(server): rkmpp hardware decoding scaling (#7472)
* feat(server): RKMPP hardware decode & scaling

* disable hardware decoding for HDR
2024-02-27 20:32:07 -05:00
Alex The Bot
6d91c23f65 Version v1.96.0 2024-02-27 20:14:58 +00:00
renovate[bot]
df02a9f5ed
chore(deps): update dependency @types/node to v20.11.20 (#7476)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-02-27 19:16:37 +00:00
Jason Rasmussen
807cd245f4
refactor(server): e2e (#7462)
* refactor: trash e2e

* refactor: asset e2e
2024-02-27 14:04:38 -05:00
renovate[bot]
df9ab8943d
chore(deps): update base-image to v20240227 (major) (#7470)
chore(deps): update base-image to v20240227

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-02-27 14:03:02 -05:00
Alex
57f25855d3
fix(web/server): revert renovate hash update (#7464)
* Revert "chore(deps): update node.js to f3299f1 (#7444)"

This reverts commit cfb49c8be0.

* Revert "chore(deps): update node.js to f3299f1 (#7443)"

This reverts commit 2f121af9ec.
2024-02-27 10:28:00 -06:00
renovate[bot]
e02964ca0d
chore(deps): update server (#7447)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-02-27 10:26:37 -06:00
Fynn Petersen-Frey
5e485e35e9
feat(server): easy RKMPP video encoding (#7460)
* feat(server): easy RKMPP video encoding

* make linter happy
2024-02-27 09:47:04 -06:00
renovate[bot]
cfb49c8be0
chore(deps): update node.js to f3299f1 (#7444)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-02-27 09:29:25 -06:00
Mert
fb18129843
fix(server): truncate embedding tables (#7449)
truncate
2024-02-27 09:24:23 -06:00
Daniel Dietzler
3e8af16270
refactor(web): search box (#7397)
* refactor search suggestion handling

* chore: open api

* revert server changes

* chore: open api

* update location filters

* location filter cleanup

* refactor people filter

* refactor camera filter

* refactor display filter

* cleanup

---------

Co-authored-by: Michel Heusschen <59014050+michelheusschen@users.noreply.github.com>
2024-02-26 15:45:08 -06:00
Mert
45ecb629a1
fix(server): storage template migration not working (#7414)
add `withExif`
2024-02-25 13:18:09 -05:00
martin
a2934b8830
feat(server, web): search location (#7139)
* feat: search location

* fix: tests

* feat: outclick

* location search index

* update query

* fixed query

* updated sql

* update query

* Update search.dto.ts

Co-authored-by: Daniel Dietzler <36593685+danieldietzler@users.noreply.github.com>

* coalesce

* fix: tests

* feat: add alternate names

* fix: generate sql files

* single table, add alternate names to query, cleanup

* merge main

* update sql

* pr feedback

* pr feedback

* chore: fix merge

---------

Co-authored-by: mertalev <101130780+mertalev@users.noreply.github.com>
Co-authored-by: Daniel Dietzler <36593685+danieldietzler@users.noreply.github.com>
2024-02-23 19:42:37 -05:00
Michel Heusschen
07ef008b40
fix(server): exclude archived assets from orphaned files (#7334)
* fix(server): exclude archived assets from orphaned files

* add e2e test
2024-02-22 11:16:10 -05:00
Michel Heusschen
e3cccba78c
fix(server): out of memory when unstacking assets (#7332) 2024-02-22 08:50:46 -05:00
Michel Heusschen
ec55acc98c
perf(server): optimize mapAsset (#7331) 2024-02-22 08:48:27 -05:00
renovate[bot]
869e9f1399
chore(deps): update base-image to v20240222 (major) (#7338)
chore(deps): update base-image to v20240222

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-02-22 08:16:56 -05:00
Mert
749b182f97
fix(server): fix log for setting other vector extension (#7325)
fix log
2024-02-21 18:47:43 -05:00
Jason Rasmussen
2ebb57cbd4
refactor: e2e client (#7324) 2024-02-21 17:34:11 -05:00
martin
5c0c98473d
fix(server, web): people page (#7319)
* fix: people page

* fix: use locale

* fix: e2e

* fix: remove useless w-full

* fix: don't count people without thumbnail

* fix: es6 template string

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-02-21 17:03:45 -05:00
Jason Rasmussen
546edc2e91
refactor: album e2e (#7320)
* refactor: album e2e

* refactor: user e2e
2024-02-21 16:52:13 -05:00
Michel Heusschen
173b47033a
fix(server): search with same face multiple times (#7306) 2024-02-21 09:52:38 -06:00
Jason Rasmussen
f798e037d5
refactor(server): e2e (#7265)
* refactor: activity e2e

* refactor: person e2e

* refactor: shared link e2e
2024-02-21 08:28:03 -05:00
renovate[bot]
a1bc74cdd6
fix(deps): update exiftool (#7230)
* fix(deps): update exiftool

* documenting such changes would have been too easy

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Daniel Dietzler <mail@ddietzler.dev>
2024-02-21 08:26:13 -05:00
renovate[bot]
43f887e5f2
chore(deps): update dependency @types/node to v20.11.19 (#7239)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-02-21 08:25:28 -05:00
Mert
397570ad1a
chore(server): change transcode default to accept all supported audio codecs (#7283)
* change transcode defaults

* don't untick accepted audio codecs

* no need to change the transcode policy

* fix tests

* remove log
2024-02-21 00:25:30 -05:00
Alex The Bot
7c34d0595e Version v1.95.1 2024-02-21 04:02:43 +00:00
Mert
eb73f6605b
fix(server): don't return archived assets by default (#7278)
* don't show archived results by default

* fix e2e

* generate sql

* set default in dto

---------

Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
2024-02-21 03:59:26 +00:00
Alex
bb5236ae65
fix(server): not in album filter with context search (#7275) 2024-02-20 20:44:34 -06:00
Mert
e33fd40b4c
fix(server): quote database name in migration (#7277)
quote database name
2024-02-21 02:13:43 +00:00
Alex The Bot
302d98ebe1 Version v1.95.0 2024-02-20 16:52:23 +00:00
Jonathan Jogenfors
b3c7bebbd4
feat(server,web) Semantic import path validation (#7076)
* add library validation api

* chore: open api

* show warning i UI

* add flex row

* fix e2e

* tests

* fix tests

* enforce path validation

* enforce validation on refresh

* return 400 on bad import path

* add limits to import paths

* set response code to 200

* fix e2e

* fix lint

* fix test

* restore e2e folder

* fix import

* use startsWith

* icon color

* notify user of failed validation

* add parent div to validation

* add docs to the import validation

* improve library troubleshooting docs

* fix button alignment

---------

Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
2024-02-20 09:53:12 -06:00
renovate[bot]
7158706296
fix(deps): update server (#7224)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-02-19 22:34:39 -05:00
Jason Rasmussen
9b20604a70
refactor(server): e2e (#7223)
* refactor: download e2e

* refactor: oauth e2e

* refactor: system config e2e

* refactor: partner e2e

* refactor: server-info e2e

* refactor: user e2e

* chore: uncomment test
2024-02-19 22:34:18 -05:00
Mert
6690e8edf2
fix(docs): document vector extension env variable (#7220) 2024-02-19 21:32:55 -05:00
renovate[bot]
14ca471dea
chore(deps): pin dependencies (#7217)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-02-19 19:35:46 -05:00
Jason Rasmussen
a03b37ca86
refactor: server auth e2e (#7203) 2024-02-19 12:03:51 -05:00
Alex
a8f177066b
fix(server): getAllAssets endpoint includes motion part of LivePhotos (#7194) 2024-02-19 07:24:14 -06:00
martin
66d3daa074
fix: shell scripts (#7189)
* fix: bash scripts

* fix: use bash

* fix: e2e
2024-02-18 20:57:24 -06:00
martin
ddae707ea9
fix: shell scripts (#7186)
* fix: bash scripts

* pr feedback

* wrong variable

* ci: add shellcheck workflow

* fix: missing scripts
2024-02-18 17:03:01 -06:00
Michel Heusschen
4b46bb49d7
fix(server): on_asset_update event sends varying data types (#7179) 2024-02-18 16:50:32 -06:00
renovate[bot]
072f61927c
chore(deps): update typescript-eslint monorepo to v7 (major) (#7171) 2024-02-18 11:26:01 -08:00
Mert
857ec0451d
feat(server): optimize get asset query (#7176)
* faster query

* add index

* remove legacy code

* update mock

* remove unused imports

* add relations

* add stack

* formatting

* remove stack relation

* remove unused import

* increase chunk size

* generate sql

* linting

* fix typing

* formatting
2024-02-18 12:22:25 -06:00
Alex
8e1c85fe4f
fix(server): not in album filter show motion part of LivePhotos (#7175) 2024-02-18 12:17:53 -06:00
Michel Heusschen
0730b54ca9
fix(server): empty/restore trash (#7161)
* fix(server): empty/restore trash

* add e2e tests

* add e2e tests - part 2
2024-02-17 14:05:43 -06:00
Alex
69983ff83a
feat: enhance search (#7127)
* feat: hybrid search

* fixing normal search

* building out the query

* okla

* filters

* date

* order by date

* Remove hybrid search endpoint

* remove search hybrid endpoint

* faces query

* search for person

* search and pagination

* with exif

* with exif

* justify gallery viewer

* memory view

* Fixed userId is null

* openapi and styling

* searchdto

* lint and format

* remove term

* generate sql

* fix test

* chips

* not showing true

* pr feedback

* pr feedback

* nit name

* linting

* pr feedback

* styling

* linting
2024-02-17 11:00:55 -06:00
Michel Heusschen
fab19a8583
fix(server): recognize faces when min. faces is set to 1 (#7144)
* fix(server): recognize face when min. faces is set to 1

* update logic

* clarified log

---------

Co-authored-by: mertalev <101130780+mertalev@users.noreply.github.com>
2024-02-17 03:32:11 +00:00
Mert
5ff68d4cdb
feat(server): only transcode streams that require it (#7106) 2024-02-14 11:24:39 -05:00
Torbjorn Tyridal
6adff50f0a
feat(server, web): Include partner's photos on map (#7065)
* feat(server): Include partner's photos on map - if included in timeline

* depend on query parameter withPartners

instead of partners.inTimeline

* web: map option to include partners images

* make open-api
2024-02-14 10:07:00 -05:00
renovate[bot]
b2181ee6f1
chore(deps): update dependency @types/node to v20.11.17 (#7102)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-02-13 22:13:38 +00:00
Alex
4b3f8d1946
feat: Search filtering logic (#6968)
* commit

* controller/service/repository logic

* use enum

* openapi

* suggest people

* suggest place/camera

* cursor hover

* refactor

* Add try catch

* Remove get people with name service

* Remove deadcode

* people selection

* People placement

* sort people

* Update server/src/domain/repositories/metadata.repository.ts

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>

* pr feedback

* styling

* done

* open api

* fix test

* use string type

* remmove bad merge

* use correct type

* fix test

* fix lint

* remove unused code

* remove unused code

* pr feedback

* pr feedback

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-02-13 19:54:58 +00:00
renovate[bot]
cd7a475578
fix(deps): update server (#7069)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-02-13 09:04:01 -05:00
renovate[bot]
338c9b0689
chore(deps): update base-image to v20240213 (major) (#7081)
chore(deps): update base-image to v20240213

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-02-13 09:02:15 -05:00
Jason Rasmussen
b648025e2f
refactor: library watching (#7071) 2024-02-13 08:48:47 -05:00
renovate[bot]
43e099fb56
fix(deps): update dependency picomatch to v4 (#7073)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-02-12 23:37:10 -05:00
Mert
e334443919
feat(server, web): smart search filtering and pagination (#6525)
* initial pagination impl

* use limit + offset instead of take + skip

* wip web pagination

* working infinite scroll

* update api

* formatting

* fix rebase

* search refactor

* re-add runtime config for vector search

* fix rebase

* fixes

* useless omitBy

* unnecessary handling

* add sql decorator for `searchAssets`

* fixed search builder

* fixed sql

* remove mock method

* linting

* fixed pagination

* fixed unit tests

* formatting

* fix e2e tests

* re-flatten search builder

* refactor endpoints

* clean up dto

* refinements

* don't break everything just yet

* update openapi spec & sql

* update api

* linting

* update sql

* fixes

* optimize web code

* fix typing

* add page limit

* make limit based on asset count

* increase limit

* simpler import
2024-02-12 20:50:47 -05:00
martin
f1e4fdf175
refactor: authentication on public routes (#6765)
* refactor: authentication on public routes

* fix: remove public user

* pr feedback

* pr feedback

* pr feedback

* pr feedback

* remove unused method

* fix: tests

* fix: useless methods

* fix: tests

* pr feedback

* pr feedback

* chore: cleanup

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-02-13 01:47:26 +00:00
Alex
dca1bd22df
Change license to AGPLv3 (#7046)
* Change license to AGPLv3

* Readme and documentation

* Package.json

* More replacement

* Added License MIT for previous code

* NIT

* Update LICENSE

Co-authored-by: bo0tzz <git@bo0tzz.me>

* Update cli/LICENSE

Co-authored-by: bo0tzz <git@bo0tzz.me>

* remote mit

---------

Co-authored-by: bo0tzz <git@bo0tzz.me>
2024-02-12 15:31:59 +00:00
Trevor Jex
d7437d31d1
feat(server): restore modified at timestamp after upload, preserve when copying (#7010) 2024-02-11 22:40:34 -06:00
martin
4e31d82bac
feat(server): replace axios dependency by fetch (#7018)
* feat: replace axios dependency by fetch

* pr feedback
2024-02-11 11:15:06 -05:00
shenlong
ec5e4dbcc2
fix(mobile): stack entity handling (#6980)
Co-authored-by: shenlong-tanwen <139912620+shalong-tanwen@users.noreply.github.com>
2024-02-09 21:09:43 -06:00
Jonathan Jogenfors
954c1c2ef4
feat(server): server-side checking of duplicate import paths and exclusion patterns (#6993)
validate path and pattern
2024-02-09 13:02:11 -05:00
Jason Rasmussen
90a7f16817
chore(server): remove deprecated endpoints (#6984)
* chore: remove deprecated endpoints

* chore: open api
2024-02-08 16:57:54 -05:00
Manas Adepu
198e8517e5
fix(server): use luxon for deleted date calculation (#6958)
* luxon implementation

* chore: simplify

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-02-08 16:56:19 -05:00
Jason Rasmussen
bd1fa9377b
refactor(server): asset core (#6985)
refactor: asset core
2024-02-08 16:56:06 -05:00
Jan
4ea15a5b0c
fix(server): check if sidecarPath exists (#6293)
* check if sidecarPath exists

* Revert "check if sidecarPath exists"

This reverts commit 954a1097b870585afee34974d466e51c5172fed9.

* sidecar sync remove dead sidecarPaths and discover new ones

* tests and minor cleanup

* chore: linting

---------

Co-authored-by: Daniel Dietzler <mail@ddietzler.dev>
Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-02-07 17:30:38 +00:00
Mert
b31c7681ae
feat(server): optimize face re-queueing (#6961)
* do not defer faces with no matches

* move comment
2024-02-07 09:56:39 -06:00
renovate[bot]
479fca8f02
chore(deps): pin tensorchord/pgvecto-rs docker tag to 9072418 (#6960)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-02-07 02:51:22 +00:00
Mert
56b0643890
feat(server)!: pgvecto.rs 0.2 and pgvector compatibility (#6785)
* basic changes

update version check

set ef_search for clip

* pgvector compatibility

Revert "pgvector compatibility"

This reverts commit 2b66a52aa4097dd27da58138c5288fd87cb9b24a.

pgvector compatibility: minimal edition

pgvector startup check

* update extension at startup

* wording

shortened vector extension variable name

* nightly docker

* fixed version checks

* update tests

add tests for updating extension

remove unnecessary check

* simplify `getRuntimeConfig`

* wording

* reindex on minor version update

* 0.2 upgrade testing

update prod compose

* acquire lock for init

* wip vector down on shutdown

* use upgrade helper

* update image tag

* refine restart check

check error message

* test reindex

testing

upstream fix

formatting

fixed reindexing

* use enum in signature

* fix tests

remove unused code

* add reindexing tests

* update to official 0.2

remove alpha from version name

* add warning test if restart required

* update test image to 0.2.0

* linting and test cleanup

* formatting

* update sql

* wording

* handle setting search path for new and existing databases

* handle new db in reindex check

* fix post-update reindexing

* get dim size

* formatting

* use vbase

* handle different db name

* update sql

* linting

* fix suggested env
2024-02-06 21:46:38 -05:00
renovate[bot]
f80af067bf
chore(deps): update dependency eslint-plugin-unicorn to v51 (#6952)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-02-06 23:53:55 +01:00
renovate[bot]
d88ca5fb2a
chore(deps): update server (#6930)
* chore(deps): update server

* chore: generate sql

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Daniel Dietzler <mail@ddietzler.dev>
2024-02-06 22:06:02 +00:00
Michael Manganiello
4164bcfd0d
chore(server): Use ChunkedSet in Access repository (#6943)
This change simplifies the Access repository methods, by using the
`ChunkedSet` decorator. As the methods expect sets, the `chunks` util
needed to be fixed, so it returns chunks of the same type it received.

Now `chunks` is overloaded, to have proper typing based on the input
parameter.
2024-02-06 17:03:25 -05:00
renovate[bot]
61768ce89e
chore(deps): update base-image to v20240206 (major) (#6942)
chore(deps): update base-image to v20240206

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-02-06 17:01:07 -05:00
Alex
b768eef44d
fix(server): extract duration from video as ISO time (#6863)
* fix(server): extract duration from video as ISO time

* feedback and add test

* fix test
2024-02-02 14:58:13 -06:00
Daniel Dietzler
d3404f927c
feat(server)!: oauth encryption algorithm setting (#6818)
* feat: add oauth signing algorithm setting

* chore: open api

* chore: change default to RS256

* feat: test and clean up

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-02-02 00:27:54 -05:00
renovate[bot]
b87a6abb2c
fix(deps): update server (#6769)
fix(deps): update dependency @babel/runtime to v7.23.9

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-02-01 22:20:16 -05:00
Jonathan Jogenfors
f44fa45aa0
chore(server,cli,web): housekeeping and stricter code style (#6751)
* add unicorn to eslint

* fix lint errors for cli

* fix merge

* fix album name extraction

* Update cli/src/commands/upload.command.ts

Co-authored-by: Ben McCann <322311+benmccann@users.noreply.github.com>

* es2k23

* use lowercase os

* return undefined album name

* fix bug in asset response dto

* auto fix issues

* fix server code style

* es2022 and formatting

* fix compilation error

* fix test

* fix config load

* fix last lint errors

* set string type

* bump ts

* start work on web

* web formatting

* Fix UUIDParamDto as UUIDParamDto

* fix library service lint

* fix web errors

* fix errors

* formatting

* wip

* lints fixed

* web can now start

* alphabetical package json

* rename error

* chore: clean up

---------

Co-authored-by: Ben McCann <322311+benmccann@users.noreply.github.com>
Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-02-01 22:18:00 -05:00
Alex The Bot
07466fa7b7 Version v1.94.1 2024-01-31 19:21:00 +00:00
Alex The Bot
d4c000cb5a Version v1.94.0 2024-01-31 17:01:33 +00:00
Jason Rasmussen
b0d7434e7b
fix: library watching (#6802) 2024-01-31 11:26:51 -05:00
Jonathan Jogenfors
068e703e88
feat(server): Automatic watching of library folders (#6192)
* feat: initial watch support

* allow offline files

* chore: ignore query errors when resetting e2e db

* revert db query

* add savepoint

* guard the user query

* chore: openapi and db migration

* wip

* support multiple libraries

* fix tests

* wip

* can now cleanup chokidar watchers

* fix unit tests

* add library watch queue

* add missing init from merge

* wip

* can now filter file extensions

* remove watch api from non job client

* Fix e2e test

* watch library with updated import path and exclusion pattern

* add library watch frontend ui

* case sensitive watching extensions

* can auto watch libraries

* move watcher e2e tests to separate file

* don't watch libraries from a queue

* use event emitters

* shorten e2e test timeout

* refactor chokidar code to filesystem provider

* expose chokidar parameters to config file

* fix storage mock

* set default config for library watching

* add fs provider mocks

* cleanup

* add more unit tests for watcher

* chore: fix format + sql

* add more tests

* move unwatch feature back to library service

* add file event unit tests

* chore: formatting

* add documentation

* fix e2e tests

* chore: fix e2e tests

* fix library updating

* test cleanup

* fix typo

* cleanup

* fixing as per pr comments

* reduce library watch config file

* update storage config and mocks

* move negative event tests to unit tests

* fix library watcher e2e

* make watch configuration global

* remove the feature flag

* refactor watcher teardown

* fix microservices init

* centralize asset scan job queue

* improve docs

* add more tests

* chore: open api

* initialize app service

* fix docs

* fix library watch feature flag

* Update docs/docs/features/libraries.md

Co-authored-by: Daniel Dietzler <36593685+danieldietzler@users.noreply.github.com>

* fix: import right app service

* don't be truthy

* fix test speling

* stricter library update tests

* move fs watcher mock to external file

* subscribe to config changes

* docker does not need polling

* make library watch() private

* feat: add configuration ui

---------

Co-authored-by: Daniel Dietzler <36593685+danieldietzler@users.noreply.github.com>
Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
2024-01-31 08:15:54 +00:00
Markus
87c38d1832
feat(server, web): Added TranscodePolicy "Bitrate higher than max bitrate or not in accepted format" (#6479)
* chore: rebase

* chore: open api

* Add Database-Migration for setting targetCodec as acceptedCodec if it was set by admin

* Add TranscodePolicy setting, to only transcode files with a bitrate higher than set max bitrate

* Rename enum value of TranscodePolicy

* calculate max_bitrate according to "k" and "m" suffix for comparison

* remove migration

* minor changes

* UnitTest for Bitrate Policy

* Fix UnitTest

* Add missing output options

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
Co-authored-by: mertalev <101130780+mertalev@users.noreply.github.com>
2024-01-30 20:25:07 -05:00
Ben McCann
9c7dee8551
chore: migrate CLI to ESM and vitest (#6777)
* chore: migrate CLI to ESM and vitest

* fix lint

* update github workflow

* format
2024-01-30 18:23:33 -05:00
martin
1bfef200a5
fix(server): avoid leaking people data on shared links (#6779)
* fix: avoid leaking people data on shared links

* test: add e2e test
2024-01-30 15:34:00 -06:00
renovate[bot]
4290a29107
chore(deps): update base-image to v20240130 (major) (#6756)
chore(deps): update base-image to v20240130

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-30 09:24:44 -06:00
renovate[bot]
40e14fc272
fix(deps): update dependency geo-tz to v8.0.1 (#6750)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-30 08:03:23 -05:00
renovate[bot]
1231d621c4
chore(deps): update server (#6744)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-29 20:58:19 -05:00
t4keda
76f8d030ce
added a configuration option to select the dri node in transcoding (#6376)
* added a configuration option to select the dri node in transcoding

* chore: open api

* refactor: get hawrdware device

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-01-29 20:40:02 -05:00
Jason Rasmussen
6dca47c629
refactor: no experimental vm modules (#6719) 2024-01-29 09:11:02 -06:00
Mert
ae7f174948
refactor: rename clip -> smart search (#6713) 2024-01-29 09:51:22 -05:00
Mert
e5a70329c9
fix(server): HEVC videos not playing on Apple devices (#6712)
* add hvc1 tag

* formatting
2024-01-28 21:17:20 -05:00
Mert
0770ad15e5
fix(server): do not process faces of deleted assets (#6710)
* return if asset is not found

* add unit test

* formatting
2024-01-29 01:17:54 +00:00
Mert
28806d03e3
fix(server): fix person pagination when deleting (#6707)
fix person delete pagination
2024-01-28 17:02:01 -05:00
martin
fa0913120d
feat(web,server): search people (#5703)
* feat: search peoples

* fix: responsive design

* use existing count

* generate sql file

* fix: tests

* remove visible people

* fix: merge, hide...

* use component

* fix: linter

* chore: regenerate api

* fix: change name when searching for a face

* save search

* remove duplicate

* use enums for query parameters

* fix: increase to 20 for the local search

* use constants

* simplify

* fix: number of people more visible

* fix: merge

* fix: search

* fix: loading spinner position

* pr feedback
2024-01-27 19:54:31 -05:00
Daniel Dietzler
e9333837bf
chore(server): use fs to read package.json (#6692)
use fs readsync instead of js import for reading package json
2024-01-27 17:39:33 -05:00
Zack Pollard
25cad79657
refactor: move asset stacks to their own entity (#6353)
* feat: auto-stack burst photos

* feat: move stacks to asset stack entity

* chore: pin node version with volta in server

* chore: update e2e cases

* chore: cleanup

* feat: migrate existing stacks

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-01-27 18:52:14 +00:00
Ben McCann
5cec8d1c63
chore: remove unused test util methods (#6689)
* chore: remove unused test util methods

* format
2024-01-27 12:27:55 -05:00
Markus
8aef92affc
feat(server, web): accepted codecs (#6460)
* chore: rebase

* chore: open api

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-01-26 12:02:56 -05:00
Jason Rasmussen
96b7885583
refactor(server): trash endpoints (#6652)
* refactor(server): trash endpoints

* chore: open api

* chore: fix wrong rename
2024-01-26 11:48:37 -05:00
Jonathan Jogenfors
33757689fe
fix(deps) bump msgpackr (#6673)
bump msgpackr
2024-01-26 16:41:12 +00:00
Jason Rasmussen
7ea55c7236
refactor(server): download endpoints (#6653)
* refactor(server): download controller

* chore: open api

* chore: fix mobile references
2024-01-26 08:19:13 -06:00
renovate[bot]
ae4229b172
chore(deps): update base-image to v20240125 (major) (#6637)
chore(deps): update base-image to v20240125

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-25 20:59:47 -06:00
Jason Rasmussen
b306cf564e
refactor(server): move asset detail endpoint to new controller (#6636)
* refactor(server): move asset by id to new controller

* chore: open api

* refactor: more consolidation

* refactor: asset service
2024-01-25 12:52:21 -05:00
Jason Rasmussen
7fc4abba72
feat(server): sql access checks (#6635) 2024-01-25 10:14:38 -05:00
Mert
bd87eb309c
feat(server): optimize partial facial recognition (#6634)
* optimize partial facial recognition

* add tests

* use map

* bulk insert faces
2024-01-25 01:27:39 -05:00
Jason Rasmussen
852effa998
refactor(server): e2e (#6632) 2024-01-24 17:24:53 -05:00
renovate[bot]
4424f3cb13
fix(deps): update exiftool (#6586)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-24 11:01:46 -05:00
renovate[bot]
160366c5c1
fix(deps): update server (#6588)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-23 18:06:23 -05:00
Jason Rasmussen
bf64e64328
chore(server): remove unused dependency (#6606) 2024-01-23 17:50:39 -05:00
Jason Rasmussen
a00768c9e5
chore(server): remove old device id endpoint (#6578)
* chore: remove old endpoint

* chore: open api

* chore: remove old tests
2024-01-22 20:54:53 -06:00
renovate[bot]
773d093ace
fix(deps): update server (#6587)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-23 02:00:29 +00:00
Aram Akhavan
a972dd4060
fix(server): extraction of Samsung Motionphoto videos (#6337)
* Fix extraction of samsung motionphoto videos

* Refactor binary tag extraction to the repository to consolidate exiftool usage

* format

* fix linting and swap argument orders

* Fix tag name and conditional order

* Add unit test

* Update server test assets submodule

* Remove old motion photo video assets when a new one is extracted

* delete first, then write

* Include motion photo asset uuid's in the filename

If the filenames are not uniquified, then we can't delete old/corrupt ones

* Fix formatting and fix/add tests

* chore: only use new uuid

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-01-22 13:04:45 -05:00
Jason Rasmussen
7b314f9435
chore(server): sort open api params (#6484)
* chore: sort spec

* chore: open api

* chore(mobile): sort auditDeletes params

---------

Co-authored-by: shenlong-tanwen <139912620+shalong-tanwen@users.noreply.github.com>
2024-01-22 11:49:51 -05:00
Jason Rasmussen
bd2dbb4944
fix(web): always use websocket transport (#6564) 2024-01-22 11:37:00 -05:00
renovate[bot]
e6f260c70f
chore(deps): update base-image to v20240118 (major) (#6473)
chore(deps): update base-image to v20240118

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-22 11:07:35 -05:00
Jason Rasmussen
e4277128be
chore: remove unused files and references (#6562) 2024-01-21 22:57:37 -06:00
Daniel Dietzler
607fd39130
fix(server): only calculate quota usage for internal assets (#6556)
only calculate usage for internal assets
2024-01-21 15:48:29 -06:00
Mert
311261bd4e
fix(server): disable sharp file caching (#6542)
don't cache files
2024-01-20 23:10:14 -05:00
Mert
c8b33c00ec
fix(server): use crf-based two pass for vp9 if max bitrate is disabled (#6535)
use crf-based two pass for vp9 if max bitrate is disabled
2024-01-20 15:05:08 -05:00
Alex The Bot
4ebb9974ff Version v1.93.3 2024-01-20 16:03:18 +00:00
Alex The Bot
3dddc6b449 Version v1.93.2 2024-01-19 18:29:04 +00:00
martin
17eaeb695e
feat: smart merge (#6508)
* pr feedback

* fix: tests

* update assets statistics

* pr feedback

* pr feedback

* fix: linter

* pr feedback

* fix: don't limit the smart merge

* pr feedback

* fix: server code

* remove slider

* fix: tests

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-01-19 17:52:26 +00:00
Alex
07b874edda
fix(web): revert smart merge (#6504)
* revert smart merge

* fix test

* fix test

* Remove Slider file
2024-01-19 11:34:20 -06:00
Alex The Bot
d5af357992 Version v1.93.1 2024-01-19 15:01:17 +00:00
Alex The Bot
fa0b7c8563 Version v1.93.0 2024-01-19 02:14:46 +00:00
haosu
660b2e908d
feat(format): hif format (#6477) 2024-01-18 11:18:56 -06:00
Mert
68f52818ae
feat(server): separate face clustering job (#5598)
* separate facial clustering job

* update api

* fixed some tests

* invert clustering

* hdbscan

* update api

* remove commented code

* wip dbscan

* cleanup

removed cluster endpoint

remove commented code

* fixes

updated tests

minor fixes and formatting

fixed queuing

refinements

* scale search range based on library size

* defer non-core faces

* optimizations

removed unused query option

* assign faces individually for correctness

fixed unit tests

remove unused method

* don't select face embedding

update sql

linting

fixed ml typing

* updated job mock

* paginate people query

* select face embeddings because typeorm

* fix setting face detection concurrency

* update sql

formatting

linting

* simplify logic

remove unused imports

* more specific delete signature

* more accurate typing for face stubs

* add migration

formatting

* chore: better typing

* don't select embedding by default

remove unused import

* updated sql

* use normal try/catch

* stricter concurrency typing and enforcement

* update api

* update job concurrency panel to show disabled queues

formatting

* check jobId in queueAll

fix tests

* remove outdated comment

* better facial recognition icon

* wording

wording

formatting

* fixed tests

* fix

* formatting & sql

* try to fix sql check

* more detailed description

* update sql

* formatting

* wording

* update `minFaces` description

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
2024-01-18 00:08:48 -05:00
Mert
9a2fa21b28
fix(server): scale transcoded videos if dimensions are odd (#6461)
scale if odd resolution
2024-01-17 22:16:44 -05:00
Steven Carter
d4146e3e6d
feat(server): provide the ability to search archived photos (#6332)
* Feat: provide the ability to search archived photos

Adds a query parameter (`searchArchived`) to the search URL parameters
to allow the results to contain archived photos.

* chore: rename includeArchived => withArchived

* chore: open api

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-01-18 02:08:00 +00:00
martin
f0b328fb6b
feat(server, web): smart merge (#5796)
* pr feedback

* fix: tests

* update assets statistics

* pr feedback

* pr feedback

* fix: linter

* pr feedback

* fix: don't limit the smart merge

* pr feedback

* fix: server code

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-01-18 01:52:11 +00:00
Alex
c55503496f
fix(server): set log level of immich-admin process in boostrap function (#6458)
* fix(server): set log level of immich-admin process in boostrap function

* Remove log
2024-01-17 16:47:46 -05:00
Jason Rasmussen
6f291006e4
fix(server): handle 5 digit years (#6457) 2024-01-17 16:08:38 -05:00
renovate[bot]
0350058689
fix(deps): update server (#6415)
* fix(deps): update server

* chore: fix tests

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-01-17 18:24:51 +00:00
Alex
78de4f1312
feat(mobile): quota (#6409)
* feat(mobile): quota

* openapi

* user entity update

* Render quota

* refresh usage upon opening the app bar

* stop backup when quota exceed
2024-01-16 20:08:31 -06:00
Jason Rasmussen
abce82e235
fix(server): enable/disable password login on truenas (#6433) 2024-01-16 16:40:09 -05:00
renovate[bot]
76b66e42e1
chore(deps): update base-image to v20240111 (major) (#6355)
chore(deps): update base-image to v20240111

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-16 11:09:59 -05:00
Sushain Cherivirala
7fc1954e2a
fix(server): add filename search (#6394)
Fixes https://github.com/immich-app/immich/issues/5982.

There are basically three options:

1. Search `originalFileName` by dropping a file extension from the query
(if present). Lower fidelity but very easy - just a standard index &
equality.
2. Search `originalPath` by adding an index on `reverse(originalPath)`
and using `starts_with(reverse(query) + "/", reverse(originalPath)`. A
weird index & query but high fidelity.
3. Add a new generated column called `originalFileNameWithExtension` or
something. More storage, kinda jank.

TBH, I think (1) is good enough and easy to make better in the future.
For example, if I search "DSC_4242.jpg", I don't really think it matters
if "DSC_4242.mov" also shows up.

edit: There's a fourth approach that we discussed a bit in Discord and
decided we could switch to it in the future: using a GIN. The minor
issue is that Postgres doesn't tokenize paths in a useful (they're a
single token and it won't match against partial components). We can
solve that by tokenizing it ourselves. For example:

```
immich=# with vecs as (select to_tsvector('simple', array_to_string(string_to_array('upload/library/sushain/2015/2015-08-09/IMG_275.JPG', '/'), ' ')) as vec)  select * from vecs where vec @@ phraseto_tsquery('simple', array_to_string(string_to_array('library/sushain', '/'), ' '));
                                      vec
-------------------------------------------------------------------------------
 '-08':6 '-09':7 '2015':4,5 'img_275.jpg':8 'library':2 'sushain':3 'upload':1
(1 row)
```

The query is also tokenized with the 'split-by-slash-join-with-space'
strategy. This strategy results in `IMG_275.JPG`, `2015`, `sushain` and
`library/sushain` matching. But, `08` and `IMG_275` do not match. The
former is because the token is `-08` and the latter because the
`img_275.jpg` token is matched against exactly.
2024-01-15 14:40:28 -06:00
Tom Vincent
984feafb90
fix(server): extract image description (#6344) 2024-01-15 11:19:41 -05:00
Alex
d096caccac
chore(web): quota enhancement (#6371)
* chore(web): quota enhancement

* show quota in user table

* update quota for single user ioption

* Add a note how to set unlimited storage

* fixed deletion doesn't update quota

* refactor relation

* fixed test

* re-refactor

* update sql

* fix e2e test

* Update server/src/domain/user/user.service.ts

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>

* revert e2e test

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-01-15 09:04:29 -06:00
renovate[bot]
2a8cb70c98
fix(deps): update dependency geo-tz to v8 (#6388)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-15 08:27:59 -05:00
cfitzw
deb1f970a8
feat(server, web): quotas (#4471)
* feat: quotas

* chore: open api

* chore: update status box and upload error message

---------

Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-01-12 19:43:36 -05:00
Jason Rasmussen
f4edb6c4bd
feat(server): track metadata extracted at (#6352) 2024-01-12 19:39:45 -05:00
Jason Rasmussen
2439c5ab57
refactor: open api (#6334) 2024-01-12 07:36:27 -05:00
waclaw66
902977f165
fix(server): exif gps decoding (#6138) 2024-01-10 07:36:54 -05:00
Jason Rasmussen
bf1dd36fa9
refactor(server): split api and jobs into separate e2e suites (#6307)
* refactor: domain and infra modules

* refactor(server): e2e tests
2024-01-09 23:04:16 -05:00
Jason Rasmussen
12dc7c48c9
refactor(server): domain and infra modules (#6301) 2024-01-09 17:07:01 -05:00
Alex The Bot
df59b2099f Version v1.92.1 2024-01-08 15:24:38 +00:00
Daniel Dietzler
7cc0904273
feat(server): disable onboarding when config file is set (#6256) 2024-01-08 09:22:26 -06:00
Alex The Bot
319ddfda53 Version v1.92.0 2024-01-08 05:19:11 +00:00
Zack Pollard
5a66314ead
test: small improvements to database init tests (#6232) 2024-01-07 01:53:09 +00:00
Michael Manganiello
e262298090
fix(server): Split database queries based on PostgreSQL bound params limit (#6034)
* fix(server): Split database queries based on PostgreSQL bound params limit

PostgreSQL uses a 16-bit integer to indicate the number of bound
parameters.

This means that the maximum number of parameters for any query is 65535.
Any query that tries to bind more than that (e.g. searching by a list of
IDs) requires splitting the query into multiple chunks.

This change includes refactoring every Repository that runs queries
using a list of ids, and either flattening or merging results.

Fixes #5788, #5997.

Also, potentially a fix for #4648 (at least based on
[this comment](https://github.com/immich-app/immich/issues/4648#issuecomment-1826134027)).

References:

* https://github.com/typeorm/typeorm/issues/7565
* [PostgreSQL message format - Bind](https://www.postgresql.org/docs/15/protocol-message-formats.html#PROTOCOL-MESSAGE-FORMATS-BIND)

* misc: Create Chunked decorator to simplify implementation

* feat: Add ChunkedArray/ChunkedSet decorators
2024-01-06 20:36:12 -05:00
maxer137
6835d4519a
feat(server): add postgres major version check (#6213)
* feat(server): Throw error when PostgreSQL version is not within the supported versions
The pgvecto.rs extension, though not distributed, can be built for PostgreSQL 12 and 13.
An installation of PostgreSQL 12 with the pgvecto.rs extensions installed will not be caught by immich.
This causes immich to attempt to run the database migrations without having a proper environment.
With assertPostgresql the server will throw an error if the PostgreSQL version is not within the supported range.

* Replaced assertion with lesser than comparison
As requested by @zackpollard

* Changed the comparison to use the minPostgresVersion variable.
If we define one we might as well use it. makes changing the versioning later easier

* Added two new tests, modified two existing tests

`should return if minimum supported PostgreSQL and vectors version are installed`:
Check if init returns properly and that getPostgresVersion is called twice

`should thrown an error if PostgreSQL version is below minimum supported version`:
Checks if the init function correctly returns an error

`should suggest image with postgres ${major} if database is ${major}`:
Modified to set MockResolvedValue instead of MockResolvedValueOnce. With the new check we get the PostgreSQL version twice. So it needs to be set during the entire test.

`should not suggest image if postgres version is not in 14, 15 or 16`:
Modified the bounds to [14, 18]. Because values below 14 now will not get called.
Also Modified to call `getPostgresVersion.MockResolvedValueOnce` for twice, because it gets called twice.

* Fixed two mistakes in the jest functions from previous commit #2abcb60

`should thrown an error if PostgreSQL version is below minimum supported version`:
The regex function I wrote mistakingly used the negate function which check that the error *did not* contain the phrase "PostgreSQL". Which is the opposite

`should not suggest image if postgres version is not in 14, 15 or 16`:
confused bounds for a normal javascript array. Changed the test to only check for values above 16. As values below 14 will get thrown out by test `should return if minimum supported PostgreSQL and vectors version are installed`

I apologise for the mistakes in my previous commit.

* Format fix

---------

Co-authored-by: max <wak@vanling.net>
2024-01-06 19:24:09 -05:00
Mert
41a32b4e6b
feat(server): add rw2 support (#6231) 2024-01-06 23:58:04 +00:00
Alex
0750e13d3f
chore(server): set onboarding for existing instances (#6229)
* chore(server): set onboarding for existing instances

* down
2024-01-06 22:18:42 +00:00
Michael Manganiello
8921278447
fix(server): Execute query in AlbumRepository.removeAsset method (#6216)
The current `removeAsset` implementation just builds the query but does
not execute it. That also seems to be the reason the `@GenerateSql`
decorator was commented out.
2024-01-06 11:56:08 -06:00
Emanuel Bennici
d1e16025cf
fix(server): Fix incorrect sorting with search (#6031)
The search results are not sorted by date causing confision.

Fixes #5916
2024-01-04 14:47:09 -06:00
Zack Pollard
4cf1e553d2
feat(server): in upload folder, split the files into folders based on the first four of the files uuid (#6175) 2024-01-04 14:45:16 -06:00
Alex
13ba83dce6
chore(server): better ML error messages (#5914)
Co-authored-by: Jason Rasmussen <jrasm91@gmail.com>
2024-01-04 21:34:50 +01:00
martin
aefd93e43a
feat(server): add env for reverse geocoding path (#6163)
* feat: add env for reverse geocoding path

* fix: quote in doc
2024-01-04 13:36:52 +00:00
Alex
18f59f78e3
feat(web): onboarding (#6066)
* feat(web): onboarding

* feat: openapi

* feat: modulization

* feat: page advancing

* Animation

* Add storage templaete settings

* sql

* more style

* Theme

* information and styling

* hide/show table

* Styling

* Update user property

* fix test

* fix test:

* fix e2e

* test

* Update web/src/lib/components/onboarding-page/onboarding-hello.svelte

Co-authored-by: bo0tzz <git@bo0tzz.me>

* naming

* use System Metadata

* better return type

* onboarding using server metadata

* revert previous changes in user entity

* sql

* test web

* fix test server

* server/web test

* more test

* consolidate color theme change logic

* consolidate save button to storage template

* merge main

* fix web

---------

Co-authored-by: bo0tzz <git@bo0tzz.me>
2024-01-04 05:28:32 +00:00
Jason Rasmussen
f8d64be13c
feat(server)!: move welcome message to settings (#6157)
* feat(server): move welcome message to settings

* chore: open api
2024-01-04 05:00:17 +00:00
Jason Rasmussen
7b40c20ea5
chore(server): time bucket sql (#6156) 2024-01-03 22:32:52 -06:00
Jason Rasmussen
317adc5c28
feat(web,server): external domain setting (#6146)
* feat: external domain setting

* chore: open api

* mobile: handle serverconfig-externalDomain

---------

Co-authored-by: shenlong-tanwen <139912620+shalong-tanwen@users.noreply.github.com>
2024-01-03 21:54:48 -05:00
renovate[bot]
13fb32513c
fix(deps): update server (#6119)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-03 17:41:30 -05:00
renovate[bot]
23b38a0474
fix(deps): update dependency @nestjs/schedule to v4 (#5348)
* fix(deps): update dependency @nestjs/schedule to v4

* fix: change CronJob in addCronJob to match new type required by nestjs schedule module

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Zack Pollard <zackpollard@ymail.com>
2024-01-01 22:25:25 -05:00
Fynn Petersen-Frey
cc7ba3c21a
feat(server): search across own+partner assets (#5966)
* feat(server): search across own+partner assets

* generate sql

* fix sql parameter
2024-01-01 17:25:22 -05:00
Michael Manganiello
4a5b8c3770
feat(server): Enqueue jobs in bulk (#5974)
* feat(server): Enqueue jobs in bulk

The Job Repository now has a `queueAll` method, that enqueues messages
in bulk (using BullMQ's
[`addBulk`](https://docs.bullmq.io/guide/queues/adding-bulks)),
improving performance when many jobs must be enqueued within the same
operation.

Primary change is in `src/domain/job/job.service.ts`, and other services
have been refactored to use `queueAll` when useful.

As a simple local benchmark, triggering a full thumbnail generation
process over a library of ~1,200 assets and ~350 faces went from
**~600ms** to **~250ms**.

* fix: Review feedback
2024-01-01 15:45:42 -05:00
Jan
7dd88c4114
fix(server): sanitize storagelabel when creating a user #3346 (#5717)
* sanitize storagelabel when creating a user #3346

* code formatting
2024-01-01 15:37:39 -05:00
renovate[bot]
a53b2de3c4
chore(deps): update dependency @types/supertest to v6 (#6099)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-01 19:27:00 +00:00
renovate[bot]
cb3f18bb9f
chore(deps): update base-image to v20231228 (#6095)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-01-01 13:44:02 -05:00
Jason Rasmussen
03eb5ffc5c
refactor(server): simplify config init process (#5702) 2024-01-01 13:16:44 -05:00
martin
0ed89e61ec
fix: remove archived people from explore (#6091) 2024-01-01 11:07:42 -05:00
Zack Pollard
ca9cad20bc
feat: storage template locking + fix for database locks (#6054)
* fix: locks need to be acquired and released using the same session

* feat: only allow a single storage template operation at a single time

this has been added to avoid possible rare race conditions where two files are moved at once to the same path with the same name, causing our duplicate iterator to not detect them and therefore both files will have the same name and overwrite eachother
2023-12-30 09:09:33 -06:00
Zack Pollard
2e38fa73bf
feat: storage template file move hardening (#5917)
* fix: pgvecto.rs extension breaks typeorm schema:drop command

* fix: parse postgres bigints to javascript number types when selecting data

* feat: verify file size is the same as original asset after copying file for storage template job

* feat: allow disabling of storage template job, defaults to disabled for new instances

* fix: don't allow setting concurrency for storage template migration, can cause race conditions above 1

* feat: add checksum verification when file is copied for storage template job

* fix: extract metadata for assets that aren't visible on timeline
2023-12-29 18:41:33 +00:00
Michael Manganiello
5f6bd4ae7e
fix(server): Reduce number of bound parameters in Access queries (#6015)
* fix(server): Reduce number of bound parameters in Access queries

According to https://github.com/typeorm/typeorm/issues/7565, the
introduction of bulk queries for permission checks could quickly reach
the limit of 65536 bound parameters allowed by the PostgreSQL
connection.

To avoid reaching that limit, this first change refactors the Access
queries that are expanding the set of ids multiple times. For example,
`asset.checkSharedLinkAccess` expands the ids 4 times, so providing just
~16400 ids is enough to break the query.

Refactored queries:

* activity.checkCreateAccess

```sql
-- Before
SELECT "AlbumEntity"."id" AS "AlbumEntity_id"
FROM "albums" "AlbumEntity"
    LEFT JOIN "albums_shared_users_users" "AlbumEntity_AlbumEntity__AlbumEntity_sharedUsers"
        ON "AlbumEntity_AlbumEntity__AlbumEntity_sharedUsers"."albumsId"="AlbumEntity"."id"
    LEFT JOIN "users" "AlbumEntity__AlbumEntity_sharedUsers"
        ON "AlbumEntity__AlbumEntity_sharedUsers"."id"="AlbumEntity_AlbumEntity__AlbumEntity_sharedUsers"."usersId"
        AND ("AlbumEntity__AlbumEntity_sharedUsers"."deletedAt" IS NULL)
WHERE
    (
        (
            "AlbumEntity"."id" IN ($1, $2, $3, $4, $5, $6, $7, $8, $9, $10)
            AND "AlbumEntity"."isActivityEnabled" = $11
            AND "AlbumEntity__AlbumEntity_sharedUsers"."id" = $12
        )
        OR (
            "AlbumEntity"."id" IN ($13, $14, $15, $16, $17, $18, $19, $20, $21, $22)
            AND "AlbumEntity"."isActivityEnabled" = $23
            AND "AlbumEntity"."ownerId" = $24
        )
    )
    AND "AlbumEntity"."deletedAt" IS NULL

-- After
SELECT "album"."id" AS "album_id"
FROM "albums" "album"
    LEFT JOIN "albums_shared_users_users" "album_sharedUsers"
        ON "album_sharedUsers"."albumsId"="album"."id"
    LEFT JOIN "users" "sharedUsers"
        ON "sharedUsers"."id"="album_sharedUsers"."usersId"
        AND "sharedUsers"."deletedAt" IS NULL
WHERE
    "album"."id" IN ($1, $2, $3, $4, $5, $6, $7, $8, $9, $10)
    AND "album"."isActivityEnabled" = true
    AND (
        "album"."ownerId" = $11
        OR "sharedUsers"."id" = $12
    )
    AND "album"."deletedAt" IS NULL
```

* asset.checkAlbumAccess

```sql
-- Before
SELECT
    "asset"."id" AS "assetId",
    "asset"."livePhotoVideoId" AS "livePhotoVideoId"
FROM "albums" "album"
    INNER JOIN "albums_assets_assets" "album_asset"
        ON "album_asset"."albumsId"="album"."id"
    INNER JOIN "assets" "asset"
        ON "asset"."id"="album_asset"."assetsId"
        AND "asset"."deletedAt" IS NULL
    LEFT JOIN "albums_shared_users_users" "album_sharedUsers"
        ON "album_sharedUsers"."albumsId"="album"."id"
    LEFT JOIN "users" "sharedUsers"
        ON "sharedUsers"."id"="album_sharedUsers"."usersId"
        AND "sharedUsers"."deletedAt" IS NULL
WHERE
    (
        "album"."ownerId" = $1
        OR "sharedUsers"."id" = $2
    )
    AND (
        "asset"."id" IN ($3, $4, $5, $6, $7, $8, $9, $10, $11, $12)
        OR "asset"."livePhotoVideoId" IN ($13, $14, $15, $16, $17, $18, $19, $20, $21, $22)
    )
    AND "album"."deletedAt" IS NULL

-- After
WITH "assetIds" AS (
    SELECT unnest(array[$1, $2, $3, $4, $5, $6, $7, $8, $9, $10])::uuid AS "id"
    FROM (SELECT 1 AS dummy_column) "dummy_table"
)
SELECT
    "asset"."id" AS "assetId",
    "asset"."livePhotoVideoId" AS "livePhotoVideoId"
FROM "albums" "album"
    INNER JOIN "albums_assets_assets" "album_asset"
        ON "album_asset"."albumsId"="album"."id"
    INNER JOIN "assets" "asset"
        ON "asset"."id"="album_asset"."assetsId"
        AND "asset"."deletedAt" IS NULL
    LEFT JOIN "albums_shared_users_users" "album_sharedUsers"
        ON "album_sharedUsers"."albumsId"="album"."id"
    LEFT JOIN "users" "sharedUsers"
        ON "sharedUsers"."id"="album_sharedUsers"."usersId"
        AND "sharedUsers"."deletedAt" IS NULL
WHERE
    (
        "album"."ownerId" = $11
        OR "sharedUsers"."id" = $12
    )
    AND (
        "asset"."id" IN (SELECT id FROM "assetIds")
        OR "asset"."livePhotoVideoId" IN (SELECT id FROM "assetIds")
    )
    AND "album"."deletedAt" IS NULL
```

* asset.checkSharedLinkAccess

```sql
-- Before
SELECT
    "assets"."id" AS "assetId",
    "assets"."livePhotoVideoId" AS "assetLivePhotoVideoId",
    "albumAssets"."id" AS "albumAssetId",
    "albumAssets"."livePhotoVideoId" AS "albumAssetLivePhotoVideoId"
FROM "shared_links" "sharedLink"
    LEFT JOIN "albums" "album"
        ON "album"."id"="sharedLink"."albumId"
        AND "album"."deletedAt" IS NULL
    LEFT JOIN "shared_link__asset" "assets_sharedLink"
        ON "assets_sharedLink"."sharedLinksId"="sharedLink"."id"
    LEFT JOIN "assets" "assets"
        ON "assets"."id"="assets_sharedLink"."assetsId"
        AND "assets"."deletedAt" IS NULL
    LEFT JOIN "albums_assets_assets" "album_albumAssets"
        ON "album_albumAssets"."albumsId"="album"."id"
    LEFT JOIN "assets" "albumAssets"
        ON "albumAssets"."id"="album_albumAssets"."assetsId"
        AND "albumAssets"."deletedAt" IS NULL
WHERE
    "sharedLink"."id" = $1
    AND (
        "assets"."id" IN ($2, $3, $4, $5, $6, $7, $8, $9, $10, $11)
        OR "albumAssets"."id" IN ($12, $13, $14, $15, $16, $17, $18, $19, $20, $21)
        OR "assets"."livePhotoVideoId" IN ($22, $23, $24, $25, $26, $27, $28, $29, $30, $31)
        OR "albumAssets"."livePhotoVideoId" IN ($32, $33, $34, $35, $36, $37, $38, $39, $40, $41)
    )

-- After
WITH "assetIds" AS (
    SELECT unnest(array[$1, $2, $3, $4, $5, $6, $7, $8, $9, $10])::uuid AS "id"
    FROM (SELECT 1 AS dummy_column) "dummy_table"
)
SELECT
    "assets"."id" AS "assetId",
    "assets"."livePhotoVideoId" AS "assetLivePhotoVideoId",
    "albumAssets"."id" AS "albumAssetId",
    "albumAssets"."livePhotoVideoId" AS "albumAssetLivePhotoVideoId"
FROM "shared_links" "sharedLink"
    LEFT JOIN "albums" "album"
        ON "album"."id"="sharedLink"."albumId"
        AND "album"."deletedAt" IS NULL
    LEFT JOIN "shared_link__asset" "assets_sharedLink"
        ON "assets_sharedLink"."sharedLinksId"="sharedLink"."id"
    LEFT JOIN "assets" "assets"
        ON "assets"."id"="assets_sharedLink"."assetsId"
        AND "assets"."deletedAt" IS NULL
    LEFT JOIN "albums_assets_assets" "album_albumAssets"
        ON "album_albumAssets"."albumsId"="album"."id"
    LEFT JOIN "assets" "albumAssets"
        ON "albumAssets"."id"="album_albumAssets"."assetsId"
        AND "albumAssets"."deletedAt" IS NULL
    WHERE
        "sharedLink"."id" = $11
        AND (
            "assets"."id" IN (SELECT id FROM "assetIds")
            OR "albumAssets"."id" IN (SELECT id FROM "assetIds")
            OR "assets"."livePhotoVideoId" IN (SELECT id FROM "assetIds")
            OR "albumAssets"."livePhotoVideoId" IN (SELECT id FROM "assetIds")
        )
```

* fix: Use array overlapping instead of CTEs
2023-12-27 23:50:54 -06:00
renovate[bot]
4fff2c75aa
chore(deps): update base-image to v20231221 (#6029)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-12-27 23:47:27 -06:00
Mert
a1e1f11399
feat(server): delete unnecessary encoded videos (#6027)
* delete unnecessary transcodes

* added test
2023-12-27 23:34:00 -06:00
Mert
8119d4bb26
chore(server): refactor locks (#5953)
* lock refactor

* add mocks

* add await

* move database repo injection to service

* update tests

* add mock implementation

* remove unused imports

* this
2023-12-27 18:36:51 -05:00
Thomas
c0ebc943d2
fix(server): strip metadata from thumbnails (#4438)
included all thumbnail metadata. It seems this has to be explicitly disabled.

Refs: #4382

feat. basic metadata e2e test

fix: use tiff thumbnails in first step + e2e fix

fix: revert switch to tiff

feat: test metadata of both webp and jpg

feat: use upload in e2e test

fix: lint

strip metadata with exiftool

use `withIccProfile`

fix e2e

formatting

run jobs in e2e
2023-12-26 16:27:51 -05:00
Daniel Dietzler
8fdd3aaed1
fix(server): init library scanning on start up (#5951) 2023-12-23 20:46:42 +00:00
Alex
e47e25e671
fix(server): access system config before database migration complete (#5912) 2023-12-21 12:52:49 -06:00
Mert
cc2dc12f6c
fix(server): run migrations after database checks (#5832)
* run migrations after checks

* optional migrations

* only run checks in server and e2e

* re-add migrations for microservices

* refactor

* move e2e init

* remove assert from migration

* update providers

* update microservices app service

* fixed logging

* refactored version check, added unit tests

* more version tests

* don't use mocks for sut

* refactor tests

* suggest image only if postgres is 14, 15 or 16

* review suggestions

* fixed regexp escape

* fix typing

* update migration
2023-12-21 10:06:26 -06:00
Mert
f602295bf9
chore(dev): move envs to image (#5906) 2023-12-21 09:28:23 -06:00
Mert
092a23fd7f
feat(server,ml): remove image tagging (#5903)
* remove image tagging

* updated lock

* fixed tests, improved logging

* be nice

* fixed tests
2023-12-20 20:47:56 -05:00
martin
7e216809f3
fix(server): remove shared link with removed asset (#5845) 2023-12-19 11:05:18 -06:00
Mohamed BOUSSAID
234449f3c6
fix(server, web): Prevent the user from setting a future date of birth (#5803)
* Hide the person age if it is negative

* Add validation to prevent future birth dates

* Add comment

* Add test, Add birth date validation and update birth date modal

* Add birthDate validation in PersonService and SetBirthDateModal

* Running npm run format:fix

* Generating the migration file propoerly, and Make the birthdate form logic simpler

* Make birthDate type only string

* Adding useLocationPin back
2023-12-19 10:07:38 -06:00
Alex The Bot
b40859551b Version v1.91.4 2023-12-19 03:34:19 +00:00