Fixes various compiler and IntelliJ warnings
Move Exception handling to ControllerAdvice class
Fix DocumentResource test
Fix RelationResource test
Merge branch 'cleanup'