def overview():
range_search = RangeSearch()<EOL>ranges = range_search.get_ranges()<EOL>if ranges:<EOL><INDENT>formatted_ranges = []<EOL>tags_lookup = {}<EOL>for r in ranges:<EOL><INDENT>formatted_ranges.append({'<STR_LIT>': r.range})<EOL>tags_lookup[r.range] = r.tags<EOL><DEDENT>search = Host.search()<EOL>search = search.filter('<STR_LIT>', status='<STR_LIT>')<EOL>search.aggs.bucket('<STR_LIT>', '<STR_LIT>', field='<STR_LIT:address>', ranges=formatted_ranges)<EOL>response = search.execute()<EOL>print_line("<STR_LIT>".format("<STR_LIT>", "<STR_LIT>", "<STR_LIT>"))<EOL>print_line("<STR_LIT:->" * <NUM_LIT>)<EOL>for entry in response.aggregations.hosts.buckets:<EOL><INDENT>print_line("<STR_LIT>".format(entry.key, entry.doc_count, tags_lookup[entry.key]))<EOL><DEDENT><DEDENT>else:<EOL><INDENT>print_error("<STR_LIT>")<EOL><DEDENT>
Creates a overview of the hosts per range.