Refactor of netflix ingest code