Better import #25

Open
opened 2026-04-08 18:10:59 +02:00 by jkuhl · 2 comments
Owner

Significant time during the import is wasted with compressing and decompressing the final json file. We should determine beforehand, which files will be affected by the import of each measurement, such that we can use temporary files during the import process and only write the full files once all measurements that affect them.

  • implement a function that determines all files affected by import of a measurement
  • read out the affected files in order
  • at the end of the import of a measurement, write only the files that will not be affected any more
  • if file/dict will still be affected, hold in memory
  • write affected files into extra table
  • implement function to look up affected files in the table
  • write re-import for measurements in affected files in case of update

In which the last three would solve #30

Significant time during the import is wasted with compressing and decompressing the final json file. We should determine beforehand, which files will be affected by the import of each measurement, such that we can use temporary files during the import process and only write the full files once all measurements that affect them. - [x] implement a function that determines all files affected by import of a measurement - [x] read out the affected files in order - [ ] at the end of the import of a measurement, write only the files that will not be affected any more - [ ] if file/dict will still be affected, hold in memory - [ ] write affected files into extra table - [ ] implement function to look up affected files in the table - [ ] write re-import for measurements in affected files in case of update In which the last three would solve #30
Author
Owner

Either we keep the data as a dict until we write, otherwise we use
https://docs.python.org/3/library/tempfile.html#tempfile.TemporaryFile

Either we keep the data as a dict until we write, otherwise we use https://docs.python.org/3/library/tempfile.html#tempfile.TemporaryFile
Author
Owner

The link between the parameters from the toml file and the records should be made through SQLs FOREIGN_KEYs

The link between the parameters from the toml file and the records should be made through SQLs FOREIGN_KEYs
Sign in to join this conversation.
No labels
bug
enhancement
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
jkuhl/corrlib#25
No description provided.