1. Refactored LibraryController to make the source code more compact and easier to read
2. Added exception-classes that are mapped to corresponding http-status codes
3. Added a test suite for the LibraryController verifying both happy days and error scenarios