[Closed] set backburner dependencies via maxscript
I’ve been working on a script involving submitting jobs to backburner and the one thing that it lacks is the ability to set job dependencies. I’ve searched the reference quite extensively and found no info at all so i’m hoping that i’ve just gone blind and missed something that’s right in front of me. Does anyone know if its possible to set job dependencies via maxscript? I’m using max 8 but I’d like to know if there’s a solution in a later version too
I’m in the same situation here.
Maybe a postrender script would do the job (Send the second job suspended and activate when the first one finished), haven’t tested it yet. But still would be more useful to have a way to directly set dependencies.
OK, I tried my previous suggestion and it doesn’t seem to work because you need to have control of the render manager to resume (activate) a job, and doesn’t seem a good idea to me to have BB servers to steal user control at will …
What I’m working on now is to try to send the second BB job from the scene that has been rendered using a postRender callback. I managed to get the callback function run by the machine that does the render, but it refuses to send the job, just puts the state ‘Unsubmitted’ to the job and ends.
Is there some kind of limitation on sending jobs from a scene that is being rendered in BB?
Any ideas?
Sorry, not an answer (at least not one you would probably like). We use RPManager, and while we were using Backburner, we could not set the dependicies properly (we did some mucking around with suspended jobs and priorities). This seems to be a limitation of backburner…as far as I know, I’ve actually never tried my self…
Shane
Thanks for the reply Shane, is good to know that experienced people have the same problem
thanks for the reply’s guys. Codi, i will try your callbacks idea in the next few days and see if I have any luck. On a similar note, I noticed that you can set backburner specific callbacks using the netrender interface which might be worth looking into.
I’ll let you know how it goes
I hadn’t any luck with my second approach so far. If it can help you, this is the callback code that I’m using:
(
callbacks.removeScripts id:#postRender_AsistantRender -- Removes the callback, we dont want an infintite loop
txt_post = createFile "c:\ est_post01.txt" -- Creates a text file, for debugging purposes
m = netrender.getmanager()
if m.connected == false then isConnected = m.connect #automatic "255.255.255.0"
if (isConnected) == true then (
--Create new job
job = m.newJob()
job.name = "Post callback job xxx"
job.priority = 50
job.fromFrame = currentTime
job.toFrame = currentTime
-- Submits the job
try(job.submit())catch(print (getCurrentException() as string) to:txt_post)
job.submit()
-- Some debugging
print ("j " + job as string) to:txt_post
print ("j.n " + job.name as string) to:txt_post
print ("j.s " + job.state as string) to:txt_post
print ("j.h " + job.handle as string) to:txt_post
)
close txt_post
)
This script must be in a place that all render nodes should be able to see, and the callback is created the following way:
callbacks.addScript #postRenderFrame fileName:("*path to the postRender script in a shared folder*") id:#postRender_AsistantRender persistent:true
We have an independent box that watches our BackBurner Managers, e-mails completions, creates custom logs, makes dailies of completed animations and renames files…ect. It also would be able to start/stop jobs based on a data file… aka dependencies…
In the MaxScript/Python Thread, there’s a start of a Python based Backburner client which could also provide this functionality and perhaps even assign a actual dependency… that would be sweet…
You’ll notice when you create a job the dependency field of the xml is empty. When the manager starts, it seems to load all the job xml’s into memory and only updates a few of the fields in the actual xml doc when rendering. The only time it READS the full xml is on a manager start or restoring a job from archive.
I’ve chased this issue before with no resolution, I’ll be interested to see where this thread ends…
The XML idea is another good path to explore, I did find a reference of it in the old Adesk forum, but I haven’t gone any further:
http://discussion.autodesk.com/thread.jspa?messageID=5296279 (see 1st reply)
Seems that the creator of RPManager used it in conjunction with comand line render.