Skip to content

User interaction with solution

Piotr Tylczyński edited this page Aug 26, 2021 · 1 revision

Simple path

  1. Login
  2. Go to search tab and choose some movie to display
  3. Type address of youtube movie into search bar
  4. As download ends go to queue tab
  5. Choose which movie to display

Real path

Login

There are two ways of login into system. Form login which we use for frontend. Each user with access to front have ultimate access to all /api/** endpoint. On the other hand we have Basic authentication. This method is used for backend. Users able to authenticate in this way cannot use any of Vaadin endpoint - cannot use UI

Search tab / download movie

As implementation shows, downloading YT movies is far more efficient than restriming it. This is because restriming assumes that youtube service will work flawless. Which is not true in most of a cases. For example youtube will try to block users that seems to roboty, which is quite hard to hide, especially that our project is rather about displaying not breaking youtube algorithms.

Downloaded videos can be further resized to any dimensions ordered by user. Not only to one given by youtube. This practice is used mainly by display client, and may seem to be redundant for human users.

Choosing movie

In this stage user will RMB one of movies and choose proper option to display movie. If he/she do so, POV Server will send via MQ special ping to display with information which moview was chosen. More information about protocol can be found in section MQ Communication. Then POV Client will make GET /api/video/{id} for non-resized video or GET /api/video/resize/{id}?width=<width>?height=<height> and streaming will begin. ofcourse each GET should have proper headers and have authorization information in it - look loigin section of this document.

Sample API model of POV Server can be found in pov-server repository as Postman collection

Clone this wiki locally