cleaned code
updated buffer management
buffer pool test implementation