Commit Graph

4562 Commits

Author SHA1 Message Date
dan
4eb626350a Fix a problem in fts5 caused by a COMMIT involving fts5 data that immediately follows a ROLLBACK TO that does not.
FossilOrigin-Name: 55c61f6a8d6a1bc79497b05669beac5c5397b06382bf24b6bec54845962d219b
2024-01-02 21:08:25 +00:00
stephan
aff7664939 Elaborate on the various build flavors used by ext/wasm/. Doc changes only.
FossilOrigin-Name: d489232aa492618d4c8e5817addb2323d0ca067742d7140216914239a66fb221
2024-01-02 09:20:53 +00:00
stephan
3d4d3fb59d Update and clean up the in-makefile docs for ext/wasm.
FossilOrigin-Name: 7a7b295e6d7e95ee4a46cc42761895d11700ab295870c5a4380072bb4a5b7099
2024-01-02 09:03:42 +00:00
stephan
fe1d8210c7 Back out [99d11e6d0ae6] (enabling of STAT4 in WASM/JNI), per /chat discussion.
FossilOrigin-Name: cd7929ee2e2c305475fa5a4dff2edaccf90067126ef04a1c2714cf464925453f
2024-01-01 23:28:02 +00:00
stephan
307f326ba3 JNI: move the ByteBuffer-using APIs from public to package visibility for the time being because they have UB-inducing possibilities which need to be worked out. Update test code to account for a change in custom FTS5 columntext() impls.
FossilOrigin-Name: dc501275fcfab3ad9b6ebbadf7588b225a9dd07a0abac5be83d96f15bfba99e9
2024-01-01 06:58:32 +00:00
stephan
805cd395a9 WASM: various build cleanups and add initial infrastructure for a build which elides the oo1 API and its dependents (worker1 and promiser). Sidebar: an attempt was made to move generation of the build rules to an external script, but the mixed-mode make/script was even less legible than the $(eval) indirection going on in the makefile.
FossilOrigin-Name: 563d313163c02b398ae85b7c2ed231019a14e006726f09a7c1f294a58bf4363f
2024-01-01 05:58:47 +00:00
stephan
7a482b3bcd Use SQLITE_ENABLE_STAT4 in both the WASM and JNI builds.
FossilOrigin-Name: 99d11e6d0ae687ff6bac5119027f7b04d5e7185214e79cf8c56289cfa809b0f9
2023-12-31 04:01:36 +00:00
stephan
e24cd27c39 Minor doc touchup in the JS bits.
FossilOrigin-Name: 8d2120c35425081e2158d6a8a6b083c4adf8d694046b2d98f5fd235520920432
2023-12-29 04:29:07 +00:00
dan
751c4e2152 Update fts5origintext4.test to work with SQLITE_DIRECT_OVERFLOW_READ.
FossilOrigin-Name: 15ed002aed12556aeb9bbe537c4ba839f0c95bac65a69d03401b37cc3fd11b92
2023-12-28 20:54:12 +00:00
drh
42203e1b75 Fix harmless compiler warnings in FTS5.
FossilOrigin-Name: 3cd5ef44e40570c357f913a9483fa1cd72e7f2827a5ed5826bff99febae213b1
2023-12-28 16:25:48 +00:00
dan
d82320ac9a Ensure that the xColumnText(), xQueryPhrase() and xPhraseFirstColumn() APIs all return SQLITE_RANGE if they are passed a bad column or phrase number.
FossilOrigin-Name: 1a8a9b1c89519d265869251e8b6d3c5db733f0d3a7dea6c7962811a8f1157dff
2023-12-26 15:52:40 +00:00
drh
c1805ab222 Avoid signed integer overflow during integrity_check of FTS5.
FossilOrigin-Name: 5937df3b25799eceaadfb04d7226c9995d44c8d8edb5ac3ad02af9d7e3570726
2023-12-24 11:31:20 +00:00
dan
0810150532 Fix a usan complaint about signed integer overflow.
FossilOrigin-Name: e65907e0279f4814ec957f0790777d8b94a86926cd27c52442b311b27efc0185
2023-12-22 14:47:30 +00:00
drh
4449a1b66d Fix harmless compiler warning in the randomjson.c extension.
FossilOrigin-Name: debe7060b16669ada7304ffb9bf7616c8fa30bd286d8be871ed17fd6d64a3d4c
2023-12-19 15:06:40 +00:00
drh
0a46ff995b Ensure that all object labels for individual objects generated by
randomjson.c are unique.

FossilOrigin-Name: 29c46aca231b3f1e997ef306a5a651408185bf3ad09ab9fc1fe21ed18caa4d02
2023-12-18 14:16:58 +00:00
drh
52a4691fff Bug fix in the randomjson.c extension.
FossilOrigin-Name: 1f3a33df530dbe330ea8b14a69369b807b413b25a167d1a3938f8f0faf97cc91
2023-12-18 13:51:54 +00:00
drh
2ae95649de Enhancements to ext/misc/randomjson.c.
FossilOrigin-Name: a4e6d1f86f3a502e4170f5a90031e269e48363e95114a66b84d373e3ce0b2704
2023-12-18 12:18:47 +00:00
drh
0d201598a5 Enhancements to the "randomjson.c" extension. Automatically load that extension
into fuzzcheck.

