Athena federated query to Timestream slow

0

We connected Timestream to Athena using the Athena Timestream connector. When running a federated query through Athena to Timestream, performance is 7x slower than querying Timestream directly. Simple, sub-second queries in Timestream take a minimum of 7 seconds to return in Athena. Is there anyway to improve Athena's federated query performance? We could connect directly to Timestream's JDBC driver, but it would require additional work and won't allow joining across AWS products through Athena, like we had hoped to do.

In a similar vein, is it possible to use Glue to connect Timestream to Athena more directly? Or is the federated query connection still required even if using Glue?

Drew
質問済み 4ヶ月前755ビュー
2回答
0

Rearranging the tables in the join to better align with the WHERE clause can often result in a more efficient query plan, significantly reducing the runtime. Using Athena's EXPLAIN feature can help you identify inefficiencies in your query's execution plan. For example, making sure the join operations are performed in the correct order can have a substantial impact on performance. A suboptimal join order may result in unnecessary data processing and longer execution times.

https://aws.amazon.com/blogs/big-data/optimize-federated-query-performance-using-explain-and-explain-analyze-in-amazon-athena/

Additional metadata from AWS Glue Data Catalog may be used to optimize queries; AWS Glue database and table names must match those in Timestream; lowercase names are preferred for optimal performance; mixed case names result in more computationally intensive searches; setting AWS Glue table properties in accordance with Timestream requirements can also improve performance.

https://docs.aws.amazon.com/athena/latest/ug/connectors-timestream.html

https://docs.amazonaws.cn/en_us/athena/latest/ug/connectors-timestream.html

profile picture
エキスパート
回答済み 4ヶ月前
0

Appreciate the response. No joins are being used here, this is just a straight query to Timestream with a simple predicate that matches the timestream db.

We will integrate into Glue as well and see if that helps improve performance.

Drew
回答済み 4ヶ月前

ログインしていません。 ログイン 回答を投稿する。

優れた回答とは、質問に明確に答え、建設的なフィードバックを提供し、質問者の専門分野におけるスキルの向上を促すものです。

質問に答えるためのガイドライン

関連するコンテンツ