This topic describes the import and query performance of AnalyticDB for PostgreSQL in Serverless mode.

Note The TPC-H performance tests described in this topic are implemented based on the TPC-H benchmark tests but cannot meet all requirements of TPC-H benchmark tests. Therefore, the test results described in this topic are incomparable with the published TPC-H benchmark test results.

Configuration information

An AnalyticDB for PostgreSQL instance in Serverless mode that is used for testing provides the following configurations:

  • Compute node specifications: 4 cores, 16 GB
  • Number of compute nodes: 4

Data import performance

This test uses two methods to import large tables: COPY and Foreign Data Wrapper (FDW) on Object Storage Service (OSS). The import performance of AnalyticDB for PostgreSQL in Serverless mode is tested by executing different numbers of concurrent queries.

  • Test table:

    This test uses the lineitem table for TPC-H and generates 500 GB of test data. For more information about how to generate test data, see TPC-H.

  • Test methods:

The following table describes the test results.

Test method One concurrent query Four concurrent queries Eight concurrent queries
COPY 37 MB/s 125 MB/s 128 MB/s
FDW on OSS 47 MB/s 86 MB/s 110 MB/s

Data query performance

This test uses the QGen tool for TPC-H and respectively generates 10 GB and 500 GB of test data. The query duration of AnalyticDB for PostgreSQL in Serverless mode is tested and compared with that of AnalyticDB for PostgreSQL in elastic storage mode. For more information about the test, see TPC-H.

The following table describes the query performance test results for 10 GB of test data.

Query statement Elastic storage mode Serverless mode
Q1 15,215.417 ms 8,468.049 ms
Q2 2,949.254 ms 3,874.710 ms
Q3 3,979.300 ms 2,652.187 ms
Q4 6,059.405 ms 2,561.089 ms
Q5 6,833.062 ms 4,297.496 ms
Q6 482.411 ms 578.026 ms
Q7 6,228.587 ms 4,301.195 ms
Q8 6,544.251 ms 5,011.280 ms
Q9 11,240.953 ms 7,742.912 ms
Q10 3,549.456 ms 2,767.839 ms
Q11 1,361.575 ms 1,488.599 ms
Q12 1,661.359 ms 1,842.725 ms
Q13 5,383.167 ms 5,018.539 ms
Q14 744.585 ms 751.640 ms
Q15 1,344.129 ms 1,897.243 ms
Q16 1,550.342 ms 1,984.808 ms
Q17 19,425.750 ms 15,709.382 ms
Q18 19,417.051 ms 6,803.475 ms
Q19 4,762.443 ms 2,375.202 ms
Q20 3,434.726 ms 3,485.165 ms
Q21 14,496.656 ms 8,104.987 ms
Q22 3,174.644 ms 2,918.874 ms
Total duration 2 minutes and 19.951 seconds 1 minute and 34.748 seconds

The following table describes the query performance test results for 500 GB of test data.

Query statement Elastic storage mode Serverless mode
Q1 776,749.919 ms 655,198.377 ms
Q2 127,436.833 ms 87,954.528 ms
Q3 323,528.962 ms 664,481.555 ms
Q4 351,981.303 ms 200,034.509 ms
Q5 427,701.721 ms 609,339.053 ms
Q6 110,562.730 ms 19,149.394 ms
Q7 675,657.163 ms 305,690.833 ms
Q8 516,443.454 ms 1,033,242.151 ms
Q9 1,531,569.731 ms 999,391.734 ms
Q10 295,668.016 ms 141,176.254 ms
Q11 141,573.826 ms 74,402.558 ms
Q12 249,247.709 ms 88,836.774 ms
Q13 315,628.505 ms 177,885.452 ms
Q14 187,791.651 ms 39,034.109 ms
Q15 460,263.848 ms 82,863.306 ms
Q16 123,408.319 ms 54,713.206 ms
Q17 4,650,424.484 ms 2,215,070.817 ms
Q18 1151063.573 ms 548,049.730 ms
Q19 260,702.969 ms 85,419.149 ms
Q20 549,780.389 ms 213,492.958 ms
Q21 1,103,378.860 ms 456,781.416 ms
Q22 223,275.303 ms 86,325.201 ms
Total duration 242 minutes and 34.602 seconds 147 minutes and 19.298 seconds