Create a new distributed-shared object (not backed by a shared memory block) and return its id to be used in a Proxy Object.
(self, c, typeid, /, *args, **kwargs)
| 1344 | util.debug(f"SharedMemoryServer started by pid {getpid()}") |
| 1345 | |
| 1346 | def create(self, c, typeid, /, *args, **kwargs): |
| 1347 | """Create a new distributed-shared object (not backed by a shared |
| 1348 | memory block) and return its id to be used in a Proxy Object.""" |
| 1349 | # Unless set up as a shared proxy, don't make shared_memory_context |
| 1350 | # a standard part of kwargs. This makes things easier for supplying |
| 1351 | # simple functions. |
| 1352 | if hasattr(self.registry[typeid][-1], "_shared_memory_proxy"): |
| 1353 | kwargs['shared_memory_context'] = self.shared_memory_context |
| 1354 | return Server.create(self, c, typeid, *args, **kwargs) |
| 1355 | |
| 1356 | def shutdown(self, c): |
| 1357 | "Call unlink() on all tracked shared memory, terminate the Server." |