Meelo icon indicating copy to clipboard operation
Meelo copied to clipboard

Scanner Microservice

Open Arthi-chaud opened this issue 1 year ago • 0 comments

Scanning for files and processing images requires a lot of CPU (open file, parse metadata, extract illustrations, compute blurhash, etc...)

There should be a microservice dedicated to this feature:

  • [ ] We can start scan through an endpoint
    • [ ] By default, scanning considers all libraries
    • [ ] Scan can be library-specific
  • [ ] We can start a cleaning task through an endpoint
    • [ ] By default, cleaning considers all libraries
    • [ ] Cleaning can be library-specific
  • [ ] We can refresh files' metadata task through an endpoint
    • [ ] By default, refreshing is library specific
    • [ ] Refreshing can be album-specific
    • [ ] Refreshing can be release-specific
    • [ ] Refreshing can be song-specific
    • [ ] Refreshing can be track-specific
  • [ ] Tasks cannot run in parallel
  • [ ] We should be able to get the status (i.e. the currently running task) through an endpoint
  • [x] A Swagger should be present

The Server/API should expose routes dedicated to the scanner:

  • [ ] Delete a File
    • [ ] It should take a query parameter to trigger (or not) a housekeeping task
  • [ ] Add a File
  • [ ] Get all files
  • [ ] Get a release's illustrations
  • [ ] Post an illustration
  • [ ] Post a thumbnail
  • [ ] These routes should be protected, and only accessible by the scanner

  • [x] Find the language to implement the microservice
  • [x] Investigate whether ffprobe could be a good candidate to replace the music-metadata library

Roadmap

  • [x] Setup Project
  • [x] Connect to API
  • [x] Read settings.json
  • [x] Get Metadata from Path
  • [x] Get Metadata from Embedded Data
  • [ ] Know if a file has already been registered

Arthi-chaud avatar Jun 18 '24 07:06 Arthi-chaud