I don’t think you’d need queue mode here based on the description. Does your PostgreSQL data have a numeric ID or another column you can use to order and paginate through?
If so, you could simply use an approach as suggested over here to only process your data in chunks.