|Main Archive Page > Month Archives > postfix-users archives|
On Friday 01 October 2010 18:58:26 Wietse Venema wrote:
> > Hi list,
> > I'm in the process of adding write support to postfix's mysql client (you
> > will find a patch against postfix-2.7.1 in the appendix). But I have two
> > problems: 1) the dict_cache_clean_event writes
> > _LAST_CACHE_CLEANUP_COMPLETED_ to the database. Is this the intended
> > behaviour?
> This record is needed by the cache cleanup pseudo-thread. This code
> assumes that the verify(8) daemon is responsible for cleaning up
> the verify(8) cache.
Ah, fine. So that's OK.
> > 2) If I'm guessing right then the dict_cache_clean_event will iterate
> > with help of dict->sequence through the database and will look for keys
> > to expire. But I don't know how to implement this iteration/traverse
> > process with mysql. My first thought was to use "SELECT * FROM verify"
> > and mysql_use_result() but I'm wondering if there is a better solution.
> > Has anyone an idea of how to do this?
> Does the database support a first/next operation?
The operation which comes close to that, is to select the whole table and then
fetch the keys row by row. Yes, I think that is a first/next operation (with a
What would be the answer if there wasn't a first/next operation?
Thank you in advance.