-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathQueryStatisticsTest.html
More file actions
148 lines (146 loc) · 10.4 KB
/
QueryStatisticsTest.html
File metadata and controls
148 lines (146 loc) · 10.4 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>LSD</title>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.2/jquery.min.js" type="text/javascript"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.12.1/jquery-ui.min.js" type="text/javascript"></script>
<link rel="stylesheet" href="https://ajax.googleapis.com/ajax/libs/jqueryui/1.12.1/themes/smoothness/jquery-ui.css" type="text/css" media="all"/>
<link rel="stylesheet" href="https://static.jquery.com/ui/css/demo-docs-theme/ui.theme.css" type="text/css" media="all"/>
<link rel="stylesheet" id="theme" type="text/css" href="yatspec_alt.css">
</head>
<body>
<div class="hd-switch">
<input type="checkbox" id="switch-id" name="myswitch" onchange="toggleTheme()">
<label for="switch-id">Classic</label>
<span class="hd-switch-knob"></span>
</div>
<div class="logo">
<h5 class="logo1">L</h5>iving <h5 class="logo2">S</h5>equence <h5 class="logo3">D</h5>iagrams
</div>
<header>
<h1>Query statistics</h1>
<pre class="notes">Performance of Embers Queries is audited to a database table.</pre>
<nav class="contents">
<h2>Contents</h2>
<ul class="contents">
<li class='test-passed icon-check'>
<a href="#auditAnExistingQueryThatRespondsWithData">Audit an existing query that responds with data</a>
</li>
</ul>
</nav>
</header>
<main role="main">
<article class="testmethod section">
<header>
<a id="auditAnExistingQueryThatRespondsWithData"></a>
<h2 class="section-header">Audit an existing query that responds with data</h2>
</header>
<section class="section-body">
<section class="scenario" id="-521144566_0_250739498">
<section class="specification">
<h2>Specification<a id=""></a></h2>
<pre class="highlight specification">Yatspec query inserter all queries
When http get request for all_queries
Then the performance audit shows useful statistics about the executed query</pre>
</section>
<section class="results">
<h3 class="logKey">Test result:</h3>
<pre class='highlight results test-passed icon-check'>Test passed</pre>
</section>
<section class="diagram">
<h3 logkey="Sequence_Diagram">Sequence Diagram</h3>
<div class="highlight SvgWrapper" ><?xml version="1.0" encoding="UTF-8"?>
<svg xmlns="http://www.w3.org/2000/svg" contentScriptType="application/ecmascript"
contentStyleType="text/css" height="251px" preserveAspectRatio="none"
style="width:153px;height:251px;" version="1.1" viewBox="0 0 153 251"
width="153px" zoomAndPan="magnify">
<defs>
<filter height="300%" id="f1rrjxfak1hqrk" width="300%" x="-1" y="-1">
<feGaussianBlur result="blurOut" stdDeviation="2.0" />
<feColorMatrix in="blurOut" result="blurOut2" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 .4 0" />
<feOffset dx="4.0" dy="4.0" in="blurOut2" result="blurOut3" />
<feBlend in="SourceGraphic" in2="blurOut3" mode="normal" />
</filter>
</defs>
<g>
<line style="stroke:#A80036;stroke-width:1.0;stroke-dasharray:5.0,5.0;" x1="28" x2="28" y1="88.4883" y2="167.1094" />
<line style="stroke:#A80036;stroke-width:1.0;stroke-dasharray:5.0,5.0;" x1="108.5" x2="108.5" y1="88.4883" y2="167.1094" />
<text fill="#000000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="40" x="5" y="85.5352">Client</text>
<ellipse cx="28" cy="15" fill="#FEFECE" filter="url(#f1rrjxfak1hqrk)" rx="8" ry="8" style="stroke:#A80036;stroke-width:2.0;" />
<path d="M28,23 L28,50 M15,31 L41,31 M28,50 L15,65 M28,50 L41,65 " fill="none" filter="url(#f1rrjxfak1hqrk)" style="stroke:#A80036;stroke-width:2.0;" />
<text fill="#000000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="40" x="5" y="179.6445">Client</text>
<ellipse cx="28" cy="192.5977" fill="#FEFECE" filter="url(#f1rrjxfak1hqrk)" rx="8" ry="8" style="stroke:#A80036;stroke-width:2.0;" />
<path d="M28,200.5977 L28,227.5977 M15,208.5977 L41,208.5977 M28,227.5977 L15,242.5977 M28,227.5977 L41,242.5977 " fill="none" filter="url(#f1rrjxfak1hqrk)" style="stroke:#A80036;stroke-width:2.0;" />
<rect fill="#FEFECE" filter="url(#f1rrjxfak1hqrk)" height="30.4883" style="stroke:#A80036;stroke-width:1.5;" width="65" x="74.5" y="53" />
<text fill="#000000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="51" x="81.5" y="73.5352">Embers</text>
<rect fill="#FEFECE" filter="url(#f1rrjxfak1hqrk)" height="30.4883" style="stroke:#A80036;stroke-width:1.5;" width="65" x="74.5" y="166.1094" />
<text fill="#000000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="51" x="81.5" y="186.6445">Embers</text>
<line style="stroke:#A80036;stroke-width:1.0;" x1="107" x2="97" y1="119.7988" y2="115.7988" />
<line style="stroke:#A80036;stroke-width:1.0;" x1="107" x2="97" y1="119.7988" y2="123.7988" />
<line style="stroke:#A80036;stroke-width:1.0;" x1="28" x2="108" y1="119.7988" y2="119.7988" />
<text class="sequence_diagram_clickable" fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" sequence_diagram_message_id="_request_from_Client_to_Embers" textLength="47" x="35" y="115.0566">request</text>
<line style="stroke:#A80036;stroke-width:1.0;" x1="28" x2="38" y1="149.1094" y2="145.1094" />
<line style="stroke:#A80036;stroke-width:1.0;" x1="28" x2="38" y1="149.1094" y2="153.1094" />
<line style="stroke:#A80036;stroke-width:1.0;stroke-dasharray:2.0,2.0;" x1="28" x2="108" y1="149.1094" y2="149.1094" />
<text class="sequence_diagram_clickable" fill="#000000" font-family="sans-serif" font-size="13" lengthAdjust="spacing" sequence_diagram_message_id="_response_from_Embers_to_Client" textLength="57" x="45" y="144.3672">response</text>
</g>
</svg>
</div>
</section>
<section class="interestingGivens">
<h3 class="logKey">Interesting Givens</h3>
<table class="interestingGivens">
<tr>
<th class="key">Expected Query Name To Run</th>
<td class="interestingGiven">allQueries</td>
</tr>
<tr>
<th class="key">Expected Query Sql To Run</th>
<td class="interestingGiven">select id, name, description, sql from queries order by name</td>
</tr>
<tr>
<th class="key">Url</th>
<td class="interestingGiven">http://localhost:8001/embers/query/allQueries</td>
</tr>
</table>
</section>
<footer>
<section class="interactions">
<details>
<summary>Captured Interactions</summary>
<details class="interaction">
<summary class="logKey" logkey="_request_from_Client_to_Embers"> request from Client to Embers</summary>
<div contenteditable="true" ondblclick="document.execCommand('selectAll',false,null)"
class="logValue highlight HttpRequestWrapper">GET http://localhost:8001/embers/query/allQueries
Headers: null
Body: null</div>
</details>
<details class="interaction">
<summary class="logKey" logkey="_response_from_Embers_to_Client"> response from Embers to Client</summary>
<div contenteditable="true" ondblclick="document.execCommand('selectAll',false,null)"
class="logValue highlight HttpResponseWrapper">Response Code: 200
Headers: {null=[HTTP/1.1 200 OK], Server=[Jetty(9.3.0.M1)], Content-Length=[130], Date=[Mon, 05 Apr 2021 09:50:29 GMT], Content-Type=[text/html]}
Body: name,description,id,sql
allQueries,Shows all the available queries,1,select id, name, description, sql from queries order by name
</div>
</details>
<details class="interaction">
<summary class="logKey" logkey="Database_Table___queries_statisticsqueries_statistics">Database Table - queries_statisticsqueries_statistics</summary>
<div contenteditable="true" ondblclick="document.execCommand('selectAll',false,null)"
class="logValue highlight ResultSetWrapper"><table><tr><th>duration</th><th>result</th><th>date_executed</th><th>query_name</th><th>id</th></tr><tr><td>2</td><td>Number of rows returned: 1</td><td>2021-04-05 10:50:29.436</td><td>allQueries</td><td>1</td></tr></table></div>
</details>
</details>
</section>
</footer>
</section>
</section>
</article>
</main>
<footer>
<div class="footer">
<script src="xregexp.js" type="text/javascript"></script>
<script src="yatspec.js" type="text/javascript"></script>
</div>
</footer>
</body>
</html>