Raven db 2450

This is pull request for both 2450 and 2479.