FossilOrigin-Name: 70620405ab01d6a5d38bafa9ae175fd6e4eabaf2efb7854734278dafd7b05c99
2023-12-17 20:41:48 +00:00
dan
f2194605f8 Do not run test script fts5origintest4.test with either "memsubsys1" or "mmap" permutations.
FossilOrigin-Name: 05a63d9603ef42cbee6dadff72d97583a9c78e549f70e9a808534d5c1ae7c28a
2023-12-15 15:17:39 +00:00
stephan
f062506002 Correct --enable-sab flag in ext/wasm/GNUmakefile to fix a silent alhttpd args-parsing error.
FossilOrigin-Name: 7b9b757d872a31395b0f6454e2309a6a4664b8bdd8749f6a15371cbe72c05b60
2023-12-15 13:38:47 +00:00
stephan
e982385619 Use SQLITE_STRICT_SUBTYPE=1 by default for the JNI and WASM builds unless they're explicitly built with SQLITE_STRICT_SUBTYPE=0.
FossilOrigin-Name: 990211357badf0ab08bd34cf6d25b58849d0fd8503e289c1839fc837a74e1909
2023-12-14 22:01:55 +00:00
drh
eb78d56ec5 Add assert()s to FTS5 to fix static analyzer warnings.
FossilOrigin-Name: 27d4a89a5ff96b7b7fc5dc9650e1269f7c7edf91de9b9aafce40be9ecc8b95e9
2023-12-14 16:34:47 +00:00
drh
4a5c96ace3 Fix harmless compiler warnings in JSON and FTS5.
FossilOrigin-Name: 90135efccfeb1046f002bfcbd8dfec9a1a3b40cbe1b5c714ae065b06368e354f
2023-12-14 15:38:57 +00:00
dan
e6289d6dd0 Improve the error message returned by an fts5 'rebuild' command on an external content table if there is a problem with the content table or view.
FossilOrigin-Name: 0fbf4b8a58fde1c187908934da6f59999b146f32e07ac255cc531c5c4d7007fd
2023-12-14 15:31:35 +00:00
stephan
9710fa119e Worker1 Promiser API: when multiple db connections are active then use the requested connection instead of always the first-opened connection. Bug reported in [forum:894c330e7f23b177|forum post 894c330e7f23b177].
FossilOrigin-Name: 194276e18e0268829061c09317e7f9f527a703eb45f1755ff1dd30bd99dc1b68
2023-12-12 17:52:27 +00:00
dan
05980f5931 Avoid dropping an error code in new fts5 tokendata=1 code.
FossilOrigin-Name: a66596e33dc9aa4bab2ec3ff45546e1321d0a11bdc764f8381b315292ca92423
2023-12-08 12:04:32 +00:00
dan
0b427eb796 Ensure an fts5vocab table never uses a special tokendata=1 merge cursor.
FossilOrigin-Name: 1e26510e83b40c9bd2e8bfa2a0e81f2cb915e78fed773204ef537683e48b61dc
2023-12-07 21:09:33 +00:00
dan
7c12666fe9 Avoid an assert() failure when querying an fts5vocab table that accesses a tokendata=1 fts5 table with corrupt %_data records.
FossilOrigin-Name: 386ba9e20423fb2f623d6adc9d3c310fb1b135f54a1dad15ef3b593d97886926
2023-12-07 20:46:40 +00:00
dan
1ddcf7dd95 Fix a null-pointer dereference in fts5 tokendata=1 code.
FossilOrigin-Name: d69fa8f0504887f968d9a190ecb889ddb40bb1b56d0d4479f9819c106aec719b
2023-12-07 19:08:25 +00:00
dan
5f2f8d0028 Fix a problem with handling OOM and other errors in fts5 when querying tokendata=1 tables.
FossilOrigin-Name: bc911ab5953532956510c199be72b1d3c556f2d0ddbd7fc0ae6f5f917b337b48
2023-12-07 18:41:49 +00:00
dan
2f3ccb8886 Different fix for the fts5 COMMIT-following-OOM problem first fixed by [fba3129d]. This one does not cause problems if an fts5 table is renamed and then dropped within the same transaction.
FossilOrigin-Name: d8c6b246944934a7a6e027b3f5b986fd64a19dd5c5c5175f4ea8586da59a6764
2023-12-07 14:41:58 +00:00
dan
00f3ac5544 Fix compiler warning about shadowed variable in fts5_index.c.
FossilOrigin-Name: ee70e4c1c9c41617850228e48d8df44f105cf2fbbe789340ceca6f27ad6ce5eb
2023-12-06 18:34:59 +00:00
dan
83ac79282a Update documentation comments in fts5.h.
FossilOrigin-Name: 38c50e22c98607e6c1fd78d7615cda534773b6d4fd85c712b54749fcd7af0c83
2023-12-06 18:10:50 +00:00
dan
fb923fc4cc Further tests for the new code on this branch.
FossilOrigin-Name: 59d008b6c23ab900377bc696ee19381feb7614bac80546eae361e401c3620c4e
2023-12-05 18:36:23 +00:00
dan
49bfbc1ef3 Add further tests for xInstToken().
FossilOrigin-Name: 8582707f16133f003a6687f68cbea03d4eb6c2a0e2e07746b7cace0c44e84fa4
2023-12-04 19:48:08 +00:00
dan
54318b382a Fixes for xInstToken() with tokendata=0 tables. And with prefix queries.
FossilOrigin-Name: 78fbb71598b1ca756acc078253880a1d0f7983a5a26b9efc683e6488122505a1
2023-12-04 18:45:14 +00:00
dan
910c77b049 Fix memory leak in new code on this branch.
FossilOrigin-Name: ebc160b9a05568df66f86e30804399ee29d34b44a60c57e062f98cb92826353f
2023-12-04 17:58:56 +00:00
dan
3dfc063705 Fix a problem with the xInstCount() API and "ORDER BY rank" queries.
FossilOrigin-Name: 317a50563d9e8586fda136e513727241b414e7267d50a06571c8ebd0eae710bc
2023-12-04 17:45:33 +00:00
dan
9d373ca1c5 Fix bug in xInstToken() causing the wrong token to be returned.
FossilOrigin-Name: da78d07e77cbc783fbc725758911c230fd6a1c1885d9576125de955dcc2bd37f
2023-12-04 17:05:37 +00:00
dan
43b4864a98 Add tests for using tokendata=1 and contentless_delete=1 together.
FossilOrigin-Name: a2506b8c9718054912270055638204753c4156bbc115e55194e6df9d7e76cb10
2023-12-04 15:08:21 +00:00
dan
c22d2b7b7f Fix various compiler warnings and other problems with the new code on this branch.
FossilOrigin-Name: 3a623cfa173b4035c759cb84985d11d8727053beb383648503987d6ab15c0ef0
2023-12-02 20:35:04 +00:00
dan
94c521295a When tokendata=1 queries require multiple segment-cursors, allow those cursors to share a single array of in-memory tombstone pages.
FossilOrigin-Name: e0175d07e4094db5ea4b0378a5ff480dafb6ba9da86a113fa767c4c89c3c866f
2023-12-02 18:14:07 +00:00
dan
c44041e03b Ensure that tokendata=1 queries avoid loading large doclists for queries like "common AND uncommon", just as tokendata=0 queries do.
FossilOrigin-Name: 7bda09ab404a110d57449e149a3281fca8dc4cacf7bd9832ea2a1356ad20fe8e
2023-12-02 17:32:16 +00:00
dan
f4c2962558 Remove old code for tokendata=1 queries.
FossilOrigin-Name: b0a489e8e1bf0290c2117ab32d78b1cc7d67bcb226b55ec044c8367ebde3815b
2023-12-01 20:37:11 +00:00
dan
ebd173a79f Merge latest trunk with this branch.
FossilOrigin-Name: 8258967411d3ff212424b25fec79ded0d8ae83e773cd35a0bbf300c94923f25b
2023-12-01 20:10:20 +00:00
dan
b5effc0605 Different approach to querying a tokendata=1 table. Saves cpu and memory.
FossilOrigin-Name: c523f40895866e6fc979a26483dbea8206126b4bbdf4b73b77263c09e13c855e
2023-12-01 20:09:59 +00:00
stephan
68003d9f18 Add a basic batch-mode SQL runner for the SAH Pool VFS, for use in comparing it against WebSQL. Bring the WebSQL batch runner up to date, noting that it cannot run without addition of an "origin trial" activation key from Google because that's now the only way to enable WebSQL in Chrome (that part is not checked in because that key is private). Minor code-adjacent cleanups.
FossilOrigin-Name: 883990e7938c1f63906300a6113f0fadce143913b7c384e8aeb5f886f0be7c62
2023-11-30 20:34:24 +00:00
stephan
bac2fe9f44 Update some OPFS-related help text in WASM tests. Minor cleanups in speedtest1-worker.js.
FossilOrigin-Name: 263f6d3a7784ef7d032dbf7a3265aca8dd70bf50797f28f6b2e8ddb6a301f83a
2023-11-30 10:00:25 +00:00
dan
89fcfbb424 Fix signed integer overflow in fts5.
FossilOrigin-Name: 60e46c7ec68fd8caaed960ca06d98fb06855b2d0bb860dd2fb7b5e89a5e9c7b4
2023-11-29 16:22:39 +00:00
drh
ed088f5f8d In the recovery extension, if a payload size is unreasonably large, it is
probably corrupt, so truncate it.

FossilOrigin-Name: 988c3179e978a3a6d42541e9c7a2ab98150383671810926503376ed808f150ff
2023-11-29 13:47:46 +00:00