added flow processing