TPC-E Benchmark Overview TPC - E TPC-PR Subcommittee Feb 2007 © 2007 TPC TPC-E Goals •OLTP Database-centric workload •Comparability of results (*) •Familiar business model – easy to understand •Reduce cost/complexity of running benchmark TPC - E •Enhance schema complexity •Encourage DB uses which are more representative of what customers do •Address aspects of PDG (*) TPC-E results are intended for OLTP database testing and are not an indicator for past or future market performance, nor should they be used as such. Business Model – Financial Market Stock Exchange Customers Customer Request Brokerage Response Market Response Brokerage Request Ticker Feed TPC - E Synchronous Txns •C2B Environment •Customer Initiated •Request a Trade •Check Status of Trade •Portfolio Summary Brokerage Response Market Response Asynchronous Txns •B2B Environment •Send Trade to Market •Receive Trade Result Ticker Feed Brokerage HouseBrokerage Customer Request Request Business Model – Financial Market DRIVER Stock Exchange Customers Customer Request Brokerage Response Market Response Brokerage Request Ticker Feed TPC - E SUT Brokerage Response Market Response Ticker Feed Brokerage House Brokerage Customer Request Request Business Model – Comparison TPC - E TPC-C •Wholesale supplier •Organized by •Warehouses •Districts •Customers TPC-E •Brokerage house •Organized by •Customers •Accounts •Securities TPC - E Database Tables Customer Broker Market ACCOUNT_PERMISSION BROKER COMPANY SECTOR CUSTOMER CASH_TRANSACTION COMPANY_COMPETITOR SECURITY CUSTOMER_ACCOUNT CHARGE DAILY_MARKET CUSTOMER_TAXRATE COMMISSION_RATE EXCHANGE HOLDING SETTLEMENT FINANCIAL Dimension HOLDING_HISTORY TRADE INDUSTRY ADDRESS HOLDING_SUMMARY TRADE_HISTORY LAST_TRADE STATUS_TYPE WATCH_ITEM TRADE_REQUEST NEWS_ITEM TAXRATE WATCH_LIST TRADE_TYPE NEWS_XREF ZIP_CODE TPC - E Database Scaling Customer Broker Market ACCOUNT_PERMISSION BROKER COMPANY SECTOR CUSTOMER CASH_TRANSACTION COMPANY_COMPETITOR SECURITY CUSTOMER_ACCOUNT CHARGE DAILY_MARKET CUSTOMER_TAXRATE COMMISSION_RATE EXCHANGE HOLDING SETTLEMENT FINANCIAL Dimension HOLDING_HISTORY TRADE INDUSTRY ADDRESS HOLDING_SUMMARY TRADE_HISTORY LAST_TRADE STATUS_TYPE WATCH_ITEM TRADE_REQUEST NEWS_ITEM TAXRATE WATCH_LIST TRADE_TYPE NEWS_XREF ZIP_CODE Legend: Fixed Tables Growing Tables Scaling Tables TPC - E Database Schema Summary Characteristic TPC-E TPC-C Tables 33 9 Columns 188 92 Min Cols / Table 2 3 Max Cols / Table 24 21 Data Type Count Many 4 Data Types UID, CHAR, NUM, DATE, BOOL, LOB UID, CHAR, NUM, DATE Primary Keys 33 8 Foreign Keys 50 9 Tables w/ Foreign Keys 27 7 Check Constraints 22 0 Referential Integrity Yes No Database – Mile High View COMPANY_COMPETITOR PK,FK1,I1 PK,FK2 PK,FK3 COMPANY CP_CO_ID CP_COMP_CO_ID CP_IN_ID PK,U2,U1 CO_ID FK3 U1 FK2,U2 FK1 INDUSTRY PK CO_ST_ID CO_NAME CO_SC_ID CO_SP_RATE CO_CEO CO_AD_ID CO_DESC CO_OPEN_DATE IN_ID FINANCIAL PK,FK1 PK PK PK COMPANY_INDUSTRY BROKER ST_ID PK,U1 ST_NAME FK1 U1 PK PK U1 SC_NAME FK1 LAST_TRADE PK,FK1 NI_HEADLINE NI_SUMMARY NI_ITEM NI_DTS NI_SRC NI_AUTH U2,U1 FK3 FK4 FK2,U2 CUSTOMER_ACCOUNT ZC_CODE PK,U2,U1 ZC_TOWN ZC_DIV NEWS_ITEM NI_ID TRADE PK,U2,U1 T_ID ZIP_CODE CA_ID FK1,U1 FK1,U2 CA_B_ID FK2,U2,U1 CA_C_ID CA_NAME CA_TAX_ST CA_BAL ADDRESS PK TR_DTS TR_ST_ID TR_TT_ID TR_S_SYMB TR_QTY TR_BID_PRICE TR_CA_ID FK3,U2 FK5,U2 FK2,U2 U2 FK1,U1 SECTOR SC_ID B_ST_ID B_NAME B_NUM_TRAD_YTD B_COMM_YTD STATUS_TYPE foreign key relationship lines omitted for diagram clarity CI_CO_ID CI_IN_ID PK,U1 TRADE_REQUEST B_ID PK,FK4,U1,U2 TR_T_ID FI_QTR_START_DATE FI_REV FI_NET_EARN FI_BASIC_EPS FI_DILUT_EPS FI_MARGIN FI_INVENT FI_ASSETS FI_LIAB FI_DIVID FI_OUT_BASIC FI_OUT_DILUT IN_NAME PK,FK1 PK,FK2 STATUS_TYPE FI_CO_ID FI_YEAR FI_QTR AD_ID AD_LINE1 AD_LINE2 AD_ZC_CODE AD_CTRY T_DTS T_ST_ID T_TT_ID T_IS_CASH T_S_SYMB T_QTY T_BID_PRICE T_CA_ID T_EXEC_NAME T_TRAD_PRICE T_CHRG T_COMM T_TAX T_LIFO TRADE_TYPE PK TT_ID TT_NAME TT_IS_SELL TT_IS_MRKT CHARGE PK,FK1 PK SETTLEMENT LT_S_SYMB PK,FK2,U1 SE_T_ID LT_DTS LT_PRICE LT_OPEN_PRICE LT_VOL FK1,U1 CH_TT_ID CH_C_TIER CH_CHRG SE_CA_ID SE_CASH_TYPE SE_CASH_DUE_DATE SE_AMT COMMISSION_RATE CASH_TRANSACTION EXCHANGE NEWS_XREF CUSTOMER PK EX_ID FK1 EX_NAME EX_NUM_SYMB EX_OPEN EX_CLOSE EX_DESC EX_AD_ID PK,FK2,U1 NX_NI_ID PK,FK1,U1 NX_CO_ID PK,U1 DM_DATE PK,FK1,U1 DM_S_SYMB TPC - E DM_CLOSE DM_HIGH DM_LOW DM_VOL PK,U1 S_SYMB C_ID U1 FK2 C_TAX_ID C_ST_ID C_L_NAME C_F_NAME C_M_NAME C_GNDR C_TIER C_DOB C_AD_ID C_CTRY_1 C_AREA_1 C_LOCAL_1 C_EXT_1 C_CTRY_2 C_AREA_2 C_LOCAL_2 C_EXT_2 C_CTRY_3 C_AREA_3 C_LOCAL_3 C_EXT_3 C_EMAIL_1 C_EMAIL_2 S_ISSUE S_ST_ID S_NAME FK2,U1 S_EX_ID FK1,U1 S_CO_ID S_NUM_OUT S_START_DATE S_EXCH_DATE S_PE S_52WK_HIGH S_52WK_HIGH_DATE S_52WK_LOW S_52WK_LOW_DATE S_DIVID S_YIELD FK1 U1 FK3 CUSTOMER_TAXRATE TAXRATE PK TX_ID PK,FK2 PK,FK1 CX_TX_ID CX_C_ID TX_NAME TX_RATE TRADE_HISTORY PK,U1 SECURITY DAILY_MARKET PK,FK2,U1 CT_T_ID FK1,U1 U1 CT_CA_ID CT_DTS CT_AMT CT_NAME PK,FK2,U1 TH_T_ID PK,FK1,U1 TH_ST_ID U1 PK,FK2 PK,FK1 WI_WL_ID WI_S_SYMB PK WL_ID FK1 WL_C_ID PK,FK1 PK CR_TO_QTY CR_RATE HOLDING PK,FK3,U2,U1 H_T_ID FK1,U2,U1 FK2,U2,U1 U1 U2 H_CA_ID H_S_SYMB H_BUY_DTS H_PRICE H_QTY HOLDING_HISTORY PK,FK1,U1 HH_H_T_ID PK,FK2,U1 HH_T_ID ACCOUNT_PERMISSION WATCH_LIST CR_C_TIER CR_TT_ID CR_EX_ID CR_FROM_QTY TH_DTS HH_BEFORE_QTY HH_AFTER_QTY WATCH_ITEM PK PK,FK2 PK,FK1 PK AP_CA_ID AP_TAX_ID AP_ACL AP_L_NAME AP_F_NAME Broker Customer Market Dimension Database – Content •Populated with pseudo-real data •Distributions based on: –2000 U.S. and Canada census data (*) •Used for generating name, address, gender, etc. •Introduces natural data skew –Actual listings on the NYSE and NASDAQ TPC - E •Benefits –Realistic looking data –Compressible for backup testing, etc. –Closer match to actual customer databases –Anticipate usage well beyond benchmark (*) only names of 2000 census have been used – all other data are fictional and any similarities are purely coincidental Database – Content •Sample data from TPC-C CUSTOMER table C_FIRST C_MIDDLE C_LAST C_STREET_1 C_CITY RONpTGcv5ZBZO8Q OE BARBARABLE bR7QLfDBhZPHlyDXs OmWlmelzIJ0GeP kYM e8u6FMxFLtt6p Q OE BARBARPRI eEbgKxoIzx99ZTD S 4V1t1VmdVcXyoTOMwpPz bTUkSuVQGdXLjGe OE BARBARPRES QCGLjWnsqSQPN D S jVHBwIGFh2k oTOMwpPz 18AEf3ObueKvubUX OE BARBARESE JnBSg4RtZbALYu S 5g8XMnlegn oTOMwpPz mFFsJYeYE6AR bUX OE BARBARANTI MLEwwdy3dXfqngFcE yVVR4iEtj0ADEwe wpPz • Sample data from TPC-E CUSTOMER table TPC - E C_TAX_ID C_L_NAME C_F_NAME C_M_NAME C_GNDR C_DOB C_EMAIL_1 757FI2006HD923 Mexicano Courtney T F 1997-11-30 CMexicano@hotmail.com 922SN3775RQ823 Udley Judith F F 1954-09-27 JUdley@earthlink.com 006GT3444BE624 Buchanan John R M 1971-06-13 JBuchanan@msn.com 181UZ4114LR434 Soloman Clinton D M 1938-02-27 CSoloman@rr.com 355IE4773VF335 Orner Harry P M 1974-11-15 Horner@attbi.com Database – Content •Database creation is vendor specific, but… •Database population can be vendor neutral TPC - E •TPC-E includes a data generator for database loading •C++ code to generate data •MSSQL ODBC interface provided •Flat file generation provided •Sponsor is free to customize interface Transactions - Overview TPC - E Name Symbol Access Description Broker-Volume BV RO DSS-type medium query Customer-Position CP RO “What am I worth?” Market-Feed MF RW Processing of Stock Ticker Market-Watch MW RO “What’s the market doing?” Security-Detail SD RO Details about a security Trade-Lookup TL RO Look up historical trade info Trade-Order TO RW Enter a stock trade Trade-Result TR RW Completion of a stock trade Trade-Status TS RO Check status of trade order Trade-Update TU RW Correct historical trade info Transactions – Runtime Flow Driver System Under Test (SUT) Data Maintenance Brokerage House sT DM DM eT Customer Emulator MW BV CP sT TS TU CP TL SD BV MW TS TL eT TU SD sT TO TO eT Orders Market Exchange Emulator Asynch. Send To Market Interface Triggered Limit Orders Process sT Trade Confirmation TR TR ACK Ticker eT TPC - E Market Order Limit Orders Ticker sT MF MF eT ACK Limit Order “Real-world” basis for TPC-E Examples of User Interfaces Modeled Business Workstation Network Laptop Hand-held Stock Market Exchange Presentation Services Application And Business Logic Services Network Database Services Legend Customer Sponsor Provided TPC - E Cell phone Example of External Business Stock Market Abstraction of “Real-world” Modeled Business User Interfaces Network Market Exchange Presentation Services Application And Business Logic Services Network Database Services Legend Customer Sponsor Provided Stock Market TPC - E • Points to remember – Data generator code provide by TPC – PDG requested User Interface not be present – Goal: Database-centric workload Functional Components of TPC-E Driving and Reporting Sponsor Provided CE… EGenDriver MEE… EGenDriverCE …CE DM… EGenDriverMEE EGenDriverDM …MEE TPC Defined Interfaces …DM EGenDriver Connector Sponsor Provided Network EGenTxnHarness Connector EGenTxnHarness Sponsor Provided TPC-E Logic and Frame Calls TPC Defined Interface Frame Implementation Legend TPC - E Database Interface Commercial Product Sponsor Provided Sponsor Provided TPC Provided DBMS Database Logic Commercial Product TPC Defined Interface Driver & System Under Test (SUT) Driving and Reporting Driver CE… MEE… DM… EGenDriverCE EGenDriverMEE EGenDriverDM …CE …MEE …DM EGenDriver Connector Mandatory Network Between Driver and Tier A TPC-E Logic and Frame Calls Tier A System Under Test (SUT) Frame Implementation Legend Database Interface Sponsor Provided TPC Provided Tier B TPC - E EGenTxnHarness Connector DBMS Database Logic Commercial Product TPC Defined Interface Implementation Details Legend TPC Provided Sponsor Provided • Transaction Harness Commercial Product EGenTxnHarness Input from Driver TPC-E Transaction TPC-E Logic Frame Call Frame 1 Frame Return TPC-E Logic DBMS TPC-E Logic Frame Call Frame N TPC - E Output to Driver Frame Return TPC-E Logic – Transaction pseudo code provided – C++ class for each transaction – The Harness defines • • • • Inputs Outputs Transaction logic “Frames” Sample Implementation Driver Tier B Tier A Data App. Server Network Mandatory Network between Driver and Tier A Data App. Server TPC - E Data Database Server App. Server System Under Test Summary - Highlights •Financial business model •Rich transaction set •Major components provided TPC - E •Diverse, realistic schema •Extensive use of non-primary key access •Foreign key relationships •Complex DML •Referential integrity •Availability requirements •Storage media must be fault tolerant •Practical implication: RAID-1 or RAID-5 TPC - E Summary - Benefits • Server-centric workload with strong DB focus • Broader coverage: database functions, schema, features • Realistic application transaction model • Ease of benchmarking: quicker startup, lower cost • Reduced I/O requirements • Comparability of results • Realistic database schema, population, and transactions • Learns from TPC history • Specification provides code where sponsor creativity not being tested Trademarks and Copyright TPC - E • TPC, TPC Benchmark and TPC-C are trademarks of the Transaction Processing Performance Council. All other materials are © 2007 TPC. All rights reserved.