scripts/tools/KvToRdsMigration.php
protected function getCurrentKvResultStorage()
    {
        /** @var ResultServerService $resultService */
        $resultService = $this->getServiceLocator()->get(ResultServerService::SERVICE_ID);
        $resultStorageKey = $resultService->getOption(ResultServerService::OPTION_RESULT_STORAGE);
        if ($resultStorageKey != 'taoAltResultStorage/KeyValueResultStorage') {
            throw new \common_Exception('Result storage is not on KeyValue storage mode.');
        }
        return $resultService->instantiateResultStorage($resultStorageKey);
    }
protected function getCurrentKvResultStorage()
    {
        /** @var ResultServerService $resultService */
        $resultService = $this->getServiceLocator()->get(ResultServerService::SERVICE_ID);
        $resultStorageKey = $resultService->getOption(ResultServerService::OPTION_RESULT_STORAGE);
        if ($resultStorageKey != 'taoAltResultStorage/KeyValueResultStorage') {
            throw new \common_Exception('Result storage is not on KeyValue storage mode.');
        }
        return $resultService->instantiateResultStorage($resultStorageKey);
    }
protected function getCurrentKvResultStorage ( ) { /** @var ResultServerService $resultService */ $ resultService = $ this -> getServiceLocator ( ) -> get ( ResultServerService :: SERVICE_ID ) ; $ resultStorageKey = $ resultService -> getOption ( ResultServerService :: OPTION_RESULT_STORAGE ) ; if ( $ resultStorageKey != 'taoAltResultStorage/KeyValueResultStorage' ) { throw new \ common_Exception ( 'Result storage is not on KeyValue storage mode.' ) ; } return $ resultService -> instantiateResultStorage ( $ resultStorageKey ) ; }
Get the configured service to deal with result storage

@return \taoResultServer_models_classes_WritableResultStorage
@throws \common_exception If the service is not a key value interface
Get the configured service to deal with result storage