-
-
Notifications
You must be signed in to change notification settings - Fork 519
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Maximum days of events to keep is not working (no events are removed) #844
Comments
Hi @BetweenTheKeyboardAndChair , I've been analyzing this issue, and I've found a solution. I'll test it for a couple of days to see if there's any downside. The problem is how QsqlDatabase works from different threads:
In order to access a database from different threads you create a new QsqlDatabase connection to the DB specifying the DB name/file. But with in-memory databases, whenever you create a new connection with |
In 5b5e271 we added support for in-memory cached DB, to allow delete old events from memory (#844). Unfortunately, on some systems this URI (file::memory:?cache=shared) creates a file on disk on user's home. This file is in the end a DB, so if users want to delete old events, they'll have to save events to disk. On the other hand, when in-memory DB is selected, we now disable the option to delete old events from memory. Closes #857
Bug: Old events are not being removed from the events UI tab.
The UI setting preferences for the database are:
Database type: In memory
System info: Ubuntu 20.04.1 LTS (focal), ucin 5.4.0-135-generic
opensnitch/now 1.6.0-rc.4-1 amd64 [installed,local]
python3-opensnitch-ui/now 1.6.0-rc.4-1 all [installed,local]
protobuf: 3.6.1
grpc: 1.37.1
To Reproduce
Start opensnitch and the UI, and let it run. No events have been removed since the process was started 2 weeks ago. i.e. If I reverse sort events by time on the events tab, I see events from 1/26/22.
The text was updated successfully, but these errors were encountered: