I've written an extensive POE::Component::JobQueue which is used to get around a long running Singleton process.

I've figured out how to load multiple copies of the Singleton into the application, however I need to ensure that only a copy of the Singleton that is not being used is referenced.

The easiest way to do this would be to simply refer to the worker_count reference of the JobQueue process as shown in the internals. IE: JobQueue #1 would reference to the #1 singleton... #8 would reference to the #8 reference of the singleton.

However using a Passive JobQueue with standard FIFO, which then runs a session which calls the Singleton through a Wheel::Run process, I can not figure out how to access what is the current wheel_count.

Checking a dump of the Kernel for the POE, shows the data is deeply embeded, but not directly accessible. Direct Access to the current Heap or Session does not lead to access.

Is there a way to get the current worker_count for a Passive JobQueue?

(Sorry for no code samples, the code is not accessible on the Intranet)
Even smart people are dumb in most things...

In reply to POE::Component::JobQueue, getting current worker number by Devanchya

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.