1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-07-29 08:01:23 +03:00

Rename the new opfs-sahpool init-retry flag to the suitably descriptive, and suitably onerous, forceReinitIfPreviouslyFailed, based on feedback.

FossilOrigin-Name: c9f0a6090258534a3d81066df5610229183a8457fc60d5034b4b94d9a29796e4
This commit is contained in:
stephan
2024-07-13 00:55:55 +00:00
parent 8ee747dda5
commit f7623a0871
4 changed files with 14 additions and 13 deletions

View File

@ -103,7 +103,7 @@ globalThis.sqlite3ApiBootstrap.initializers.push(function(sqlite3){
/* Logging verbosity 3+ == everything, 2 == warnings+errors, 1 == /* Logging verbosity 3+ == everything, 2 == warnings+errors, 1 ==
errors only. */ errors only. */
verbosity: 2, verbosity: 2,
forceReinitIfFailed: false forceReinitIfPreviouslyFailed: false
}); });
/** Logging routines, from most to least serious. */ /** Logging routines, from most to least serious. */
@ -1080,7 +1080,7 @@ globalThis.sqlite3ApiBootstrap.initializers.push(function(sqlite3){
then a directory name is synthesized from the `name` option. then a directory name is synthesized from the `name` option.
- `forceReinitIfFailed`: (default=`false`) Is a fallback option - `forceReinitIfPreviouslyFailed`: (default=`false`) Is a fallback option
to assist in working around certain flaky environments which may to assist in working around certain flaky environments which may
mysteriously fail to permit access to OPFS sync access handles on mysteriously fail to permit access to OPFS sync access handles on
an initial attempt but permit it on a second attemp. This option an initial attempt but permit it on a second attemp. This option
@ -1231,7 +1231,7 @@ globalThis.sqlite3ApiBootstrap.initializers.push(function(sqlite3){
return p; return p;
}catch(e){ }catch(e){
//log("installOpfsSAHPoolVfs() got cached failure",options,vfsName,e); //log("installOpfsSAHPoolVfs() got cached failure",options,vfsName,e);
if( options.forceReinitIfFailed ){ if( options.forceReinitIfPreviouslyFailed ){
delete initPromises[vfsName]; delete initPromises[vfsName];
/* Fall through and try again. */ /* Fall through and try again. */
}else{ }else{

View File

@ -3190,9 +3190,10 @@ globalThis.sqlite3InitModule = sqlite3InitModule;
T.assert(cErr === await inst(conf2).catch(e=>e), T.assert(cErr === await inst(conf2).catch(e=>e),
"Init result is cached even if it failed"); "Init result is cached even if it failed");
/* Ensure that the forceReinitIfFailed fallback bypasses the VFS init cache... */ /* Ensure that the forceReinitIfPreviouslyFailed fallback bypasses
the VFS init cache... */
cErr = u3 = undefined; cErr = u3 = undefined;
conf2.forceReinitIfFailed = true; conf2.forceReinitIfPreviouslyFailed = true;
conf2.verbosity = 3; conf2.verbosity = 3;
const P3b = await inst(conf2).then(u=>u3 = u).catch((e)=>cErr=e); const P3b = await inst(conf2).then(u=>u3 = u).catch((e)=>cErr=e);
T.assert(undefined === cErr) T.assert(undefined === cErr)

View File

@ -1,5 +1,5 @@
C Reformulate\sthe\sforceReinitIfFailed\shandling\sbased\son\sfeedback,\sto\scorrect\sthe\stype-checking\sand\sresolve\sa\spotential\srace\scondition. C Rename\sthe\snew\sopfs-sahpool\sinit-retry\sflag\sto\sthe\ssuitably\sdescriptive,\sand\ssuitably\sonerous,\sforceReinitIfPreviouslyFailed,\sbased\son\sfeedback.
D 2024-07-11T19:50:17.794 D 2024-07-13T00:55:55.226
F .fossil-settings/empty-dirs dbb81e8fc0401ac46a1491ab34a7f2c7c0452f2f06b54ebb845d024ca8283ef1 F .fossil-settings/empty-dirs dbb81e8fc0401ac46a1491ab34a7f2c7c0452f2f06b54ebb845d024ca8283ef1
F .fossil-settings/ignore-glob 35175cdfcf539b2318cb04a9901442804be81cd677d8b889fcc9149c21f239ea F .fossil-settings/ignore-glob 35175cdfcf539b2318cb04a9901442804be81cd677d8b889fcc9149c21f239ea
F LICENSE.md df5091916dbb40e6e9686186587125e1b2ff51f022cc334e886c19a0e9982724 F LICENSE.md df5091916dbb40e6e9686186587125e1b2ff51f022cc334e886c19a0e9982724
@ -618,7 +618,7 @@ F ext/wasm/api/sqlite3-api-worker1.c-pp.js 5cc22a3c0d52828cb32aad8691488719f47d2
F ext/wasm/api/sqlite3-license-version-header.js 0c807a421f0187e778dc1078f10d2994b915123c1223fe752b60afdcd1263f89 F ext/wasm/api/sqlite3-license-version-header.js 0c807a421f0187e778dc1078f10d2994b915123c1223fe752b60afdcd1263f89
F ext/wasm/api/sqlite3-opfs-async-proxy.js 881af4643f037b6590c491cef5fac8bcdd4118993197a1fa222ccb8b01e3504a F ext/wasm/api/sqlite3-opfs-async-proxy.js 881af4643f037b6590c491cef5fac8bcdd4118993197a1fa222ccb8b01e3504a
F ext/wasm/api/sqlite3-vfs-helper.c-pp.js 3f828cc66758acb40e9c5b4dcfd87fd478a14c8fb7f0630264e6c7fa0e57515d F ext/wasm/api/sqlite3-vfs-helper.c-pp.js 3f828cc66758acb40e9c5b4dcfd87fd478a14c8fb7f0630264e6c7fa0e57515d
F ext/wasm/api/sqlite3-vfs-opfs-sahpool.c-pp.js e7b8c70c9a239eee2b571b5cd60e2a1d677312b83ad7e6395629c2954d0f26d3 F ext/wasm/api/sqlite3-vfs-opfs-sahpool.c-pp.js 8c59ff35224adbe926b85d0c6debedc63c3c949d4cee761b3a74867b56155341
F ext/wasm/api/sqlite3-vfs-opfs.c-pp.js 0c3801a8e252944fdbaddbad698534316fde90d3db5eedae156e7774ab127710 F ext/wasm/api/sqlite3-vfs-opfs.c-pp.js 0c3801a8e252944fdbaddbad698534316fde90d3db5eedae156e7774ab127710
F ext/wasm/api/sqlite3-vtab-helper.c-pp.js a2fcbc3fecdd0eea229283584ebc122f29d98194083675dbe5cb2cf3a17fe309 F ext/wasm/api/sqlite3-vtab-helper.c-pp.js a2fcbc3fecdd0eea229283584ebc122f29d98194083675dbe5cb2cf3a17fe309
F ext/wasm/api/sqlite3-wasm.c 9267174b9b0591b4f71193542ab57adf95bb9415f7d3453acf4a8ca8052f5e6c F ext/wasm/api/sqlite3-wasm.c 9267174b9b0591b4f71193542ab57adf95bb9415f7d3453acf4a8ca8052f5e6c
@ -667,7 +667,7 @@ F ext/wasm/test-opfs-vfs.html 1f2d672f3f3fce810dfd48a8d56914aba22e45c6834e262555
F ext/wasm/test-opfs-vfs.js 1618670e466f424aa289859fe0ec8ded223e42e9e69b5c851f809baaaca1a00c F ext/wasm/test-opfs-vfs.js 1618670e466f424aa289859fe0ec8ded223e42e9e69b5c851f809baaaca1a00c
F ext/wasm/tester1-worker.html ebc4b820a128963afce328ecf63ab200bd923309eb939f4110510ab449e9814c F ext/wasm/tester1-worker.html ebc4b820a128963afce328ecf63ab200bd923309eb939f4110510ab449e9814c
F ext/wasm/tester1.c-pp.html 1c1bc78b858af2019e663b1a31e76657b73dc24bede28ca92fbe917c3a972af2 F ext/wasm/tester1.c-pp.html 1c1bc78b858af2019e663b1a31e76657b73dc24bede28ca92fbe917c3a972af2
F ext/wasm/tester1.c-pp.js e231a9ae8b5ad6c3697339178e2e801edfb13cedcbd4a1e98bc5915646cc357d F ext/wasm/tester1.c-pp.js 74ade5f0d61db790b4e403f6bf7c0d346e19ec876cdee109c22ae4214aa89f4e
F ext/wasm/tests/opfs/concurrency/index.html 0802373d57034d51835ff6041cda438c7a982deea6079efd98098d3e42fbcbc1 F ext/wasm/tests/opfs/concurrency/index.html 0802373d57034d51835ff6041cda438c7a982deea6079efd98098d3e42fbcbc1
F ext/wasm/tests/opfs/concurrency/test.js a98016113eaf71e81ddbf71655aa29b0fed9a8b79a3cdd3620d1658eb1cc9a5d F ext/wasm/tests/opfs/concurrency/test.js a98016113eaf71e81ddbf71655aa29b0fed9a8b79a3cdd3620d1658eb1cc9a5d
F ext/wasm/tests/opfs/concurrency/worker.js 0a8c1a3e6ebb38aabbee24f122693f1fb29d599948915c76906681bb7da1d3d2 F ext/wasm/tests/opfs/concurrency/worker.js 0a8c1a3e6ebb38aabbee24f122693f1fb29d599948915c76906681bb7da1d3d2
@ -2195,8 +2195,8 @@ F vsixtest/vsixtest.tcl 6a9a6ab600c25a91a7acc6293828957a386a8a93
F vsixtest/vsixtest.vcxproj.data 2ed517e100c66dc455b492e1a33350c1b20fbcdc F vsixtest/vsixtest.vcxproj.data 2ed517e100c66dc455b492e1a33350c1b20fbcdc
F vsixtest/vsixtest.vcxproj.filters 37e51ffedcdb064aad6ff33b6148725226cd608e F vsixtest/vsixtest.vcxproj.filters 37e51ffedcdb064aad6ff33b6148725226cd608e
F vsixtest/vsixtest_TemporaryKey.pfx e5b1b036facdb453873e7084e1cae9102ccc67a0 F vsixtest/vsixtest_TemporaryKey.pfx e5b1b036facdb453873e7084e1cae9102ccc67a0
P 5286e0f654d91a4ebee51fcabaab696e17ff07bb18990b401a31bd3d1213e695 P c4f468309158f9b951137461213fb269d96d15c331256cf392a56c9bed231460
R 1edb9efa72844191061bd673c33c8081 R 6ea3913d20dc04cfbb6567303894df42
U stephan U stephan
Z fea5c63c4f659006bc6ce3b8cbda987f Z dab1e381b46a819e9c939e93f18cc9e7
# Remove this line to create a well-formed Fossil manifest. # Remove this line to create a well-formed Fossil manifest.

View File

@ -1 +1 @@
c4f468309158f9b951137461213fb269d96d15c331256cf392a56c9bed231460 c9f0a6090258534a3d81066df5610229183a8457fc60d5034b4b94d9a29796e4