Skip to content

Commit

Permalink
[Bug]External engines(e.g. ES) don't have segments, ignore those tabl…
Browse files Browse the repository at this point in the history
…es (#4671)

It will crash when there are External engine tables in doris after executing "python show_segment_status.py"
The main reason is external engine tables don't have any index and partitions. So it should be ignored.
  • Loading branch information
caoyang10 committed Sep 28, 2020
1 parent 05512d7 commit 0eb5400
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions tools/show_segment_status/fe_meta_resolver.py
Expand Up @@ -110,12 +110,13 @@ def _fetch_tables_by_db(self, db):
self.exec_sql(sql);
table_list = self.cur.fetchall()
for table_tuple in table_list :
table = {}
table['db_id'] = db['db_id']
table['db_name'] = db['db_name']
table['tbl_id'] = long(table_tuple[0])
table['tbl_name'] = table_tuple[1]
self.table_list.append(table)
if table_tuple[6] == "OLAP":
table = {}
table['db_id'] = db['db_id']
table['db_name'] = db['db_name']
table['tbl_id'] = long(table_tuple[0])
table['tbl_name'] = table_tuple[1]
self.table_list.append(table)
return

def fetch_rollup_map(self):
Expand Down

0 comments on commit 0eb5400

Please sign in to comment.