code: def get_model_indexes(model, add_reserver_flag=True):
      
      import uliweb.orm as orm
      from sqlalchemy.engine.reflection import Inspector
  
      indexes = []
      engine = model.get_engine().engine
      insp = Inspector.from_engine(engine)
      for index in insp.get_indexes(model.tablename):
          d = {}
          d['name'] = index['name']
          d['unique'] = index['unique']
          d['fields'] = index['column_names']
          if add_reserver_flag:
              d['_reserved'] = True
          indexes.append(d)
  
      return indexes
docs: Creating indexes suit for model_config.