fix memory leak , batched processing of records by iterating and adding to a list, removed TTL for entity table