mongodb persistence functional