简体   繁体   中英

Windows Azure WADLogs Query is very slow

I've noticed that querying a WADs table eg WADLogs is very very slow. It takes up to 5minute to return 10 records.

Yes the WADs table are very large in our scenario. Still, I wasn't expecting this slow. It takes ages to troubleshoot the production issues.

Question I've:

  1. Could anyone please share best way to manage the WADs table so that query is faster.

  2. Is there anyway to optimize the WADs tabels

  3. Is there a best practice what should and should not be done when logging on to WADs

  4. Are there any best practices on purging/backing up etc.

Thank you.

Gaurav Mantri has a post explaining how to query WAD tables in a performant manner. The bottom line is that you need to query on PartitionKey and RowKey to avoid a performance-killing table scan. The PartitionKey for the WAD tables contains the TickCount in a slightly encoded form and an appropriately constructed value can be used for range queries.

Thanks Neil for the link.

Summary:

  1. Use PartionKey attribute which is indexed by Table Storage.

Where,

PartionKey = "0"+ DateTime.UtcNow.AddDays(-1.0).Ticks

Usage for REST API Query ($filter) criteria: PartitionKey ge '0634012319404982640′

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM