Tirex::Manager(3pm)

πŸ’– Tirex::Manager(3pm) πŸ’–

okay bestie, gather round, because this is the manual page for Tirex::Manager β€” that's the Rendering manager from the User Contributed Perl Documentation, and yes it's a Perl module page, and yes it absolutely eats. πŸŽ€


✨ NAME ✨

Tirex::Manager β€” she's the Rendering manager. that's the whole name. short. iconic. no notes. πŸ’…


🌸 SYNOPSIS 🌸

here's the vibe in code form, bestie:

use Tirex::Manager;
my $queue = Tirex::Queue->new();
my $rm = Tirex::Manager->new( queue => $queue );

make a Tirex::Queue, hand it to Tirex::Manager->new, boom. you're managing renderings. πŸ¦‹


πŸ‘‘ DESCRIPTION πŸ‘‘

so the rendering manager's whole thing is: it takes jobs from the queue and runs them. that's the job. that's the gig. queen behavior honestly.

but she's not out here just yeeting every job at once, no ma'am β€” she takes into account how many parallel renderings are allowed, and also the priority of the jobs, etc. it's giving resource-aware. it's giving scheduling with emotional intelligence. 😌


🧚 METHODS 🧚

πŸ’œ Tirex::Manager->new( queue => $queue )

Make a brand new rendering manager, bestie. the parameters are:

  • queue β€” the queue with the rendering requests (go look at Tirex::Queue, iykyk) πŸ“

🌈 $rm->add_bucket(name => $name, minprio => $minprio, maxproc => $maxproc, maxload => $maxload)

Creates a bucket with the config you passed and adds it to the roster. and she's always keeping the buckets sorted according to minprio β€” like a good little list, always in order, obsessed with her. ✨

Returns the bucket she just created, or undef if something went wrong. 😭

🫢 $rm->set_active_flag_on_bucket($active, $bucketname)

Returns true if it worked β€” ok so that means the bucket did exist β€” and false if it didn't work out. simple as. πŸ’–

πŸŽ€ $rm->get_socket()

Return the socket where the rendering manager expects responses from the rendering backends. bestie, you should add this to your select calls in the main loop. don't forget. I'm serious. don't forget. πŸ™ˆ

⭐ $rm->schedule()

Runs as many jobs as there are in the queue β€” as long as the resources don't run out. so like, she'll go as hard as she can, but she knows her limits. main character with boundaries. πŸ’…

this will also check for timeouts on the jobs that are currently rendering. multitasking queen. πŸ‘‘

πŸ”₯ $rm->run()

Checks whether there's a job that can be rendered and whether there are enough resources, and then renders the job. vibe check, then yeet.

Returns:

  • undef if there is no job to run
  • 0 if there aren't enough resources
  • 1 if a job was started
  • 2 if a job was expired

four possible outcomes, one function. efficiency. 🌸

πŸ’€ $rm->send($job)

Send a job to the rendering daemon. go little job go!! πŸ¦‹

πŸ’– $rm->done($msg)

This is called when a message comes back from the backend saying a job was rendered. like a little text back, except it's a rendering. πŸ₯°

Returns the job, or undef if the job was not found. (ghosted by a job. tragic.) 😭

πŸ“ $rm->log_stats()

Write statistics to the log file. numbers. receipts. data. she keeps track. ✨

🌟 $rm->status()

Return the status of the rendering manager. how's she doing? what's the vibe? this tells you. πŸ’œ

🧁 $rm->get_load_from_uptime()

Get the system load by calling the uptime command. so old school. so classic. this one is called by get_load() if /proc/loadavg is not available β€” she's the backup plan, and backup plans are underrated. πŸ’…

🌈 $rm->get_load()

Get the current load on the machine. heads up though: if /proc/loadavg is not readable for some reason, it always returns 0. so like, zero. just zero. no drama, no error, just 0. πŸ™ˆ


πŸ‘€ SEE ALSO πŸ‘€

  • Tirex::Manager::Test β€” go read her too, bestie, she's the whole other page πŸ’–

and that's the page fr fr. πŸ’• this lil beauty is from the User Contributed Perl Documentation for Tirex::Manager, running the Perl v5.40.1 life, dated 2026-08-09. slay, stay rendered, and don't forget to add that socket to your select calls. mwah. πŸŽ€βœ¨πŸ’…

πŸ“¦ where this page comes from