code: public function countNotDeletedVersions($nodeId, $language, $siteId)
      {
          $qa = $this->createAggregationQueryBuilderWithSiteIdAndLanguage($siteId, $language);
          $qa->match(array(
              'nodeId' => $nodeId,
              'deleted'=> false,
          ));
  
          return $this->countDocumentAggregateQuery($qa);
      }
docs: @param string $nodeId
  @param string $language
  @param string $siteId
  
  @throws \Exception
  
  @return mixed