diff --git a/.github/workflows/build_pglite.yml b/.github/workflows/build_pglite.yml index 7fd808bf..f01058f4 100644 --- a/.github/workflows/build_pglite.yml +++ b/.github/workflows/build_pglite.yml @@ -126,6 +126,13 @@ jobs: run: | bash ./cibuild.sh demo-site + - name: Build docs + working-directory: ./docs + run: | + pnpm install + pnpm run docs:build + cp -r ./.vitepress/dist/* /tmp/web/ + - name: Upload Postgres to Github artifacts id: upload-postgres-wasm uses: actions/upload-artifact@v4 diff --git a/.gitignore b/.gitignore index 8e95d80d..e64fa62d 100644 --- a/.gitignore +++ b/.gitignore @@ -1,7 +1,7 @@ .DS_Store .vscode -/node_modules +node_modules /packages/pglite/dist /packages/pglite/pgdata-test /packages/pglite/package-lock.json @@ -11,3 +11,6 @@ /postgresql-16.3.tar.bz2 /postgresql-16.3 /postgresql + +docs/.vitepress/dist +docs/.vitepress/cache \ No newline at end of file diff --git a/cibuild.sh b/cibuild.sh index 0fef351f..9df39a50 100755 --- a/cibuild.sh +++ b/cibuild.sh @@ -382,29 +382,18 @@ do ;; demo-site) echo "==================== demo-site ==========================" + # Move all existing files to a subfolder + mkdir -p /tmp/web/x-term-repl + mv -r /tmp/web/* /tmp/web/x-term-repl/ - echo " -
-Test | -PGlite Memory | -PGlite IDB | -SQLite Memory | -SQLite IDB | -SQLite OPFS | -
---|---|---|---|---|---|
Test 1: insert small row | -0.050 | -16.905 | -0.030 | -6.156 | -3.315 | -
Test 2: select small row | -0.054 | -8.591 | -0.010 | -0.705 | -0.639 | -
Test 3: update small row | -0.044 | -8.674 | -0.009 | -0.705 | -0.811 | -
Test 4: delete small row | -0.097 | -17.026 | -0.024 | -3.891 | -2.825 | -
Test 5: insert 1kb row | -0.065 | -17.071 | -0.059 | -6.983 | -3.402 | -
Test 6: select 1kb row | -0.094 | -8.589 | -0.029 | -0.711 | -0.661 | -
Test 7: update 1kb row | -0.070 | -17.030 | -0.016 | -0.761 | -0.821 | -
Test 8: delete 1kb row | -0.081 | -17.037 | -0.034 | -6.886 | -3.349 | -
Test 9: insert 10kb row | -0.275 | -17.047 | -0.107 | -9.267 | -3.856 | -
Test 10: select 10kb row | -0.145 | -8.824 | -0.051 | -0.832 | -0.681 | -
Test 11: update 10kb row | -0.245 | -8.835 | -0.071 | -0.746 | -0.851 | -
Test 12: delete 10kb row | -0.081 | -17.006 | -0.021 | -11.224 | -4.079 | -
Test | -Memory | -Memory (Unlogged Tables) | -Emscripten IndexedDB FS | -
---|---|---|---|
Test 1: 1000 INSERTs | -0.020 | -0.013 | -0.054 | -
Test 2: 25000 INSERTs in a transaction | -0.322 | -0.277 | -0.351 | -
Test 2.1: 25000 INSERTs in single statement | -0.092 | -0.087 | -0.142 | -
Test 3: 25000 INSERTs into an indexed table | -0.336 | -0.325 | -0.421 | -
Test 3.1: 25000 INSERTs into an indexed table in single statement | -0.151 | -0.115 | -0.245 | -
Test 4: 100 SELECTs without an index | -0.200 | -0.200 | -0.254 | -
Test 5: 100 SELECTs on a string comparison | -0.431 | -0.431 | -0.457 | -
Test 6: Creating an index | -0.019 | -0.018 | -0.069 | -
Test 7: 5000 SELECTs with an index | -0.155 | -0.156 | -0.185 | -
Test 8: 1000 UPDATEs without an index | -0.087 | -0.089 | -0.131 | -
Test 9: 25000 UPDATEs with an index | -0.499 | -0.477 | -0.563 | -
Test 10: 25000 text UPDATEs with an index | -0.648 | -0.620 | -0.810 | -
Test 11: INSERTs from a SELECT | -0.088 | -0.075 | -0.151 | -
Test 12: DELETE without an index | -0.012 | -0.011 | -0.068 | -
Test 13: DELETE with an index | -0.033 | -0.011 | -0.138 | -
Test 14: A big INSERT after a big DELETE | -0.071 | -0.059 | -0.139 | -
Test 15: A big DELETE followed by many small INSERTs | -0.132 | -0.127 | -0.196 | -
Test 16: DROP TABLE | -0.002 | -0.002 | -0.053 | -
Test | -default | -Memory (sync) | -Memory (async) | -MemoryAsync | -IDBMinimal | -IDBMinimal relaxed | -IDBBatchAtomic | -IDBBatchAtomic relaxed | -OriginPrivateFileSystem | -AccessHandlePool | -
---|---|---|---|---|---|---|---|---|---|---|
Test 1: 1000 INSERTs (very slow on IDB & OPFS) | -0.064 | -0.035 | -0.051 | -0.055 | -2.384 | -2.588 | -1.094 | -0.939 | -18.847 | -24.67 | -
Test 2: 25000 INSERTs in a transaction | -0.082 | -0.077 | -0.12 | -0.098 | -0.14 | -0.105 | -0.15 | -0.107 | -0.141 | -0.137 | -
Test 3: 25000 INSERTs into an indexed table | -0.112 | -0.1 | -0.138 | -0.138 | -0.23 | -0.185 | -0.228 | -0.198 | -0.174 | -0.143 | -
Test 4: 100 SELECTs without an index | -0.106 | -0.104 | -0.17 | -0.187 | -0.185 | -0.281 | -0.185 | -0.275 | -0.285 | -0.103 | -
Test 5: 100 SELECTs on a string comparison | -0.454 | -0.451 | -0.546 | -0.584 | -0.549 | -0.553 | -0.546 | -0.548 | -0.545 | -0.452 | -
Test 6: Creating an index | -0.012 | -0.012 | -0.016 | -0.018 | -0.031 | -0.024 | -0.033 | -0.024 | -0.191 | -0.061 | -
Test 7: 5000 SELECTs with an index | -0.046 | -0.042 | -0.064 | -0.064 | -0.06 | -0.067 | -0.071 | -0.068 | -0.061 | -0.044 | -
Test 8: 1000 UPDATEs without an index | -0.033 | -0.032 | -0.055 | -0.058 | -0.062 | -0.057 | -0.059 | -0.056 | -0.077 | -0.053 | -
Test 9: 25000 UPDATEs with an index | -0.131 | -0.131 | -0.211 | -0.22 | -0.391 | -0.364 | -0.258 | -0.219 | -0.274 | -0.163 | -
Test 10: 25000 text UPDATEs with an index | -0.108 | -0.101 | -0.168 | -0.177 | -0.348 | -0.362 | -0.244 | -0.267 | -0.23 | -0.132 | -
Test 11: INSERTs from a SELECT | -0.049 | -0.047 | -0.057 | -0.062 | -0.311 | -0.33 | -0.347 | -0.358 | -0.171 | -0.102 | -
Test 12: DELETE without an index | -0.023 | -0.02 | -0.023 | -0.034 | -0.915 | -0.936 | -1.148 | -1.146 | -0.222 | -0.094 | -
Test 13: DELETE with an index | -0.037 | -0.038 | -0.044 | -0.049 | -0.298 | -0.365 | -0.161 | -0.217 | -0.31 | -0.065 | -
Test 14: A big INSERT after a big DELETE | -0.037 | -0.036 | -0.045 | -0.047 | -0.221 | -0.169 | -0.207 | -0.21 | -0.175 | -0.084 | -
Test 15: A big DELETE followed by many small INSERTs | -0.029 | -0.031 | -0.043 | -0.045 | -0.138 | -0.138 | -0.083 | -0.137 | -0.189 | -0.058 | -
Test 16: DROP TABLE | -0.002 | -0.003 | -0.002 | -0.004 | -0.096 | -0.163 | -0.098 | -0.144 | -0.61 | -0.077 | -
Test | -SQLite In-Memory | -SQLite On-Disk | -Postgres | -
---|---|---|---|
Test 1: 1000 INSERTs | -0.002 | -0.288 | -0.007 | -
Test 2: 25000 INSERTs in a transaction | -0.022 | -0.019 | -0.114 | -
Test 2.1: 25000 INSERTs in single statement | -0.019 | -0.02 | -0.053 | -
Test 3: 25000 INSERTs into an indexed table | -0.035 | -0.04 | -0.383 | -
Test 3.1: 25000 INSERTs into an indexed table in single statement | -0.025 | -0.029 | -0.29 | -
Test 4: 100 SELECTs without an index | -0.076 | -0.078 | -0.094 | -
Test 5: 100 SELECTs on a string comparison | -0.268 | -0.429 | -0.259 | -
Test 6: Creating an index | -0.007 | -0.011 | -0.01 | -
Test 7: 5000 SELECTs with an index | -0.01 | -0.01 | -0.078 | -
Test 8: 1000 UPDATEs without an index | -0.018 | -0.021 | -0.047 | -
Test 9: 25000 UPDATEs with an index | -0.047 | -0.056 | -0.307 | -
Test 10: 25000 text UPDATEs with an index | -0.032 | -0.041 | -0.416 | -
Test 11: INSERTs from a SELECT | -0.022 | -0.027 | -0.072 | -
Test 12: DELETE without an index | -0.01 | -0.023 | -0.007 | -
Test 13: DELETE with an index | -0.017 | -0.021 | -0.019 | -
Test 14: A big INSERT after a big DELETE | -0.017 | -0.021 | -0.048 | -
Test 15: A big DELETE followed by many small INSERTs | -0.008 | -0.01 | -0.067 | -
Test 16: DROP TABLE | -0.001 | -0.003 | -0.004 | -
opfs-worker.js
worker-process.js