Background information for data providers

From TV-Browser Wiki
Revision as of 09:55, 1 May 2009 by Jo (talk | contribs) (New page: This article contains background information on the topic Providing TV listings with a Primary Data Service. == Get and prepare raw data == The tool '' PDSRunner'' starts the par...)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

This article contains background information on the topic Providing TV listings with a Primary Data Service.

Get and prepare raw data

The tool PDSRunner starts the parsers which fetch the program data from the channels and converts the data in a TV-Browser specific format. These data files are stored in the raw directory.

Create diff files

The tool PrimaryDataManager looks for differences between the new data in the raw directory and the already existing data in the prepared directory. If differences are found the tool creates update files.

To keep the traffic for data providers low, the data is divided into different files:

  • "base" contains time, title and data as actors etc.
  • "more00-16" contains the descriptions for programs between 0.00 and 16.00
  • "more16-00" contains the descriptions for programs between 16.00 and
  • "picture00-16" contains die Bilder for programs between 0.00 and 16.00
  • "picture16-00" contains die Bilder for programs between 16.00 and 0.00
  • For days with > 255 programs there are also "additional" files

The only alway required file is "base".

Each program gets an ID to assign the entry in the "base" file with the correct entries in the "more" and "picture" files. The ID's are also necessary to keep the data consistent in the "update" files.

Update files

On the first run "full" files are created. If the PrimaryDataManager finds changes in the data, it creates "update" files as needed. These update files contain the ID of the program and the new data. The changes will also be written into previous update files and the first "full" version.

Upload the data

The tool MirrorUpdater loads the files and some additional information onto the mirrors.