beginning of paginator and small refactoring
begining of paginator
stress test