diff options
author | Kamen Mazdrashki <kamenim@samba.org> | 2011-02-26 20:36:19 +0200 |
---|---|---|
committer | Kamen Mazdrashki <kamenim@samba.org> | 2011-02-27 00:23:16 +0200 |
commit | f0bde828e0ca76752c23920cc0fd563866e5a90b (patch) | |
tree | 77df7397f2948839ad641ba11015bbc3c0986327 /source4/dsdb/repl | |
parent | 48200c27eaaa961dd17f27a973ab07ccb7afbd8f (diff) | |
download | samba-f0bde828e0ca76752c23920cc0fd563866e5a90b.tar.gz samba-f0bde828e0ca76752c23920cc0fd563866e5a90b.tar.bz2 samba-f0bde828e0ca76752c23920cc0fd563866e5a90b.zip |
s4-drepl: Pass replication options from DsReplicaSync call
Diffstat (limited to 'source4/dsdb/repl')
-rw-r--r-- | source4/dsdb/repl/drepl_extended.c | 2 | ||||
-rw-r--r-- | source4/dsdb/repl/drepl_out_pull.c | 4 | ||||
-rw-r--r-- | source4/dsdb/repl/drepl_service.c | 9 | ||||
-rw-r--r-- | source4/dsdb/repl/drepl_service.h | 2 |
4 files changed, 12 insertions, 5 deletions
diff --git a/source4/dsdb/repl/drepl_extended.c b/source4/dsdb/repl/drepl_extended.c index cf1c25a097..4d645941bb 100644 --- a/source4/dsdb/repl/drepl_extended.c +++ b/source4/dsdb/repl/drepl_extended.c @@ -198,7 +198,7 @@ WERROR drepl_request_extended_op(struct dreplsrv_service *service, data->sdsa = sdsa; werr = dreplsrv_schedule_partition_pull_source(service, sdsa, - extended_op, fsmo_info, + 0, extended_op, fsmo_info, extended_op_callback, data); if (!W_ERROR_IS_OK(werr)) { talloc_free(sdsa); diff --git a/source4/dsdb/repl/drepl_out_pull.c b/source4/dsdb/repl/drepl_out_pull.c index 11165f4a3e..0c68cc9310 100644 --- a/source4/dsdb/repl/drepl_out_pull.c +++ b/source4/dsdb/repl/drepl_out_pull.c @@ -89,6 +89,7 @@ void drepl_reps_update(struct dreplsrv_service *s, const char *reps_attr, WERROR dreplsrv_schedule_partition_pull_source(struct dreplsrv_service *s, struct dreplsrv_partition_source_dsa *source, + uint32_t options, enum drsuapi_DsExtendedOperation extended_op, uint64_t fsmo_info, dreplsrv_extended_callback_t callback, @@ -101,6 +102,7 @@ WERROR dreplsrv_schedule_partition_pull_source(struct dreplsrv_service *s, op->service = s; op->source_dsa = source; + op->options = options; op->extended_op = extended_op; op->fsmo_info = fsmo_info; op->callback = callback; @@ -121,7 +123,7 @@ static WERROR dreplsrv_schedule_partition_pull(struct dreplsrv_service *s, for (cur = p->sources; cur; cur = cur->next) { status = dreplsrv_schedule_partition_pull_source(s, cur, - DRSUAPI_EXOP_NONE, 0, + 0, DRSUAPI_EXOP_NONE, 0, NULL, NULL); W_ERROR_NOT_OK_RETURN(status); } diff --git a/source4/dsdb/repl/drepl_service.c b/source4/dsdb/repl/drepl_service.c index ab97ba650d..658d597c5d 100644 --- a/source4/dsdb/repl/drepl_service.c +++ b/source4/dsdb/repl/drepl_service.c @@ -170,6 +170,7 @@ static void _drepl_replica_sync_done_cb(struct dreplsrv_service *service, static WERROR _drepl_schedule_replication(struct dreplsrv_service *service, struct dreplsrv_partition_source_dsa *dsa, struct drsuapi_DsReplicaObjectIdentifier *nc, + uint32_t rep_options, struct drepl_replica_sync_cb_data *data, TALLOC_CTX *mem_ctx) { @@ -181,7 +182,7 @@ static WERROR _drepl_schedule_replication(struct dreplsrv_service *service, } /* schedule replication item */ - werr = dreplsrv_schedule_partition_pull_source(service, dsa, + werr = dreplsrv_schedule_partition_pull_source(service, dsa, rep_options, DRSUAPI_EXOP_NONE, 0, fn_callback, data); if (!W_ERROR_IS_OK(werr)) { @@ -277,7 +278,8 @@ static NTSTATUS drepl_replica_sync(struct irpc_message *msg, if (req1->options & DRSUAPI_DRS_SYNC_ALL) { for (dsa = p->sources; dsa; dsa = dsa->next) { /* schedule replication item */ - werr = _drepl_schedule_replication(service, dsa, nc, cb_data, msg); + werr = _drepl_schedule_replication(service, dsa, nc, + req1->options, cb_data, msg); if (!W_ERROR_IS_OK(werr)) { REPLICA_SYNC_FAIL("_drepl_schedule_replication() failed", werr); @@ -311,7 +313,8 @@ static NTSTATUS drepl_replica_sync(struct irpc_message *msg, } /* schedule replication item */ - werr = _drepl_schedule_replication(service, dsa, nc, cb_data, msg); + werr = _drepl_schedule_replication(service, dsa, nc, + req1->options, cb_data, msg); if (!W_ERROR_IS_OK(werr)) { REPLICA_SYNC_FAIL("_drepl_schedule_replication() failed", werr); diff --git a/source4/dsdb/repl/drepl_service.h b/source4/dsdb/repl/drepl_service.h index 80f60d6812..c454ac618a 100644 --- a/source4/dsdb/repl/drepl_service.h +++ b/source4/dsdb/repl/drepl_service.h @@ -125,6 +125,8 @@ struct dreplsrv_out_operation { struct dreplsrv_partition_source_dsa *source_dsa; + /* replication options - currently used by DsReplicaSync */ + uint32_t options; enum drsuapi_DsExtendedOperation extended_op; uint64_t fsmo_info; enum drsuapi_DsExtendedError extended_ret; |