Database: Refactor MP1 database for multi seat usage (4 Viewers)

ajs

Development Group
  • Team MediaPortal
  • February 29, 2008
    15,492
    10,371
    Kyiv
    Home Country
    Ukraine Ukraine
    I am storing the IMDBUrl object in the database. So, it should be unique.
    For Test, make initial scan all movies with IMDB grabber, then Delete this grabber and set TI_MDB or TMDB grabber and try rescan :)
    The search is handled by the grabber, did you change his call? And did you change all the robbers? Or?
     

    Anthony Vaughan

    MP Donator
  • Premium Supporter
  • June 25, 2015
    566
    292
    Home Country
    United Kingdom United Kingdom
    Provided that the structure of the site, grabber, API, etc. is not changed.
    This is the code that gets actor details in IMDB.cs:

    public bool GetActorDetails(IMDBUrl url, out IMDBActor actor, bool pFetchActorInfo)
    {
    actor = new IMDBActor();

    int pos = url.URL.LastIndexOf("nm");
    string id = url.URL.Substring(pos, 9).Replace("/", string.Empty);

    Log.Debug("IMDB: GetActorDetails: start id: {0}", id);

    try
    {
    if (pFetchActorInfo || !VideoDatabase.HasActorByIMDBActorID(id))
    {
    if (InternalActorsScriptGrabber.InternalActorsGrabber.GetActorDetails(url, out actor))
    {
    // Add filmography
    if (actor.Count > 0)
    {
    actor.SortActorMoviesByYear();
    }

    return true;
    }
    }
    }
    catch (Exception ex)
    {
    Log.Error("IMDB GetActorDetails Error: {0}", ex.Message);
    }
    return false;
    }

    It uses IMDBUrl as the search parameter to get actor details in InternalActorMoviesGrabber.csscript. That's why I store it for fast fetch refreshes.

    I don't see what's wrong with that and, besides, this method is optional. If you want to do a full search every time then don't select Fast Fetch.
     

    Anthony Vaughan

    MP Donator
  • Premium Supporter
  • June 25, 2015
    566
    292
    Home Country
    United Kingdom United Kingdom
    Its not URL its IMDB ID
    The first parameter of the GetActorDetails method is IMDBUrl which is a class including url. This is the class that the internal actor grabber uses to get actor details; using the url.URL and url.Title. Here's an example of what I am storing:

    1637002897445.png


    In this case the url seems to be a TMDBID.

    All I am doing is to store this information - what you chose when you did your first search on a movie - so that you can, optionally, avoid having to re-select the title if you don't want to change the source when doing a refresh. It makes refreshing your data much faster and needs only one click - which makes a massive difference when you are refreshing a lot of movies.

    I'm just not seeing the issue.
     

    ajs

    Development Group
  • Team MediaPortal
  • February 29, 2008
    15,492
    10,371
    Kyiv
    Home Country
    Ukraine Ukraine
    In this case the url seems to be a TMDBID.
    How will it work if this grabber is not there? If it doesn't work? If there are 3 grabbers in the settings and at the time of scanning we received information from the grabber that gives back the worst information?
     

    ajs

    Development Group
  • Team MediaPortal
  • February 29, 2008
    15,492
    10,371
    Kyiv
    Home Country
    Ukraine Ukraine
    All I am doing is to store this information - what you chose when you did your first search on a movie - so that you can
    In fact, this is unnecessary information and there is no point in storing it in the database, there is an IMDB ID and the name of the movie, by IMDB ID almost all grabbers uniquely identify the movie, if there is no IMDB ID, they look at the title. You just have not met with the movies that are not in the database IMDB, TMDB and are only in the database Kinopoisk, but there such a scheme with stored ID does not always work.
     

    Users who are viewing this thread

    Top Bottom