Like mysql, you can add a long-type redundant field, incrementing each time, so that you can solve the problem that the mongo primary key is of type ObjectId;
You can use paging to do it, but you may need to record how much data has been fetched in previous segments. If the same amount of data is fetched in each segment, it is more suitable for paging.