backend_localfile should save tasks after time interval instead of modification
Bug #907676 reported by
Izidor Matušov
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
GTG |
Fix Released
|
Medium
|
Diego Garcia Gangl |
Bug Description
Right now, backend_localfile is saving its XML right after modification. It would make more sense to save XML after certain time interval after the last modification.
Use case:
When starting GTG, every time a task is modified, XML is saved. Because modified signal is quite often sent, GTG spends much time on saving a file what is slow unless you own SSD disk.
Instead of that, it could run a timer, e.g. 30-second timer. Everytime a task is modified, timer is reset. When there is no modification and timer finish, save the changes.
It should be a huge performance improvement.
Related branches
lp:~huxuan/gtg/bug-907676
Rejected
for merging
into
lp:~gtg/gtg/old-trunk
- Izidor Matušov: Disapprove
- Xuan (Sean) Hu (community): Needs Resubmitting
-
Diff: 97 lines (+30/-7)2 files modifiedGTG/backends/backend_localfile.py (+28/-7)
GTG/tests/test_backends.py (+2/-0)
Changed in gtg: | |
assignee: | nobody → Xuan Hu (huxuan) |
Changed in gtg: | |
assignee: | nobody → Narendra Joshi (narendraj9) |
Changed in gtg: | |
status: | Confirmed → Fix Committed |
assignee: | Narendra Joshi (narendraj9) → Diego Garcia Gangl (dnicolas) |
Changed in gtg: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
Even better would be to use an scalable backend like SQLite instead of using XML as a database.