process handling functions