how to run:
- sbt run
Link to the app on heroku: https://ask-movie-app.herokuapp.com/
What does this app contain:
- Play Framework web app written in Scala
- Single search box form
- Gets a movie from a third-party service
- Parses the movie plot and uses randomly as Search Terms to produce up to 10 related movies
- Creates links to the related movies as search terms for the next search
- Movies are distinct and so are the search terms
What did I try to show:
- Inheritance through Trait
- Passing a function as an argument
- Usage of Objects
- Pattern matching
- Chaining operations on collections
- Usage of Futures
- Getting data from a third-party service
- Reading json response into class
- Follow MVC
- Implement a recursive function
- Strict immutable (val)
- Use implicit
- Utilize java libraries
Things to improve:
- Refactoring code out of the Search Controller class
- Write unit tests
- Add test coverage plugin to make sure the coverage is good
- Styling to the pages
- Configuration:
- The secret code for production shouldn't be stored in application.config
- The API key for the movie database service should be store differently
- Probably not all referers should be allowed to the app
- Implement the sevice to fill up 10 movies in every query or at least exhust some large amount of attemtps
Bugs:
- Some movies although correct search terms end up being a "dead end"
- Improve which characters are removed from the potential search terms (example: Carlito's should keep the ' charecter)