library/Garp/Service/Elasticsearch/Configuration.php
protected function _getDefaultIndex() {
        $config = Zend_Registry::get('config');

        if (!isset($config->app->name)) {
            throw new Exception(self::ERROR_NO_APP_NAME_CONFIGURED);
        }

        $appName = str_replace(' ', '', $config->app->name);
        $appName = Garp_Util_String::camelcasedToDashed($appName);

        if (!$appName) {
            throw new Exception(self::ERROR_APP_NAME_EMPTY);
        }

        $indexName = $appName . '-' . APPLICATION_ENV;

        return $indexName;
    }
protected function _getDefaultIndex() {
        $config = Zend_Registry::get('config');

        if (!isset($config->app->name)) {
            throw new Exception(self::ERROR_NO_APP_NAME_CONFIGURED);
        }

        $appName = str_replace(' ', '', $config->app->name);
        $appName = Garp_Util_String::camelcasedToDashed($appName);

        if (!$appName) {
            throw new Exception(self::ERROR_APP_NAME_EMPTY);
        }

        $indexName = $appName . '-' . APPLICATION_ENV;

        return $indexName;
    }
protected function _getDefaultIndex ( ) { $ config = Zend_Registry :: get ( 'config' ) ; if ( ! isset ( $ config -> app -> name ) ) { throw new Exception ( self :: ERROR_NO_APP_NAME_CONFIGURED ) ; } $ appName = str_replace ( ' ' , '' , $ config -> app -> name ) ; $ appName = Garp_Util_String :: camelcasedToDashed ( $ appName ) ; if ( ! $ appName ) { throw new Exception ( self :: ERROR_APP_NAME_EMPTY ) ; } $ indexName = $ appName . '-' . APPLICATION_ENV ; return $ indexName ; }
Returns the database name for this environment, to be used as the index name for Elasticsearch.
Returns the database name for this environment to be used as the index name for Elasticsearch .