Manage resoures properly in InputStreamGraphSource