Download Dive deep into application performance using Query Store in SQL

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts

Relational algebra wikipedia , lookup

Database wikipedia , lookup

Extensible Storage Engine wikipedia , lookup

Microsoft Access wikipedia , lookup

Open Database Connectivity wikipedia , lookup

SQL wikipedia , lookup

Clusterpoint wikipedia , lookup

Microsoft Jet Database Engine wikipedia , lookup

Microsoft SQL Server wikipedia , lookup

Relational model wikipedia , lookup

Database model wikipedia , lookup

Versant Object Database wikipedia , lookup

Transcript
Credits to:
Connor Cunningham and Query Store team
Visual Studio Online
Bob Ward, Principal PM Architect
long
Survives
crashes
Records
critical
information
Records for
limited time
Doesn’t record
everything
Broadly utilize Query Store to ensure optimal and
predictable performance for their tenants.
“Highly recommend to everyone!
“Query Store has allowed us to pinpoint and fix
problems that would be very difficult to analyze
without the detailed information it provides”
Today
Yesterday
Today
Yesterday
Today
Yesterday
Upgrade to SQL
Server 2016
(stay at prior DB
Compatibility Level)
Enable Query Store,
Capture Plans
Set Compatiblity
Level to 130
Use Query Store to
Force Old Plans
Quickly For Any
Regressions
Protection
Optimization
• Regressed queries
• Excessive resource
consumption
• Database upgrade
• Change verification
• Improve ad-hoc
workloads
• Identify execution
patterns
• Analyze execution
variability
Query Store Scenarios @ MSDN
internal tables
Query Text
Context
Settings
1:N
Query
1:N
1 - n
Plan
views
1:N
1 - n
Runtime
Stats
Compile stats:
query_store_query_text
query_context_settings
query_store_query
query_store_plan
1:N
Runtime Stats
Interval
One Row Per Query Text Per
Plan Affecting Option Per
Object
Example: ANSI NULLS on/off,
query inside/outside SP
One Row Per Plan
(for each query)
sys.
One Row Per
Plan Per Time
Interval
(example: 5 min)
Runtime stats:
query_store_runtime_stats_interval
query_store_runtime_stats
Execution Type (completed, client aborted, server aborted)
Plan Store
Stats
Interval
Timeframe for aggregation
of stats for plan
Flush
Interval
How often we persist to
disk
In
Out
SELECT
DDL
UPDATE
INSERT
DELETE
BULK INSERT
“Commands”
CREATE, ALTER,
DROP, …
DBCC, KILL,
BACKUP, …
sys.database_query_store_options
Best Practices
…a workload data recorder for your
databases
QUERY STORE
…the starting point for
performance troubleshooting
…gives you full control wherever
you are (on-premises, in the cloud)
Query Store: A flight data recorder for your database
Monitoring Performance By Using the Query Store
Azure SQL Database Query Performance Insight
[email protected]
www.microsoft.com/itprocareercenter
www.microsoft.com/itprocloudessentials
www.microsoft.com/mechanics
https://techcommunity.microsoft.com
http://myignite.microsoft.com
https://aka.ms/ignite.mobileapp