I think there may be a concurrency issue with Kuery-ORM when subjected to stress which causes infrequent errors, but looks like it could potentially cause data corruption.
I am using this work-in-progress branch of my TechEmpower implementation for Kitura, compiled in release mode, and driven with the following command:
Context and Description
I think there may be a concurrency issue with Kuery-ORM when subjected to stress which causes infrequent errors, but looks like it could potentially cause data corruption.
I am using this work-in-progress branch of my TechEmpower implementation for Kitura, compiled in release mode, and driven with the following command:
Client output:
...the
Non-2xx or 3xx responses
line indicates the number of failed requests during this period.The corresponding output from the Kitura process:
The same benchmark driven by the
TechEmpowerPostgres
executable (which uses Kuery directly and does not involve the ORM) runs without such errors.Also, running with fewer concurrent connections (eg. 20) seems to prevent the errors from occurring.
Environment Details
macOS 10.13.6 High Sierra, Swift 4.2.1 (Xcode 10.1), compiled in release mode. Running against a local PostgreSQL database.
Steps to Reproduce
1) ... 2) ...
Expected vs. Actual Behaviour