When the maintenance queue runs it is running for the entire Recite CMS installation, not for a specific client. Since a queue will typically be the result of an action on a particular client's web site, you will need access to that client in your maintenance script.
Recite CMS automates this process of retaining client context for you. That is, you
can still call Application::GetClient()
and
getClientId()
and be sure that it will correspond to the
correct client.