@rest_initialiser(cluster_init_check=True, version_check=True)
def execute(self, opts):
    (_, errors) = self.rest.get_bucket(opts.bucket_name)
    _exit_if_errors(errors)
    if (not opts.force):
        question = ('Running this command will totally PURGE database data from disk. ' + 'Do you really want to do it? (Yes/No)')
        confirm = input(question)
        if (confirm not in ('y', 'Y', 'yes', 'Yes')):
            return
    (_, errors) = self.rest.flush_bucket(opts.bucket_name)
    _exit_if_errors(errors)
    _success('Bucket flushed')
@rest_initialiser(cluster_init_check=True, version_check=True)
def execute(self, opts):
    (_, errors) = self.rest.get_bucket(opts.bucket_name)
    _exit_if_errors(errors)
    if (not opts.force):
        question = ('Running this command will totally PURGE database data from disk. ' + 'Do you really want to do it? (Yes/No)')
        confirm = input(question)
        if (confirm not in ('y', 'Y', 'yes', 'Yes')):
            return
    (_, errors) = self.rest.flush_bucket(opts.bucket_name)
    _exit_if_errors(errors)
    _success('Bucket flushed')