ElasticsearchSQLHook
通过 elasticsearch-dbapi 与 Elasticsearch 交互的 Elasticsearch 钩子
使用示例
es = ElasticsearchSQLHook(elasticsearch_conn_id=CONN_ID)
es_connection = es.get_conn()
response = es_connection.execute_sql("SHOW TABLES")
for row in response["rows"]:
print(f"row: {row}")
return True