/**
  * Gets the status of running batch invocation.
  */
 public function statusAction()
 {
     $this->_helper->viewRenderer->setNoRender();
     $this->_helper->layout()->disableLayout();
     $response = Sahara_Soap::getSchedServerSessionClient()->getSessionInformation(array('userQName' => $this->_auth->getIdentity()));
     if (!$response->isInSession) {
         /* Not in session, so unable to determine the rig clients address. */
         $error = array('success' => 'false', 'error' => array('code' => -1, 'operation' => 'Batch status request', 'reason' => 'not in session'));
         echo $this->view->json($error);
         return;
     }
     try {
         list($ns, $name) = explode(':', $this->_auth->getIdentity());
         $rigClient = new Sahara_Soap($response->contactURL . '?wsdl');
         echo $this->view->json($rigClient->getBatchControlStatus(array('requestor' => $name)));
     } catch (Exception $ex) {
         $this->_logger->error("Soap error calling batch 'getBatchControlStatus'. Message: " . $ex->getMessage() . ', code: ' . $ex->getCode() . '.');
         echo $this->view->json(array('success' => false, 'error' => array('code' => -4, 'operation' => 'Batch status request', 'reason' => 'Exception getting batch status, message: ' . $ex->getMessage())));
     }
 }