a. Does Firefox get killed when the time period expires to force an update?
Yes: When the timer reaches zero, snapd will terminate (kill) Firefox and then refresh (update) the snap. Any unsaved work will be lost when the application is terminated.
The notification is intended to be a better alternative. You can select the time to Quit Firefox on your own schedule and at a convenient place in your workflow.
- Keep in mind that after Quitting Firefox, you must ALSO run
sudo snap refresh
, and wait for the command to complete before restarting Firefox.
b. If so, how can this be prevented?
You cannot prevent snapd from terminating Firefox. Snaps MUST update -- it's a key feature of snaps from their beginning. Automatic, frequent updates are one of the reasons that Mozilla selected snaps to be their primary package for delivering Firefox.
Snaps originated in phones and devices that must update automatically and reliably without user intervention, and preferably without the user even noticing. The expansion of snap packages into desktop systems is much newer, and there are indeed some teething troubles with snaps for long-lived desktop applications (like Firefox).
Both Mozilla and Canonical engineers continue to work on those bugs. The refresh experience will get better.