SageTV Community  

Go Back   SageTV Community > SageTV Development and Customizations > SageTV Customizations
Forum Rules FAQs Community Downloads Today's Posts Search

Notices

SageTV Customizations This forums is for discussing and sharing user-created modifications for the SageTV application created by using the SageTV Studio or through the use of external plugins. Use this forum to discuss customizations for SageTV version 6 and earlier, or for the SageTV3 UI.

Closed Thread
 
Thread Tools Search this Thread Display Modes
  #881  
Old 09-12-2009, 10:23 AM
Skirge01's Avatar
Skirge01 Skirge01 is offline
SageTVaholic
 
Join Date: Jun 2007
Location: New Jersey
Posts: 2,599
Quote:
Originally Posted by Slugger View Post
It's not the 2009_08_xx.request.log file I need from Jetty, it's the 2009_08_xx.stderrout.log file that I need. This will be the file that logs the exceptions that are being thrown. If you are not seeing this file (it's in the same location as the 2009_08_xx.request.log file) then you must enable debug logging in Jetty - see JettyStarter.properties.

While you stop Sage to enable debug logging, also upgrade the SJQ server and task client to the latest versions. Server is snapshot 511 and task client is snapshot 504. Then when you start seeing the HTTP 500 errors again, get the stderrout log and send that to me, please.
Slugger, I went ahead and updated the server and client to the lastest builds. I'm still seeing lots of locking up of the comskip processes which I need to kill off. I'm also needing to restart SJQ via resaving the sjq.context.xml file you mentioned (thanks for that tip, btw), or else nothing else gets queued up. I checked with erik and the hangs are almost definitely caused by comskip, not SJQ. This may be the reason I'm not finding the stderrout files you're requesting.

At this point, I'm having to babysit both SJQ and comskip every time a comskip is due to finish (with 7 instances running in parallel, this is about every 30 minutes), so that I can update the sjq.context.xml file, restart the SJQC services on each client and kill all the hung comskip instances. Obviously, this means that while I'm at work, comskip very likely is not running for that 8-10 hours of the day or while I sleep and can't keep an eye on it. (Darn that whole work/sleep thing! )

Is there any way to get SJQ to know when a comskip instance is hung up, so that it knows to kill it, possibly requeue it, and start another comskip instance? In my, admittedly, extremely limited programming skills, I would think that a periodic check of the recording's log file timestamps would provide the necessary information to know whether it was hung.

EDIT: Through my constant monitoring of the 3 computers, I've found that, when a process is hung, if I stop the SJQC service, the hung process starts up. Then, if I start the service, I believe everything continues normally. I'm not certain of this last part, so I will check to ensure future shows are getting queued on those clients.
__________________
Server: XP, SuperMicro X9SAE-V, i7 3770T, Thermalright Archon SB-E, 32GB Corsair DDR3, 2 x IBM M1015, Corsair HX1000W PSU, CoolerMaster CM Storm Stryker case
Storage: 2 x Addonics 5-in-3 3.5" bays, 1 x Addonics 4-in-1 2.5" bay, 24TB
Client: Windows 7 64-bit, Foxconn G9657MA-8EKRS2H, Core2Duo E6600, Zalman CNPS7500, 2GB Corsair, 320GB, HIS ATI 4650, Antec Fusion
Tuners: 2 x HD-PVR (HTTP tuning), 2 x HDHR, USB-UIRT
Software: SageTV 7

Last edited by Skirge01; 09-13-2009 at 09:32 AM.
  #882  
Old 09-13-2009, 09:53 PM
Slugger Slugger is offline
SageTVaholic
 
Join Date: Mar 2007
Location: Kingston, ON
Posts: 4,008
Quote:
Originally Posted by Skirge01 View Post
Is there any way to get SJQ to know when a comskip instance is hung up, so that it knows to kill it, possibly requeue it, and start another comskip instance? In my, admittedly, extremely limited programming skills, I would think that a periodic check of the recording's log file timestamps would provide the necessary information to know whether it was hung.
Check out the MAXRUNRATIO setting in the user guide. That should do exactly what you're looking for.
__________________
Twitter: @ddb_db
Server: Intel i5-4570 Quad Core, 16GB RAM, 1 x 128GB OS SSD (Win7 Pro x64 SP1), 1 x 2TB media drive
Capture: 2 x Colossus
STB Controller: 1 x USB-UIRT
Software:Java 1.7.0_71; SageTV 7.1.9
Clients: 1 x HD300, 2 x HD200, 1 x SageClient, 1 x PlaceShifter
Plugins: Too many to list now...
  #883  
Old 09-14-2009, 09:51 AM
Skirge01's Avatar
Skirge01 Skirge01 is offline
SageTVaholic
 
Join Date: Jun 2007
Location: New Jersey
Posts: 2,599
Thanks for that tip! That does seem to have resolved the issue of hung processes. They do appear to be ending at this point.

However, the clients seem to simply stop running anything and I need to "update" the sjq.context.xml file, followed by stopping and restarting the service on both the server (also a client) and a 2nd client PC, before any more comskip sessions will be started. (For unrelated reasons, I stopped using the 3rd computer for comskip at the moment.) To date, I still have yet to find one of those stderr log files you mentioned. I expected to find it on the server, but also checked the client log folder, just to be sure. Do I need to stop the Sage service in order for the true setting on the debug flag to take effect?
__________________
Server: XP, SuperMicro X9SAE-V, i7 3770T, Thermalright Archon SB-E, 32GB Corsair DDR3, 2 x IBM M1015, Corsair HX1000W PSU, CoolerMaster CM Storm Stryker case
Storage: 2 x Addonics 5-in-3 3.5" bays, 1 x Addonics 4-in-1 2.5" bay, 24TB
Client: Windows 7 64-bit, Foxconn G9657MA-8EKRS2H, Core2Duo E6600, Zalman CNPS7500, 2GB Corsair, 320GB, HIS ATI 4650, Antec Fusion
Tuners: 2 x HD-PVR (HTTP tuning), 2 x HDHR, USB-UIRT
Software: SageTV 7
  #884  
Old 09-14-2009, 10:51 AM
Slugger Slugger is offline
SageTVaholic
 
Join Date: Mar 2007
Location: Kingston, ON
Posts: 4,008
Yes, Jetty would have to be restarted for the debug flag to take effect and to restart Jetty requires a stop/restart of Sage.
__________________
Twitter: @ddb_db
Server: Intel i5-4570 Quad Core, 16GB RAM, 1 x 128GB OS SSD (Win7 Pro x64 SP1), 1 x 2TB media drive
Capture: 2 x Colossus
STB Controller: 1 x USB-UIRT
Software:Java 1.7.0_71; SageTV 7.1.9
Clients: 1 x HD300, 2 x HD200, 1 x SageClient, 1 x PlaceShifter
Plugins: Too many to list now...
  #885  
Old 09-14-2009, 11:10 AM
Skirge01's Avatar
Skirge01 Skirge01 is offline
SageTVaholic
 
Join Date: Jun 2007
Location: New Jersey
Posts: 2,599
Thanks, Slugger. Sorry for these seemingly dumb questions. I don't know how you put up with us! But, we sure do appreciate that you do!!!
__________________
Server: XP, SuperMicro X9SAE-V, i7 3770T, Thermalright Archon SB-E, 32GB Corsair DDR3, 2 x IBM M1015, Corsair HX1000W PSU, CoolerMaster CM Storm Stryker case
Storage: 2 x Addonics 5-in-3 3.5" bays, 1 x Addonics 4-in-1 2.5" bay, 24TB
Client: Windows 7 64-bit, Foxconn G9657MA-8EKRS2H, Core2Duo E6600, Zalman CNPS7500, 2GB Corsair, 320GB, HIS ATI 4650, Antec Fusion
Tuners: 2 x HD-PVR (HTTP tuning), 2 x HDHR, USB-UIRT
Software: SageTV 7
  #886  
Old 09-14-2009, 03:47 PM
Skirge01's Avatar
Skirge01 Skirge01 is offline
SageTVaholic
 
Join Date: Jun 2007
Location: New Jersey
Posts: 2,599
I did some more checking and here's what my jettystarter.properties file says (in part, obviously):

Quote:
# jetty.logs only contains logs of requests to the Jetty server.
jetty.logs=$(jetty.home)/logs

# Uncomment to get more detailed logging from Jetty. Output is written to the standard
# output stream (by default, sagetv_0.txt).
DEBUG=true
I thought the second part was what would be giving me the stderr logs, but according to the comment, these debug logs will go to the default Sage log file. Is this what you're talking about or am I even more confused than I thought?
__________________
Server: XP, SuperMicro X9SAE-V, i7 3770T, Thermalright Archon SB-E, 32GB Corsair DDR3, 2 x IBM M1015, Corsair HX1000W PSU, CoolerMaster CM Storm Stryker case
Storage: 2 x Addonics 5-in-3 3.5" bays, 1 x Addonics 4-in-1 2.5" bay, 24TB
Client: Windows 7 64-bit, Foxconn G9657MA-8EKRS2H, Core2Duo E6600, Zalman CNPS7500, 2GB Corsair, 320GB, HIS ATI 4650, Antec Fusion
Tuners: 2 x HD-PVR (HTTP tuning), 2 x HDHR, USB-UIRT
Software: SageTV 7
  #887  
Old 09-14-2009, 03:54 PM
Slugger Slugger is offline
SageTVaholic
 
Join Date: Mar 2007
Location: Kingston, ON
Posts: 4,008
Right above that section add the $(jetty.home)/etc/jetty-logging.xml file to jetty.configfiles
__________________
Twitter: @ddb_db
Server: Intel i5-4570 Quad Core, 16GB RAM, 1 x 128GB OS SSD (Win7 Pro x64 SP1), 1 x 2TB media drive
Capture: 2 x Colossus
STB Controller: 1 x USB-UIRT
Software:Java 1.7.0_71; SageTV 7.1.9
Clients: 1 x HD300, 2 x HD200, 1 x SageClient, 1 x PlaceShifter
Plugins: Too many to list now...

Last edited by Slugger; 09-14-2009 at 03:55 PM. Reason: typo
  #888  
Old 09-14-2009, 04:16 PM
Skirge01's Avatar
Skirge01 Skirge01 is offline
SageTVaholic
 
Join Date: Jun 2007
Location: New Jersey
Posts: 2,599
Based on that, I made the following change to jettystarter.properties:

Quote:
###########################
### Configuration Files ###
###########################

# The set of files used to configure Jetty. If a file has spaces in its path,
# it must be enclosed in double quotes.
# - jetty.xml sets up a non-SSL server with hot-deployment of web applications
# - jetty-ssl.xml adds an SSL server
#jetty.configfiles="$(jetty.home)/etc/jetty.xml"
jetty.configfiles="$(jetty.home)/etc/jetty.xml" "$(jetty.home)/etc/jetty-ssl.xml"
jetty.configfiles="$(jetty.home)/etc/jetty-logging.xml"
That's all I need to do? I assume I also need to restart Sage, but I was talking about editing any other files.
__________________
Server: XP, SuperMicro X9SAE-V, i7 3770T, Thermalright Archon SB-E, 32GB Corsair DDR3, 2 x IBM M1015, Corsair HX1000W PSU, CoolerMaster CM Storm Stryker case
Storage: 2 x Addonics 5-in-3 3.5" bays, 1 x Addonics 4-in-1 2.5" bay, 24TB
Client: Windows 7 64-bit, Foxconn G9657MA-8EKRS2H, Core2Duo E6600, Zalman CNPS7500, 2GB Corsair, 320GB, HIS ATI 4650, Antec Fusion
Tuners: 2 x HD-PVR (HTTP tuning), 2 x HDHR, USB-UIRT
Software: SageTV 7
  #889  
Old 09-14-2009, 05:24 PM
Slugger Slugger is offline
SageTVaholic
 
Join Date: Mar 2007
Location: Kingston, ON
Posts: 4,008
No, you need to append... here's what mine looks like:

jetty.configfiles="$(jetty.home)/etc/jetty.xml" "$(jetty.home)/etc/jetty-ssl.xml
" "$(jetty.home)/etc/jetty-logging.xml"

Remove the ssl one if you don't need/use the SSL port with Jetty.
__________________
Twitter: @ddb_db
Server: Intel i5-4570 Quad Core, 16GB RAM, 1 x 128GB OS SSD (Win7 Pro x64 SP1), 1 x 2TB media drive
Capture: 2 x Colossus
STB Controller: 1 x USB-UIRT
Software:Java 1.7.0_71; SageTV 7.1.9
Clients: 1 x HD300, 2 x HD200, 1 x SageClient, 1 x PlaceShifter
Plugins: Too many to list now...
  #890  
Old 09-14-2009, 05:55 PM
Skirge01's Avatar
Skirge01 Skirge01 is offline
SageTVaholic
 
Join Date: Jun 2007
Location: New Jersey
Posts: 2,599
Thanks. I think I got it now. Sad to say, it shouldn't be long before some errors pop up.
__________________
Server: XP, SuperMicro X9SAE-V, i7 3770T, Thermalright Archon SB-E, 32GB Corsair DDR3, 2 x IBM M1015, Corsair HX1000W PSU, CoolerMaster CM Storm Stryker case
Storage: 2 x Addonics 5-in-3 3.5" bays, 1 x Addonics 4-in-1 2.5" bay, 24TB
Client: Windows 7 64-bit, Foxconn G9657MA-8EKRS2H, Core2Duo E6600, Zalman CNPS7500, 2GB Corsair, 320GB, HIS ATI 4650, Antec Fusion
Tuners: 2 x HD-PVR (HTTP tuning), 2 x HDHR, USB-UIRT
Software: SageTV 7
  #891  
Old 09-14-2009, 08:50 PM
jreichen's Avatar
jreichen jreichen is offline
Sage Icon
 
Join Date: Jul 2004
Posts: 1,192
Keep in mind that since SageTV's core and Jetty both log to Java's standard error (stderr) and standard output (stdout) streams - as opposed to using a logging framework - using jetty-logging.xml will redirect SageTV's logging as well. Plus some of the initial log messages will be written to sagetv_0.txt until Sage starts the Jetty plugin and activates that change in logging configuration.

It's not what I'd consider ideal - I don't know if they can be separated or not. Slugger if you have any suggestions on improving logging I'd be happy to hear them.
__________________
Server: Intel Core i5 760 Quad, Gigabyte GA-H57M-USB3, 4GB RAM, Gigabyte GeForce 210, 120GB SSD (OS), 1TB SATA, HD HomeRun.
Extender: STP-HD300, Harmony 550 Remote,
Netgear MCA1001 Ethernet over Coax.
SageTV: SageTV Server 7.1.8 on Ubuntu Linux 11.04, SageTV Placeshifter for Mac 6.6.2, SageTV Client 7.0.15 for Windows, Linux Placeshifter 7.1.8 on Server and Client
, Java 1.6.
Plugins: Jetty, Nielm's Web Server, Mobile Web Interface.

  #892  
Old 09-15-2009, 04:14 PM
Skirge01's Avatar
Skirge01 Skirge01 is offline
SageTVaholic
 
Join Date: Jun 2007
Location: New Jersey
Posts: 2,599
For a few hours there, I thought simply making that change for the logging had actually fixed the issue with comskip hanging and no new jobs getting queued up. Alas, it didn't last long. I'm attaching that elusive file you've been requesting. Let me know if there's any other information you need. Thanks!
Attached Files
File Type: zip 2009_09_15(1).stderrout.zip (636.3 KB, 128 views)
File Type: zip 2009_09_15(2).stderrout.zip (551.5 KB, 109 views)
__________________
Server: XP, SuperMicro X9SAE-V, i7 3770T, Thermalright Archon SB-E, 32GB Corsair DDR3, 2 x IBM M1015, Corsair HX1000W PSU, CoolerMaster CM Storm Stryker case
Storage: 2 x Addonics 5-in-3 3.5" bays, 1 x Addonics 4-in-1 2.5" bay, 24TB
Client: Windows 7 64-bit, Foxconn G9657MA-8EKRS2H, Core2Duo E6600, Zalman CNPS7500, 2GB Corsair, 320GB, HIS ATI 4650, Antec Fusion
Tuners: 2 x HD-PVR (HTTP tuning), 2 x HDHR, USB-UIRT
Software: SageTV 7
  #893  
Old 09-15-2009, 05:48 PM
Slugger Slugger is offline
SageTVaholic
 
Join Date: Mar 2007
Location: Kingston, ON
Posts: 4,008
Do you have more than one client configured and might they both be running a comskip job simultaneously?

The SJQ database is constantly locked and throwing exceptions, that's the SJQ problem. All the exceptions are a result of trying to log task output back to the db. The first thing I'd try is to disable SJQ from logging task output.

Go to Tools > Edit Settings > SJQ should log task output to the server > No

Save the change. That should alleviate the db locking. The side effect is that command output will not be available on the server. Hopefully that fixes you up (I plan on moving logging out of the database down the road as SQLite just doesn't seem to be able to handle the concurrency all too well).

However, while scanning over the log files, I noticed a lot of NPEs being thrown by SageTV itself:

Code:
java.lang.NullPointerException
	at sage.d.e$66.try(Unknown Source)
	at sage.ax.a(Unknown Source)
	at sage.e.a(Unknown Source)
	at sage.w.e(Unknown Source)
	at sage.w.d(Unknown Source)
	at sage.w.access$100(Unknown Source)
	at sage.w$3.run(Unknown Source)
	at sage.cs$a.run(Unknown Source)
sage.a.e: Error in method reflection of IsFilePath of java.lang.NullPointerException
	at sage.ax.a(Unknown Source)
	at sage.e.a(Unknown Source)
	at sage.w.e(Unknown Source)
	at sage.w.d(Unknown Source)
	at sage.w.access$100(Unknown Source)
	at sage.w$3.run(Unknown Source)
	at sage.cs$a.run(Unknown Source)
Caused by: java.lang.NullPointerException
	at sage.d.e$66.try(Unknown Source)
	... 7 more
I can only speculate (b/c of the obfuscated stack traces), but it would seem Sage is having troubles accessing a path on your system. Now if that's the case then API calls might be taking an unusual amount of time (I don't know how long it is before Sage actually throws this NPE), and depending on exactly what's going on, say a file check in SJQ or the file cleaner in SJQ, etc. then this could be the reason the sjq db file is being locked for such a long period of time and then the reason why SJQ is failing. As I say, it's pure speculation only, but I've got a gut feeling these Sage exceptions are at least partly to blame for why SJQ is struggling. However, start with disabling sjq from logging task output and see what that gets you. Next step might be to contact Sage support about the NPEs Sage is throwing.
__________________
Twitter: @ddb_db
Server: Intel i5-4570 Quad Core, 16GB RAM, 1 x 128GB OS SSD (Win7 Pro x64 SP1), 1 x 2TB media drive
Capture: 2 x Colossus
STB Controller: 1 x USB-UIRT
Software:Java 1.7.0_71; SageTV 7.1.9
Clients: 1 x HD300, 2 x HD200, 1 x SageClient, 1 x PlaceShifter
Plugins: Too many to list now...
  #894  
Old 09-15-2009, 08:16 PM
Skirge01's Avatar
Skirge01 Skirge01 is offline
SageTVaholic
 
Join Date: Jun 2007
Location: New Jersey
Posts: 2,599
Thanks for the tips, Slugger. I have 2 clients (one on the server itself and a separate PC). I've disabled the logging piece you mentioned. Regarding the NPE's, I took a look at the sage log and noticed this line showing up for just about every NPE I could find:

Quote:
Tue 9/15 17:10:24.951 [AWT-EventQueue-0@4f459c] EXCEPTION in getValueAsObject:sage.a.e: sage.a.e: Error in method reflection of IsFilePath of java.lang.NullPointerException for:IsFilePath(phoenix_api_GetFanartBackground(Airing))
I'm wondering if upgrading BMT would alleviate this particular issue. I'm still running a very old version (pre-webGUI version). Phoenix is version 1.36, so maybe that's an old version, too. I'll take a look around and see what else I may need to update.
__________________
Server: XP, SuperMicro X9SAE-V, i7 3770T, Thermalright Archon SB-E, 32GB Corsair DDR3, 2 x IBM M1015, Corsair HX1000W PSU, CoolerMaster CM Storm Stryker case
Storage: 2 x Addonics 5-in-3 3.5" bays, 1 x Addonics 4-in-1 2.5" bay, 24TB
Client: Windows 7 64-bit, Foxconn G9657MA-8EKRS2H, Core2Duo E6600, Zalman CNPS7500, 2GB Corsair, 320GB, HIS ATI 4650, Antec Fusion
Tuners: 2 x HD-PVR (HTTP tuning), 2 x HDHR, USB-UIRT
Software: SageTV 7
  #895  
Old 09-16-2009, 07:52 AM
moothekow moothekow is offline
Sage Advanced User
 
Join Date: Oct 2008
Posts: 88
Ok - I apologized if this has been asked/answered, but I've spent hours searching through the forums and am not sure how to accomplish (or if I can accomplish) what I'm trying to do. Not sure of the things i've read what is old and doesn't apply, etc etc.

What I want to do is fairly simple/straight forward. After a record is finished - I want to move the file into another directory. So - lets say my tv shows record to a directory: 'd:\RecordedTV'. After the recording is finished I want to sort the episode by show/season/episode-name.mpg. So - example:

Go from:
d:\RecordedTV\FilenameSageTVGivesRecording.mpg

To:
d:\SortedTV\TVshowName\Season XX\SXXEXX - EpisodeName.mpg

is this possible? In a perfect world I'd like to still consider it a recorded tv show and all that fun jazz... but if it meant I could only get to it via the 'media center' videos area I could probably live with that.

Thanks.
  #896  
Old 09-16-2009, 08:02 AM
Slugger Slugger is offline
SageTVaholic
 
Join Date: Mar 2007
Location: Kingston, ON
Posts: 4,008
Quote:
Originally Posted by moothekow View Post
Ok - I apologized if this has been asked/answered, but I've spent hours searching through the forums and am not sure how to accomplish (or if I can accomplish) what I'm trying to do. Not sure of the things i've read what is old and doesn't apply, etc etc.

What I want to do is fairly simple/straight forward. After a record is finished - I want to move the file into another directory. So - lets say my tv shows record to a directory: 'd:\RecordedTV'. After the recording is finished I want to sort the episode by show/season/episode-name.mpg. So - example:

Go from:
d:\RecordedTV\FilenameSageTVGivesRecording.mpg

To:
d:\SortedTV\TVshowName\Season XX\SXXEXX - EpisodeName.mpg

is this possible? In a perfect world I'd like to still consider it a recorded tv show and all that fun jazz... but if it meant I could only get to it via the 'media center' videos area I could probably live with that.

Thanks.
Others are doing this and the details should be further up this thread - you'll need to go searching. My only warning is that moving recording files while SageTV is running (and it must be in order for SJQ to do the moving) is not a recommended practice, though the issues that arise from doing it might have been solved by the others who are doing similar things. Again, you'll have to search back up this thread for details.
__________________
Twitter: @ddb_db
Server: Intel i5-4570 Quad Core, 16GB RAM, 1 x 128GB OS SSD (Win7 Pro x64 SP1), 1 x 2TB media drive
Capture: 2 x Colossus
STB Controller: 1 x USB-UIRT
Software:Java 1.7.0_71; SageTV 7.1.9
Clients: 1 x HD300, 2 x HD200, 1 x SageClient, 1 x PlaceShifter
Plugins: Too many to list now...
  #897  
Old 09-16-2009, 09:31 AM
moothekow moothekow is offline
Sage Advanced User
 
Join Date: Oct 2008
Posts: 88
Quote:
Originally Posted by Slugger View Post
Others are doing this and the details should be further up this thread - you'll need to go searching. My only warning is that moving recording files while SageTV is running (and it must be in order for SJQ to do the moving) is not a recommended practice, though the issues that arise from doing it might have been solved by the others who are doing similar things. Again, you'll have to search back up this thread for details.
Ok - so I figured out it looks like I'll need to run a batch file ... but I'm not sure where to go from here...

I figure I need a custom ruleset like this:

if [IsTV == true && IsActivelyRecording == false && IsScheduledRecording == true] {
SORTRECORDING
}

Contents of the client job (i think that's what is is called?): ... not entirely sure what to use in here for my arguments to get what I need to my batch file...
SORTRECORDING {
:CPU low
:MAX 1
"C:\RenameEpisode.bat" "%c%" ..... what else can I use here?
}

Also not sure what else I need to do in my custom ruleset to make it mark the file post-move. Do I need to somehow do something with the '_MANUALREC' internal task? I've been digging through these forums a long time now and am having trouble working out the exact details of what I need to do.

Contents of the batch file I've come up with:

SET _inputFile=%1
SET _showName=%~n2
SET _season=%~n3
SET _episodeNumber=%~n4
SET _episodeName=%~n5

SET _baseFolder=c:\TVShows\
SET _showFolder=%_baseFolder%%_showName%\
SET _seasonFolder=%_showFolder%Season %_season%\
SET _newFileName=%_seasonFolder%S%_season%E%_episodeNumber% - %_episodeName%.mpg

if not exist "%_showFolder%" (
md "%_showFolder%"
)

if not exist "%_seasonFolder%\" (
md "%_seasonFolder%"
)

copy "%_inputFile%" "%_newFileName%"
  #898  
Old 09-16-2009, 10:01 AM
Slugger Slugger is offline
SageTVaholic
 
Join Date: Mar 2007
Location: Kingston, ON
Posts: 4,008
Quote:
Originally Posted by moothekow View Post
Contents of the client job (i think that's what is is called?): ... not entirely sure what to use in here for my arguments to get what I need to my batch file...
SORTRECORDING {
:CPU low
:MAX 1
"C:\RenameEpisode.bat" "%c%" ..... what else can I use here?
}
I'll answer what I can; the others who are doing similar things will have to chime in with the rest.

The available media variables available for command lines are documented here.
__________________
Twitter: @ddb_db
Server: Intel i5-4570 Quad Core, 16GB RAM, 1 x 128GB OS SSD (Win7 Pro x64 SP1), 1 x 2TB media drive
Capture: 2 x Colossus
STB Controller: 1 x USB-UIRT
Software:Java 1.7.0_71; SageTV 7.1.9
Clients: 1 x HD300, 2 x HD200, 1 x SageClient, 1 x PlaceShifter
Plugins: Too many to list now...
  #899  
Old 09-16-2009, 07:53 PM
Slugger Slugger is offline
SageTVaholic
 
Join Date: Mar 2007
Location: Kingston, ON
Posts: 4,008
Snapshot 542 is now available on Google Code. I am looking for as many people as possible to test this build and report any problems. The build contains just one change:

* Support short circuiting of test evaluations

Basically, prior to 542 if your test block looked like this:

Code:
if [IsTV == true && Title == "Family Guy" && IsActivelyRecording == false ] {

}
And the QueueLoader was processing a recording of "The Simpsons" then even after the second test failed (meaning the entire block is destined to fail), SJQ would still run the IsActivelyRecording test before rendering a verdict of false for the media object. Now with 542, SJQ recognizes that IsActivelyRecording doesn't need to be ran and that calculation can be skipped. I did account for this kind of test block:

Code:
if [IsTV == true && Title == "Family Guy" && IsActivelyRecording == false || DayOfWeek == 7 ] {

}
Is this case (again, assuming we're processing "The Simpsons"), SJQ will still skip the IsActivelyRecording test and then go on to test the DayOfWeek.

It is worth mentioning, formally, that SJQ's operators have the following precedence:

1. parenthesis have precedence
2. The || and && operators have equal precedence and are always evaluated in order from left to right

So consider the following statement:

A || B && C

In C/C++ that statement implies this order of evaluation:

A || (B && C)

But in SJQ, it is evaluated as such:

(A || B) && C

This has always been the case and does not change with this snapshot, but it is worth mentioning explicitly (you'll learn why later this winter ). I'll add this to the user guide shortly.

The obvious gain with this change is a performance boost when the QueueLoader is scanning media - many test evaluations will now be skipped, but that isn't the reason I am making this change today. This ability to short circuit out of a test block is the basis for SJQ v3. The ability to prevent tests from running is the key feature needed to allow the processing of other types of objects (say SageTV system message objects or event objects) with the least amount of code change. That's all I'll say for now, but I really do need as many people to test this build as possible to ensure I haven't broken the rules parser component.
__________________
Twitter: @ddb_db
Server: Intel i5-4570 Quad Core, 16GB RAM, 1 x 128GB OS SSD (Win7 Pro x64 SP1), 1 x 2TB media drive
Capture: 2 x Colossus
STB Controller: 1 x USB-UIRT
Software:Java 1.7.0_71; SageTV 7.1.9
Clients: 1 x HD300, 2 x HD200, 1 x SageClient, 1 x PlaceShifter
Plugins: Too many to list now...
  #900  
Old 09-18-2009, 11:10 AM
moothekow moothekow is offline
Sage Advanced User
 
Join Date: Oct 2008
Posts: 88
Slugger - is it at all possible to expose more media variables than are currently in the file? (Such as the episode title, episode number, season number, etc?). Looking at what you have so far - great works... Being a programmer myself I know how many hours you must have put into this thing... thanks.
Closed Thread


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Plugin: Sage Job Queue (SJQ) v3 Slugger SageTV Customizations 1355 07-25-2013 07:44 AM
Sage Job Queue (SJQ) new release notifications Slugger Customization Announcements 3 12-17-2009 09:59 AM
Sage Job Queue Completed tasks problem raffmanlt SageTV Customizations 2 08-18-2009 07:34 PM
Comskip Monitor VS Sage Job Queue SJQ personalt SageTV Customizations 6 03-02-2009 10:27 AM
Plugin: SJQ v1.1.0RC1 Available - Testers Needed Slugger SageTV Customizations 35 04-21-2008 08:12 AM


All times are GMT -6. The time now is 10:00 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2023, vBulletin Solutions Inc.
Copyright 2003-2005 SageTV, LLC. All rights reserved.