collabora-online/test
Michael Meeks e27a095775 bgsave: initial implementation (gated on COOL_BGSAVE=1)
Initial background save implementation from the Kit perspective.

To do a background save we:

   1. join known threads - we can't fork with >1 thread.
   2. check all is well: one thread, nothing unusual...
   3. create a socketpair to communicate with the child
   4. fork
   5. child: cleanup duplicated sockets
   6. child: setup LOK to not damage our shared file-system
   7. child: save
   8. child: report status back to parent & _Exit

There is still a substantial TODO, but this can be built on.

Change-Id: Ibf2c492372e2b5133932773e230ad05e18521794
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2024-04-05 17:34:43 +01:00
..
data cool#8465 clipboard: improve handling of plain text copy, complex case 2024-03-20 10:21:59 +01:00
traces Cleanup performance traces. 2022-05-09 16:40:57 +01:00
.gitignore gitignore: differentiate files from dirs 2023-01-06 11:19:18 +03:00
DeltaTests.cpp Move loadPng to Png.hpp to share it. 2024-03-10 20:06:53 +00:00
FileServeWhiteBoxTests.cpp fix fail unit test "builddir != srcdir" 2024-02-14 09:12:12 +00:00
HttpRequestTests.cpp rng::getHardRandomHexString is now the same impl as rng::getHexString 2024-02-05 16:19:38 +00:00
HttpTestServer.hpp Replace Util::startsWith/endsWith w/ C++20 equivalent 2024-02-22 08:08:32 +01:00
HttpWhiteBoxTests.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
KitPidHelpers.cpp Cleanup waitForKitPidsReady. 2024-03-25 08:18:35 +00:00
KitPidHelpers.hpp crash test - cope with more complexity around re-starting. 2024-03-25 08:18:35 +00:00
Makefile.am cool#8465 clipboard: improve handling of plain text copy, complex case 2024-03-20 10:21:59 +01:00
RequestDetailsTests.cpp cool#8328 - config header fixup. 2024-02-21 09:35:25 +00:00
StringVectorTests.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
TileCacheTests.cpp Replace total pid count waits with targeted waits 2024-03-09 16:36:39 +00:00
TileQueueTests.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
UnitAdmin.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
UnitBadDocLoad.cpp wsd: test: move WebSocketSession under test 2024-03-21 09:08:51 +00:00
UnitCalc.cpp wsd: test: move WebSocketSession under test 2024-03-21 09:08:51 +00:00
UnitClient.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
UnitClose.cpp wsd: clean up unused header includes 2024-01-08 08:38:48 +01:00
UnitConvert.cpp wsd: clean up unused header includes 2024-01-08 08:38:48 +01:00
UnitCopyPaste.cpp wsd: test: move WebSocketSession under test 2024-03-21 09:08:51 +00:00
UnitCopyPasteWriter.cpp Related: cool#8648 clipboard: use JSON when requesting HTML only 2024-04-02 21:41:57 +01:00
UnitCursor.cpp Replace total pid count waits with targeted waits 2024-03-09 16:36:39 +00:00
UnitEachView.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
UnitFuzz.cpp wsd: clean up unused header includes 2024-01-08 08:38:48 +01:00
UnitHTTP.cpp killpoco: reduce scope and number of various includes. 2024-03-06 20:56:55 -05:00
UnitHTTP.hpp wsd: clean up unused header includes 2024-01-08 08:38:48 +01:00
UnitHosting.cpp wsd: clean up unused header includes 2024-01-08 08:38:48 +01:00
UnitInsertDelete.cpp wsd: clean up unused header includes 2024-01-08 08:38:48 +01:00
UnitLargePaste.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
UnitLoad.cpp wsd: test: move WebSocketSession under test 2024-03-21 09:08:51 +00:00
UnitLoadTorture.cpp wsd: test: move WebSocketSession under test 2024-03-21 09:08:51 +00:00
UnitOAuth.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
UnitPasswordProtected.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
UnitPaste.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
UnitPrefork.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
UnitQuarantine.cpp wsd: test: use LOK_ASSERT_STATE for more informative report 2024-03-05 12:21:50 +01:00
UnitRenderSearchResult.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
UnitRenderShape.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
UnitRenderingOptions.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
UnitSession.cpp Replace Util::startsWith/endsWith w/ C++20 equivalent 2024-02-22 08:08:32 +01:00
UnitStorage.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
UnitTiffLoad.cpp Replace Util::startsWith/endsWith w/ C++20 equivalent 2024-02-22 08:08:32 +01:00
UnitTileCache.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
UnitTimeout.cpp wsd: clean up unused header includes 2024-01-08 08:38:48 +01:00
UnitTyping.cpp wsd: test: move WebSocketSession under test 2024-03-21 09:08:51 +00:00
UnitUNOCommand.cpp Replace Util::startsWith/endsWith w/ C++20 equivalent 2024-02-22 08:08:32 +01:00
UnitWOPI.cpp killpoco: reduce scope and number of various includes. 2024-03-06 20:56:55 -05:00
UnitWOPIAsyncUpload_ModifyClose.cpp wsd: move deprecated logic under legacy_server config 2024-03-02 04:02:26 -05:00
UnitWOPICrashModified.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
UnitWOPIDocumentConflict.cpp wsd: clean up unused header includes 2024-01-08 08:38:48 +01:00
UnitWOPIFailUpload.cpp wsd: test: use LOK_ASSERT_STATE for more informative report 2024-03-05 12:21:50 +01:00
UnitWOPIFileUrl.cpp wsd: test: use LOK_ASSERT_STATE for more informative report 2024-03-05 12:21:50 +01:00
UnitWOPIHttpHeaders.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
UnitWOPIHttpRedirect.cpp wsd: test: use LOK_ASSERT_STATE for more informative report 2024-03-05 12:21:50 +01:00
UnitWOPILanguages.cpp Replace Util::startsWith/endsWith w/ C++20 equivalent 2024-02-22 08:08:32 +01:00
UnitWOPILoadEncoded.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
UnitWOPILock.cpp wsd: move deprecated logic under legacy_server config 2024-03-02 04:02:26 -05:00
UnitWOPIRenameFile.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
UnitWOPISaveAs.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
UnitWOPISaveAsWithEncodedFileName.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
UnitWOPISaveOnExit.cpp wsd: do not upload unmodified document 2024-01-04 05:29:32 -05:00
UnitWOPISlow.cpp wsd: test: use LOK_ASSERT_STATE for more informative report 2024-03-05 12:21:50 +01:00
UnitWOPIStuckSave.cpp wsd: clean up unused header includes 2024-01-08 08:38:48 +01:00
UnitWOPITemplate.cpp wsd: test: use STATE_ENUM in tests 2024-03-05 12:21:50 +01:00
UnitWOPIVersionRestore.cpp wsd: clean up unused header includes 2024-01-08 08:38:48 +01:00
UnitWOPIWatermark.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
UnitWSDClient.hpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
UnitWopiOwnertermination.cpp wsd: more accurate load error message 2024-04-03 14:26:28 +01:00
UtilTests.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
WOPIUploadConflictCommon.hpp wsd: test: use LOK_ASSERT_STATE for more informative report 2024-03-05 12:21:50 +01:00
WebSocketSession.hpp wsd: test: move WebSocketSession under test 2024-03-21 09:08:51 +00:00
WhiteBoxTests.cpp bgsave: initial implementation (gated on COOL_BGSAVE=1) 2024-04-05 17:34:43 +01:00
WopiProofTests.cpp spdx: improve machine and human readability of headers. 2023-11-20 14:30:02 +00:00
WopiTestServer.hpp wsd: test: refactor WopiTestServer to override uploading 2024-03-05 12:21:50 +01:00
fakesockettest.cpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
helpers.hpp wsd: test: move WebSocketSession under test 2024-03-21 09:08:51 +00:00
httpcrashtest.cpp crash test - cope with more complexity around re-starting. 2024-03-25 08:18:35 +00:00
httpwstest.cpp Replace total pid count waits with targeted waits 2024-03-09 16:36:39 +00:00
integration-http-server.cpp Replace total pid count waits with targeted waits 2024-03-09 16:36:39 +00:00
lokassert.hpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00
run_unit.sh.in wsd: test: better run_unit.sh 2023-10-24 09:20:32 +02:00
run_unit_standalone.sh.in wsd: test: better run_unit.sh 2023-10-24 09:20:32 +02:00
test.cpp Move kit pid helper functions to one file 2024-03-09 16:36:39 +00:00
test.hpp Move kit pid helper functions to one file 2024-03-09 16:36:39 +00:00
testlog.hpp spdx: improve machine and human readability of headers. 2023-11-14 19:36:31 +00:00