Digesting an Open-Source Fair-Use TPC-E Implementation ... - PGCon
Digesting an Open-Source Fair-Use TPC-E Implementation ... - PGCon
Digesting an Open-Source Fair-Use TPC-E Implementation ... - PGCon
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
<strong>Digesting</strong> <strong>an</strong> <strong>Open</strong>-<strong>Source</strong><br />
<strong>Fair</strong>-<strong>Use</strong> <strong>TPC</strong>-E <strong>Implementation</strong>:<br />
DBT-5<br />
2007-May, Ottawa<br />
Mark Wong<br />
Rilson Nascimento<br />
<strong>PGCon</strong> 2007
Introductions<br />
Mark Wong<br />
Database Perform<strong>an</strong>ce specialist<br />
Previously worked at OSDL (presently, Linux Foundation)<br />
Rilson Nascimento<br />
MSc C<strong>an</strong>didate in the Federal University of Pernambuco,<br />
Brazil<br />
Previously worked at Itautec Perform<strong>an</strong>ce Lab<br />
2
Table of Contents<br />
<strong>TPC</strong>-E Overview<br />
Workload Architecture<br />
Experimental Results<br />
Research<br />
Future Work<br />
3
Question Policy<br />
Interrupt us if something is unclear<br />
Keep long generic questions to the end<br />
Approach us during the conference<br />
Write us<br />
markwkm@gmail.com<br />
rilson.nascimento@gmail.com<br />
4
Why <strong>TPC</strong>-E?<br />
http://www.tpc.org/tpce/spec/<strong>TPC</strong>Epresentation.ppt<br />
<strong>TPC</strong>-C is over 14 years old<br />
Not practical to modify existing workload<br />
Tr<strong>an</strong>saction are too lightweight by today's st<strong>an</strong>dards<br />
CPU perform<strong>an</strong>ce grew according to Moore's Law<br />
Disk latency did not<br />
Reduce cost/complexity of running benchmark<br />
Encourage DB uses which is more representative of what<br />
customer do<br />
5
<strong>TPC</strong>-E vs. DBT-5<br />
<strong>TPC</strong>-E is a benchmarking specification for generating<br />
marketing collateral<br />
DBT-5 a test kit to help improve PostgreSQL<br />
6
<strong>TPC</strong>-E Overview<br />
<strong>TPC</strong>-E Goals<br />
OLTP Database-centric workload<br />
Comparability of results<br />
Familiar business model – easy to underst<strong>an</strong>d<br />
Reduce cost of running benchmark<br />
Enh<strong>an</strong>ce schema complexity<br />
Be more representative to what customers do<br />
7
<strong>TPC</strong>-E Overview (2)<br />
Business Model – Fin<strong>an</strong>cial Market<br />
8
<strong>TPC</strong>-E Overview (3)<br />
Business Model – Fin<strong>an</strong>cial Market<br />
Driver<br />
SUT<br />
9
<strong>TPC</strong>-E Overview (4)<br />
Business Model – Fin<strong>an</strong>cial Market<br />
10
<strong>TPC</strong>-E Overview (5)<br />
Business Model – Comparison with <strong>TPC</strong>-C<br />
<strong>TPC</strong>-C<br />
Wholesale supplier<br />
Org<strong>an</strong>ized by<br />
Warehouses<br />
Districts<br />
Customers<br />
<strong>TPC</strong>-E<br />
Brokerage House<br />
Org<strong>an</strong>ized by<br />
Customers<br />
Accounts<br />
Securities<br />
Comp<strong>an</strong>ies<br />
11
<strong>TPC</strong>-E Overview (6)<br />
Database Schema – Comparison with <strong>TPC</strong>-C<br />
C h a r a c t e r i s t i c<br />
T a b l e s<br />
C o l u m<br />
n s<br />
M i n C o l s / T a b l e<br />
M a x C o l s / T a b l e<br />
D<br />
a t a T y p e C o u n t<br />
D<br />
a t a T y p e s<br />
P r i m<br />
a r y K e y s<br />
F o r e i g n K e y s<br />
T a b l e s w / F o r e i g n<br />
K e y s<br />
C h e c k C o n s t r a i n t s<br />
R e f e r e n t i a l<br />
I n t e g r i t y<br />
T P C - E<br />
3 3<br />
1 8 8<br />
2<br />
2 4<br />
M<br />
a n y<br />
U I D , C H A R , N U M ,<br />
D A T E , B O O L , L O B<br />
3 3<br />
5 0<br />
2 7<br />
2 2<br />
Y e s<br />
T P C - C<br />
9<br />
9 2<br />
3<br />
2 1<br />
4<br />
U I D , C H A R , N U M ,<br />
D<br />
A T E<br />
8<br />
9<br />
7<br />
0<br />
N<br />
o<br />
12
<strong>TPC</strong>-E Overview (7)<br />
Database Tables <strong>an</strong>d Scaling<br />
C u s t o m e r B r o k e r M a r k e t<br />
A C C O U N T _ P E R M I S S I O N B R O K E R C O M P A N Y S E C T O R<br />
C U S T O M E R C A S H _ T R A N S A C T I O N C O M P A N Y _ C O M P E T I T O R S E C U R I T Y<br />
C U S T O M E R _ A C C O U N T C H A R G E D A I L Y _ M A R K E T<br />
C U S T O M E R _ T A X R A T E C O M M I S S I O N _ R A T E E X C H A N G E<br />
H O L D I N G S E T T L E M E N T F I N A N C I A L D i m e n s i o n<br />
H O L D I N G _ H I S T O R Y T R A D E I N D U S T R Y A D D R E S S<br />
H O L D I N G _ S U M M A R Y T R A D E _ H I S T O R Y L A S T _ T R A D E S T A T U S _ T Y P E<br />
W A T C H _ I T E M T R A D E _ R E Q U E S T N E W S _ I T E M T A X R A T E<br />
W A T C H _ L I S T T R A D E _ T Y P E N E W S _ X R E F Z I P _ C O D E<br />
L e g e n d : F i x e d T a b l e s G r o w i n g T a b l e s S c a l i n g T a b l e s<br />
13
<strong>TPC</strong>-E Overview (8)<br />
Tr<strong>an</strong>sactions<br />
14
<strong>TPC</strong>-E Overview (9)<br />
Metrics<br />
Perform<strong>an</strong>ce (throughput), expressed in tpsE<br />
Price/Perform<strong>an</strong>ce, expressed in price/tpsE<br />
Availability Date, when all products necessary to achieve the<br />
stated perform<strong>an</strong>ce will be available<br />
15
<strong>TPC</strong>-E Overview (10)<br />
Sample Test Configuration<br />
16
<strong>TPC</strong>-E Overview (11)<br />
Sample Test Configuration, Variation I<br />
17
<strong>TPC</strong>-E Overview (12)<br />
Sample Test Configuration, Variation II<br />
18
<strong>TPC</strong>-E Overview (13)<br />
Sample Test Configuration, Variation III<br />
19
<strong>TPC</strong>-E Overview – Highlights <strong>an</strong>d Benefits<br />
Fin<strong>an</strong>cial business model<br />
Rich tr<strong>an</strong>saction set<br />
Diverse, realistic schema<br />
Server-centric workload with DB focus<br />
Realistic application model<br />
Rebal<strong>an</strong>ced hardware configuration<br />
Specification provides code where sponsor creativity is not<br />
being tested<br />
20
DBT-5 Architecture<br />
21
DBT-5 Architecture - Loader<br />
Database creation is vendor specific, but...<br />
Database population c<strong>an</strong> be vendor neutral<br />
<strong>TPC</strong>-E includes a data generator for database loading<br />
C++ code to generate data<br />
Flat file generation is provided<br />
Sponsor is free to create to customize interface<br />
Libpqxx: C++ API for PostgreSQL<br />
22
Experimental Results<br />
Test bed<br />
Processor: Intel(R) Xeon(TM) CPU 2.80GHz w/HT<br />
Memory: 3 GB<br />
Disk: 14 disks in hw RAID 0 (data)<br />
Operating System: Linux 2.6.20-gentoo-r4<br />
Database Engine: PostgreSQL 8.2.3<br />
Database Size: 2806 MB (1000 customers, 50 ITD)<br />
23
Experimental Results – DBT-5 Report<br />
24
Experimental Results<br />
Response Time (s)<br />
Tr<strong>an</strong>saction % Average : 90th % Total Rollbacks %<br />
----------------- ----- ----------------- ----------- ----------- ------<br />
Trade Order 10.21 0.021 : 0.043 3869 38 0.99<br />
Trade Result 9.59 0.040 : 0.083 3635 0 0.00<br />
Trade Lookup 8.08 0.346 : 0.945 3063 0 0.00<br />
Trade Update 1.96 0.313 : 0.677 743 0 0.00<br />
Trade Status 19.03 0.006 : 0.010 7212 0 0.00<br />
Customer Position 12.89 0.005 : 0.009 4885 0 0.00<br />
Broker Volume 4.84 0.003 : 0.004 1835 0 0.00<br />
Security Detail 14.43 0.014 : 0.018 5467 0 0.00<br />
Market Feed 0.96 0.055 : 0.090 363 0 0.00<br />
Market Watch 17.99 0.009 : 0.017 6817 0 0.00<br />
Data Mainten<strong>an</strong>ce n/a 0.036 : 0.122 9 0 0.00<br />
----------------- ----- ----------------- ----------- ----------- ------<br />
2.02 trade-result tr<strong>an</strong>sactions per second (TRTPS)<br />
30.0 minute duration<br />
20 total unknown errors<br />
1 second(s) ramping up<br />
25
Experimental Results – Response Time Plots<br />
26
Experimental Results – System Statistics<br />
27
Research<br />
A scientific article portraying DBT-5 was accepted in the<br />
27th Brazili<strong>an</strong> Computer Society Conference, that will be<br />
held in Rio de J<strong>an</strong>eiro in June 2007<br />
http://www.sbc.de9.ime.eb.br/en/index.php?view=wperforma<br />
nce&from=eventos&l<strong>an</strong>g=en<br />
Rilson's Master's dissertation is employing DBT-5:<br />
Synthesizing Representative I/O Workloads for <strong>TPC</strong>-E<br />
28
Future Work<br />
Update the workload to the latest <strong>TPC</strong>-E specification<br />
EGen<br />
Functions<br />
Write the Functions in C (in progress)<br />
Tune indexes/functions<br />
Support other databases<br />
29
Resources<br />
DBT-5<br />
svn co https://osdldbt.svn.sourceforge.net/svnroot/osdldbt/trunk/dbt5 dbt5<br />
libpqxx: C++ API for PostgreSQL<br />
http://pqxx.org/<br />
<strong>TPC</strong>-E Specification<br />
http://www.tpc.org/tpce/spec/<strong>TPC</strong>E-v0.32.2g.pdf (PDF)<br />
http://www.tpc.org/tpce/spec/<strong>TPC</strong>E-v0.32.2g.doc (DOC)<br />
30
Bibliography<br />
<strong>TPC</strong> BENCHMARK E St<strong>an</strong>dard Specification Version<br />
1.0.0<br />
<strong>TPC</strong> Site - www.tpc.org<br />
Do Nascimento, R. O., M. Wong <strong>an</strong>d P. R. M. Maciel. DBT-<br />
5: A <strong>Fair</strong> Usage <strong>Open</strong> <strong>Source</strong> <strong>TPC</strong>-E <strong>Implementation</strong> for<br />
Perform<strong>an</strong>ce Evaluation of Computer Systems. XXVII<br />
Brazili<strong>an</strong> Computer Society Conference, 2007. (to appear)<br />
31
Th<strong>an</strong>k you! :)<br />
markwkm@gmail.com<br />
rilson.nascimento@gmail.com<br />
<strong>PGCon</strong> 2007, Ottawa<br />
32