Forum: Ruby on Rails Workling - Queue List

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
77fb40a032b213788662bbae7058ec00?d=identicon&s=25 Manuel (Guest)
on 2009-03-31 09:25
(Received via mailing list)
Hi there,

I'm working on a Conversion Machine for Videos. I use workling and
starling.
My problem is that I can't find a way to show me how many jobs I have
in each worker queue and maybe the possiblity to delete a job from
that list.
I tried it with the MemCache stats, searched the web etc.... can't
find anything suitable

Maybe the only solution is to create another Database Table where I
store my Conversion-Jobs and delete them out with the worker? Sounds
like bad practice, but I'm so tired of this right now :-)

Maybe you guys have an idea?
Help very appreciated
E00fa5dff361e0bed4b488d874960889?d=identicon&s=25 Danimal (Guest)
on 2009-03-31 17:02
(Received via mailing list)
Hi Manuel,

Personally, I don't think it's a bad practice at all. I have an app
that does video uploads and conversions. The way I do it is to upload
the video, store it in the DB in a videos table with a status of
"unconverted" then spawn a conversion thread (I'm using spawn, but the
idea would work the same with other background process tools). As soon
as the thread starts, the status is set to "converting". And once it's
done, it's set to "converted".

The advantage is that the rails app can show a list of videos with
their conversion status.

I haven't used workling/starling yet, however, so that may constrain
things... but the general idea of storing each video in a table that
both your rails app and your conversion process can access makes a lot
of sense, at least to me.

HTH!

-Danimal
77fb40a032b213788662bbae7058ec00?d=identicon&s=25 Manuel (Guest)
on 2009-04-01 10:31
(Received via mailing list)
Hi Danimal,

Jeah I already do the same, I have a "original" and a "converted"
table so I can reprocess them etc...
I've found active_queue:
http://github.com/starling/active_queue/tree/master
Sounds like a perfect match, but can't get it to work... Seems that
nobody has a need for it :-)
Maybe the thing with another Database Table with status isn't such a
bad thing as i thought.... maybe another archive table with the
"converted" records should't be a bad idea, right?

Regards,
Manuel
This topic is locked and can not be replied to.