def create_elastic_search_datastore(self,
                                        name='',
                                        description='',
                                        persistence_system_id='',
                                        namespace='',
                                        replicas=1,
                                        shards=1):
        """Create an elastic seach datastore

        @param name    str
        @param description    str
        @param persistence_system_id    str
        @param namespace    str
        @param replicas    int
        @param shards    int
        @retval datastore_id    str
        """
        datastore = DataStore(name=name,
                              description=description,
                              type=DataStoreType.ELASTICSEARCH,
                              namespace=namespace)
        datastore.config['replicas'] = replicas
        datastore.config['shards'] = shards
        data_store_id, rev = self.clients.resource_registry.create(datastore)

        if persistence_system_id != '':
            self.clients.resource_registry.create_association(
                persistence_system_id, PRED.hasDatastore, data_store_id)

        return data_store_id
    def create_couch_datastore(self,
                               name='',
                               description='',
                               persistence_system_id='',
                               namespace='',
                               replicas=1,
                               partitions=1):
        """Create a couch datastore

        @param name    str
        @param description    str
        @param persistence_system_id    str
        @param namespace    str
        @param replicas    int
        @param partitions    int
        @retval datastore_id    str
        """
        datastore = DataStore(name=name,
                              description=description,
                              type=DataStoreType.COUCHDB,
                              namespace=namespace)
        datastore.config['replicas'] = replicas
        datastore.config['partitions'] = partitions
        data_store_id, rev = self.clients.resource_registry.create(datastore)

        if persistence_system_id != '':
            self.clients.resource_registry.create_association(
                persistence_system_id, PRED.hasDatastore, data_store_id)

        return data_store_id
    def create_elastic_search_datastore(self, name='', description='', persistence_system_id='', namespace='', replicas=1, shards=1):
        """Create an elastic seach datastore

        @param name    str
        @param description    str
        @param persistence_system_id    str
        @param namespace    str
        @param replicas    int
        @param shards    int
        @retval datastore_id    str
        """
        datastore = DataStore(name=name, description=description, type=DataStoreType.ELASTICSEARCH, namespace=namespace)
        datastore.config['replicas'] = replicas
        datastore.config['shards'] = shards
        data_store_id, rev = self.clients.resource_registry.create(datastore)

        if persistence_system_id != '':
            self.clients.resource_registry.create_association(persistence_system_id, PRED.hasDatastore, data_store_id)

        return data_store_id
    def create_couch_datastore(self, name='', description='', persistence_system_id='', namespace='', replicas=1, partitions=1):
        """Create a couch datastore

        @param name    str
        @param description    str
        @param persistence_system_id    str
        @param namespace    str
        @param replicas    int
        @param partitions    int
        @retval datastore_id    str
        """
        datastore = DataStore(name=name, description=description, type=DataStoreType.COUCHDB, namespace=namespace)
        datastore.config['replicas'] = replicas
        datastore.config['partitions'] = partitions
        data_store_id, rev = self.clients.resource_registry.create(datastore)

        if persistence_system_id != '':
            self.clients.resource_registry.create_association(persistence_system_id, PRED.hasDatastore, data_store_id)

        return data_store_id
    def create_file_system_datastore(self, name='', description='', persistent_archive_id='', persistence_system_id='', namespace='', replicas=1):
        """Create a file system datastore

        @param name    str
        @param description    str
        @param persistent_archive_id    str
        @param persistence_system_id    str
        @param namespace    str
        @param replicas    int
        @retval datastore_id    str
        """
        datastore = DataStore(name=name, description=description, type=DataStoreType.FILESYSTEM, namespace=namespace)
        datastore.config['replicas'] = replicas
        data_store_id, rev = self.clients.resource_registry.create(datastore)

        if persistence_system_id != '':
            self.clients.resource_registry.create_association(subject=persistence_system_id, predicate=PRED.hasDatastore, object=data_store_id)

        if persistent_archive_id != '':
            self.clients.resource_registry.create_association(subject=data_store_id, predicate=PRED.hasArchive, object=persistent_archive_id)

        return data_store_id
    def create_file_system_datastore(self,
                                     name='',
                                     description='',
                                     persistent_archive_id='',
                                     persistence_system_id='',
                                     namespace='',
                                     replicas=1):
        """Create a file system datastore

        @param name    str
        @param description    str
        @param persistent_archive_id    str
        @param persistence_system_id    str
        @param namespace    str
        @param replicas    int
        @retval datastore_id    str
        """
        datastore = DataStore(name=name,
                              description=description,
                              type=DataStoreType.FILESYSTEM,
                              namespace=namespace)
        datastore.config['replicas'] = replicas
        data_store_id, rev = self.clients.resource_registry.create(datastore)

        if persistence_system_id != '':
            self.clients.resource_registry.create_association(
                subject=persistence_system_id,
                predicate=PRED.hasDatastore,
                object=data_store_id)

        if persistent_archive_id != '':
            self.clients.resource_registry.create_association(
                subject=data_store_id,
                predicate=PRED.hasArchive,
                object=persistent_archive_id)

        return data_store_id