Re: shared memory extention
[email protected] (Johannes Schlüter)
| Newsgroups | php.pecl.dev |
|---|---|
| Organization | php.net |
| Message-ID | <1271246262.9207.8.camel@guybrush> |
Hi, On Wed, 2010-04-14 at 17:33 +1000, Geoffrey McRae wrote: > I have been working on a shared memory extension for PHP that uses > "Shared Memory Arena" for management and storage > (http://shm-arena.sourceforge.net/). I see the lib uses LGPL,which is acceptable. What license will you use? (BSD / PHP are strongly preferred) > For security each user can have a limit of 1MB of shared memory, which > is owned by the running process uid, the limit is compiled into the > extension but could be made a ini value fairly easily. ini value sounds like a good choice. > It handles all zval types excluding (for now) array and object types. > resource types will never be allowed in the cache for obvious reasons. At least arrays should be supported. Probably serializing them is enough. (note: not all objects can be serialized, many internal classes don't provide the needed info, often it doesn't make sense (like PDO)) > * bool sm_set(string $name, mixed $value[, int $ttl]) > sets $name to $value > $ttl is optional and defaults to 0 (forever) > returns TRUE on success, FALSE on failure. Is there a global TTL orother cleanup-technique? (I don't know shm-arena) Can you show the code?- While i think this should be fine and no problem to add to PECL. Do you already have an account? johannes