#NEWLINE# @ classmethod #NEWLINE# def purge_quarantine( self ) : #NEWLINE# #INDENT# quarantine_time = Configuration . get_by_name_as_int ( 'quarantine_retention_days' ) #NEWLINE# quarantine_time_dt = ( date . today ( ) - timedelta ( days = quarantine_time ) ) #NEWLINE# databases = Database . objects . filter ( is_in_quarantine = True , quarantine_dt__lte = quarantine_time_dt ) #NEWLINE# for database in databases : #NEWLINE# #INDENT# database . delete ( ) #NEWLINE# LOG . info ( ( 'The database %s was deleted, because it was set to quarentine %d days ago' % ( database . name , quarantine_time ) ) )