summaryrefslogtreecommitdiff
path: root/tests/modules/fork.c
Commit message (Collapse)AuthorAgeFilesLines
* Fix race in module fork kill test (#10717)Binbin2022-05-121-5/+8
| | | | | | | | | | | | | | | | | | | The purpose of the test is to kill the child while it is running. From the last two lines we can see the child exits before being killed. ``` - Module fork started pid: 56998 * <fork> fork child started - Killing running module fork child: 56998 * <fork> fork child exiting signal-handler (1652267501) Received SIGUSR1 in child, exiting now. ``` In this commit, we pass an argument to `fork.create` indicating how long it should sleep. For the fork kill test, we use a longer time to avoid the child exiting before being killed. Other changes: use wait_for_condition instead of hardcoded `after 250`. Unify the test for failing fork with the one for killing it (save time)
* Modules: Mark all APIs non-experimental (#9983)Viktor Söderqvist2021-12-301-1/+0
| | | These exist for quite some time, and are no longer experimental
* Moved RMAPI_FUNC_SUPPORTED location such that it will be visible to modules ↵Meir Shpilraien (Spielrein)2020-11-091-0/+6
| | | | | | (#8037) The RMAPI_FUNC_SUPPORTED was defined in the wrong place on redismodule.h and was not visible to modules.
* fix race in module api test for forkOran Agra2020-02-231-1/+1
| | | | in some cases we were trying to kill the fork before it got created
* Module api tests for RM_CallOran Agra2019-10-281-1/+5
| | | | | | | Adding a test for coverage for RM_Call in a new "misc" unit to be used for various short simple tests also solves compilation warnings in redismodule.h and fork.c
* Module API for ForkingOran Agra2019-07-171-0/+84
* create module API for forking child processes. * refactor duplicate code around creating and tracking forks by AOF and RDB. * child processes listen to SIGUSR1 and dies exitFromChild in order to eliminate a valgrind warning of unhandled signal. * note that BGSAVE error reply has changed. valgrind error is: Process terminating with default action of signal 10 (SIGUSR1)