Clarification needed on replication frequency settings

Nic Bernstein nic at onlight.com
Thu Aug 20 10:42:52 EDT 2015


Mostly to Bron, but if anyone else wishes to jump in...

There seems to be a conflict between documentation and code in regards 
to the settings for replication frequency.  Specifically, 
cyrus-imapd/lib/imapoptions has this:

    { "sync_repeat_interval",*1*, INT }
    /* Minimum interval (in seconds) between replication runs in rolling
        replication mode. If a replication run takes longer than this
        time, we repeat immediately.
        Prefix with a channel name to only apply for that channel */

which would seem to indicate that the default is 1 second. Meanwhile, 
sync_client(8) has this:

    .. option:: -d delay

         Minimum delay between replication runs in rolling replication mode.
         Larger values provide better efficiency as transactions can be
         merged. Smaller values mean that the replica system is more up to
         date and that you don't end up with large blocks of replication
         transactions as a single group. Default:*3 seconds*.

and the code, sync_client.c, has this:

         int   timeout  = 600;
         int   min_delta = 0;
         const char *channel = NULL;
    ...
             case 't':
                 timeout = atoi(optarg);
                 break;

             case 'd':
                 min_delta = atoi(optarg);
                 break;
    ...
             else {
                 /* rolling replication */
                 if (!sync_shutdown_file)
                     sync_shutdown_file = get_config(channel, "sync_shutdown_file");

                 if (!min_delta)
                     min_delta = get_intconfig(channel, "sync_repeat_interval");

                 do_daemon(channel, sync_shutdown_file, timeout, min_delta);
             }

So I'm thinking that the actual default is 1, not 3.  Am I right, or 
confused?

Cheers,
     -nic

-- 
Nic Bernstein                             nic at onlight.com
Onlight, Inc.                             www.onlight.com
6525 W Bluemound Road, Suite 24           v. 414.272.4477
Milwaukee, Wisconsin  53213-4073

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.andrew.cmu.edu/pipermail/cyrus-devel/attachments/20150820/482c7045/attachment.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: nic.vcf
Type: text/x-vcard
Size: 278 bytes
Desc: not available
Url : http://lists.andrew.cmu.edu/pipermail/cyrus-devel/attachments/20150820/482c7045/attachment.vcf 


More information about the Cyrus-devel mailing list