Message369127
Not sure about "it can always be accessed and closed/unlinked by any process later on", as each process will be spawning its own resource_tracker, using a separate pipe. Thus, unregister calls from other processes will not have any effect.
The documentation is indeed unclear that processes must share the resource_tracker. Can we introduce a new flag - "persist", that would indicate no resource tracking is needed? Registering will only happen if create=True and persist=False, meaning the user accepts the creating process must outlive all other processes that could connect to the shared memory. If persist=False, the user accepts the responsibility for manual cleaning up of the allocated memory. This will allow catering to a wider range of use cases, where readers/writer processes can exit and re-connect to shared_memory as they see fit. |
|
Date |
User |
Action |
Args |
2020-05-17 15:25:54 | rauanargyn | set | recipients:
+ rauanargyn, pitrou, python-dev, davin, dxflores, jfischer, fvdnabee |
2020-05-17 15:25:54 | rauanargyn | set | messageid: <1589729154.59.0.128332610944.issue39959@roundup.psfhosted.org> |
2020-05-17 15:25:54 | rauanargyn | link | issue39959 messages |
2020-05-17 15:25:54 | rauanargyn | create | |
|