Details
-
Bug
-
Resolution: Fixed
-
Major
-
1.0.2
-
None
Description
After WebEPG or XMLTV has finished grabbing program data, the system may go to sleep before programs get written to the database. When this happens the system may not wake up for recordings because EPG data for these scheduler is not yet available before the sleep. The system will then wake up again for the next EPG grab.
h4. Additional Information
Because the actual writing to the database occurs in a separate thread AFTER WebEPG/XMLTV finishes it's import, it does not prevent the system from going to sleep. So it often happens that the system goes to sleep during writing to the database, leaving the EPG half populated.
Also WebEPG will insert programs to the database in batches (one for each channel). This complicates things even more.
See: http://forum.team-mediaportal.com/xmltv-137/stay-awake-whilst-loading-epg-73426/
One solution is to have a queue of programs to insert, and a thread that services the queue. Each grabber should queue grabbed programs and wait until the queue is empty before allowing standby. As soon as the queue is empty it can also trigger the UpdateProgramStates() (gibman's tvguide speed up).
h4. Additional Information
Because the actual writing to the database occurs in a separate thread AFTER WebEPG/XMLTV finishes it's import, it does not prevent the system from going to sleep. So it often happens that the system goes to sleep during writing to the database, leaving the EPG half populated.
Also WebEPG will insert programs to the database in batches (one for each channel). This complicates things even more.
See: http://forum.team-mediaportal.com/xmltv-137/stay-awake-whilst-loading-epg-73426/
One solution is to have a queue of programs to insert, and a thread that services the queue. Each grabber should queue grabbed programs and wait until the queue is empty before allowing standby. As soon as the queue is empty it can also trigger the UpdateProgramStates() (gibman's tvguide speed up).