Repository navigation
Consolidate transport, XFTP, SMP and PostgreSQL fixes - #2102
Open
adayhans8-debug wants to merge 160 commits into
Open
adayhans8-debug wants to merge 160 commits into
adayhans8-debug wants to merge 160 commits into
Conversation
…s before, rethrow only cancellations
Prevent Windows XFTP server tests from hanging during TLS and HTTP/2 teardown. Cancel HTTP/2 workers asynchronously, allow client finalizers to be interrupted, and close TLS contexts without waiting for peer close notifications.
Consolidated from PR simplex-chat#2064, preserving the cancellation semantics of PR simplex-chat#2088.
Consolidated from PR simplex-chat#2073.
Consolidated from PR simplex-chat#2044.
Consolidated from PR simplex-chat#2058, preserving the fixes from PRs simplex-chat#2044, simplex-chat#2064, simplex-chat#2079 and simplex-chat#2088.
Consolidated from PR simplex-chat#2082 while preserving cancellation and file-count semantics.
Consolidated from PR simplex-chat#2038, retaining deadlock retries and file-count fixes.
Consolidated from PR simplex-chat#2039.
Restore notification grouping and batched subscription results. Initialize delayed AUTH and unacked-data settings. Remove duplicate client send block definitions.
Reset replacement subscription state. Deduplicate unsubscription events. Recompute service END counts from the store. Use dynamic SOCKS ports and current stats fixtures.
Start sendDelayed alongside send, command processing and receive threads. Without this thread, AUTH responses remain in delayedQ indefinitely when authErrorDelay is enabled. Verified: queue key SEd25519 / used key SEd25519 passes in 1.6138s.
Complete PostgreSQL migration, stats and service-association integration. Cancel replaced XFTP uploads without self-cancel deadlocks; drain unstarted uploads after commit. Delete expired files using paths returned at record deletion and cancel active uploads. Allow retrying unconfirmed sender queues and restore notification push call. Update test fixtures for temporary uploads, encoded frame size and deterministic expiration timing. Focused AUTH, short-link, async retry, SQLite schema, static-file and all 45 XFTP chunk tests pass.
Delete only the newly created connection when securing it fails, so a later invitation retry does not conflict with the stale sender queue. Keep cross-connection sender queue protection intact. Verified async second-attempt connection and should-not-add-SndQueue-of-another-connection tests.
Use separate response and message senders under the fair transport lock, preventing sustained command traffic from starving message delivery. Share the test deadline helper and raise the integration-suite limit to 180 seconds for multi-restart workloads. Verified the 200-subscription batching test and all focused connection regressions.
Delete only the new sender queue after secureConfirmQueue fails, preserving the connection and ratchet for retries. Verified all invitation/contact user-retry tests, async second attempt and cross-connection sender queue protection.
Use non-blocking writes for push workers so one full queue cannot delay notifications from other servers. Accept NMSG responses from service subscriptions and correct second-token test entity matching. Verified both memory and PostgreSQL full-push-queue tests.
Include generated schema updates from the completed migration set. Allow up to 360 seconds for heavily contended multi-restart integration tests. Verified: default suite 1449 examples, 0 failures, 7 pending.
Schema dumps produced and verified by the PostgreSQL schema tests.
adayhans8-debug
requested review from
epoberezkin and
shumvgolove
as code owners
November 23, 2026 16:36
…to consolidated/windows-transport # Conflicts: # .github/workflows/build.yml # scripts/ci/README.md # scripts/resolver/README.md # scripts/resolver/docker-compose.yml # scripts/resolver/service/snrc-resolve.py # scripts/resolver/service/test_snrc_resolve.py # src/Simplex/FileTransfer/Server/Store/Postgres.hs # src/Simplex/Messaging/Agent.hs # src/Simplex/Messaging/Agent/Store/Postgres/Common.hs # src/Simplex/Messaging/Server/QueueStore/Postgres.hs # src/Simplex/Messaging/Transport.hs # tests/CoreTests/MsgStoreTests.hs # tests/CoreTests/XFTPStoreTests.hs # tests/NtfServerTests.hs # tests/XFTPServerTests.hs
Attempt TLS bye before closing the context without uninterruptible masking. Use non-blocking notification writes for ACK events when the agent event queue is full. Both focused regression tests pass.
Race TLS bye with a one-second timeout and close the context directly afterward. Avoid nested timeout and withAsync cleanup deadlocks under uninterruptible masks. Both TLS close regression tests pass.
Close TLS context after 50ms and finish cancellation after another 150ms. This preserves timeout semantics while ensuring the context is already closed when the outer timeout fires. TLS close, blocked-peer close and 1000-cancellation tests pass.
Pass shard ID 0 to getPushClient and look up pushClients by (provider, shard). Push worker kill and periodic-server-stop tests pass with PostgreSQL enabled.
Author
|
Merged current Verification after the merge:
GitHub created the build and resolver-mainnet workflows, but both are |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
SimpleXMQ consolidation review and validation
I reviewed the open SimpleXMQ PRs and consolidated the non-overlapping bug fixes into
consolidated/windows-transport, currently atcbfb1f4b35.The related SimpleX Chat compatibility change is
816bb2d4a0b6f97c2b13e6b49a4bb61724ab1b8a.Integration decisions
CLIENT_SUPPORT _handling in SimpleX Chat's no-connection event dispatcher. The new agent event otherwise breaks SimpleX Chat 7.1.4 with-Werror=incomplete-patterns; it is currently ignored because this client has no corresponding UI event.Additional integration fixes
The consolidation exposed several issues that are now fixed:
sendDelayedinrunClientThreads; AUTH responses were otherwise left indelayedQindefinitely (117afec831).NMSGhandling.Verification
libsimplex.dllbuilt with+client_library; Windows CLI completed private SMP messaging and 1 MiB XFTP transfers through both the consolidated local server and the private endpoint.libsimplex.soand a signed APK built successfully. The app accepted a private short-link invitation, completed messaging and downloaded a 1 MiB XFTP file with matching SHA-256:386fb8e174f297a52146c8a387315a0b3c78904f345c5eff57b0ffa5ccb52502.I also rejected invalid validation evidence: an earlier all-pending PostgreSQL run caused by loopback authentication, a parallel run that exhausted database connections, and initial GUI artifacts built against
../simplexmqinstead of../simplexmq-consolidated.Remaining limitation
Only Android arm64 was packaged and signed. Armv7 is not included because its legacy GHC toolchain did not complete within one hour.