when a request downloads data beyond the max content limit, open 1 alert at most.
Also refactored alert management code.