Book library management platform which goal is to enable libraries to share information about their book collections with customers.
- Java
- Spring Framework - platform that provides comprehensive infrastructure support for developing Java applications
- Apache Maven - project management and comprehension tool
- H2 Database Engine - Java SQL database, in-memory databases
- Project Lombok - Java library for automatically complement boilerplate code
- Mapstruct - code generator that simplifies the implementation of mappings
- Guava - set of core Java libraries from Google, Guava Cache was especially used
- JUnit 5 - testing framework
Build the application, deploy it and run tests.
mvn deploy
Run application
java -jar target/book-library-0.0.1-SNAPSHOT.jar
Run application with given dataset
java -jar target/book-library-0.0.1-SNAPSHOT.jar [path-to-file]
Returns a book identified by the given ISBN number in the form of a JSON document. Returns a 404 if the book does not exist in the data set.
GET: /api/books/by-isbn/{isbn}
Returns a list of all books that are assigned to the requested category.
GET: /api/books/by-category/{category}
Returns first book, which number of pages is greater than specified value.
GET: /api/books/pages-greater-than/{pages}
Returns JSON document with a list of the best rated books which can be read in month. User can specify the number of pages he can read per hour and average number of hours he spends on reading during the day.
GET: /api/books/best-books/{howManyPages}/{howManyHours}
Returns JSON document with a list of 5 books recently viewed via details endpoint (described previously).
GET: /api/books/recently-viewed
Returns JSON document with a list of all authors and their rating in descending order of the average rating of their books.
GET: /api/authors/ratings