Couchbase Lite C
Couchbase Lite C API
Data Fields
CBLReplicatorConfiguration Struct Reference

The configuration of a replicator. More...

#include <cbl/CBLReplicator.h>

Data Fields

CBLDatabasedatabase
 The database to replicate. More...
 
CBLEndpointendpoint
 The address of the other database to replicate with. More...
 
CBLReplicatorType replicatorType
 Push, pull or both. More...
 
bool continuous
 Continuous replication? More...
 
bool disableAutoPurge
 If auto purge is active, then the library will automatically purge any documents that the replicating user loses access to via the Sync Function on Sync Gateway. More...
 
unsigned maxAttempts
 Max retry attempts where the initial connect to replicate counts toward the given value. More...
 
unsigned maxAttemptWaitTime
 Max wait time between retry attempts in seconds. Specify 0 to use the default value of 300 seconds. More...
 
unsigned heartbeat
 The heartbeat interval in seconds. Specify 0 to use the default value of 300 seconds. More...
 
CBLAuthenticator *_cbl_nullable authenticator
 Authentication credentials, if needed. More...
 
const CBLProxySettings *_cbl_nullable proxy
 HTTP client proxy settings. More...
 
FLDict _cbl_nullable headers
 Extra HTTP headers to add to the WebSocket request. More...
 
FLSlice pinnedServerCertificate
 An X.509 cert to "pin" TLS connections to (PEM or DER) More...
 
FLSlice trustedRootCertificates
 Set of anchor certs (PEM format) More...
 
FLArray _cbl_nullable channels
 Optional set of channels to pull from. More...
 
FLArray _cbl_nullable documentIDs
 Optional set of document IDs to replicate. More...
 
CBLReplicationFilter _cbl_nullable pushFilter
 Optional callback to filter which docs are pushed. More...
 
CBLReplicationFilter _cbl_nullable pullFilter
 Optional callback to validate incoming docs. More...
 
CBLConflictResolver _cbl_nullable conflictResolver
 Optional conflict-resolver callback. More...
 
void *_cbl_nullable context
 Arbitrary value that will be passed to callbacks. More...
 
CBLPropertyEncryptor _cbl_nullable propertyEncryptor
 Optional callback to encrypt CBLEncryptable values. More...
 
CBLPropertyDecryptor _cbl_nullable propertyDecryptor
 Optional callback to decrypt encrypted CBLEncryptable values. More...
 
bool acceptParentDomainCookies
 The option to remove the restriction that does not allow the replicator to save the parent-domain cookies, the cookies whose domains are the parent domain of the remote host, from the HTTP response. More...
 

Detailed Description

The configuration of a replicator.

Field Documentation

◆ acceptParentDomainCookies

bool CBLReplicatorConfiguration::acceptParentDomainCookies

The option to remove the restriction that does not allow the replicator to save the parent-domain cookies, the cookies whose domains are the parent domain of the remote host, from the HTTP response.

For example, when the option is set to true, the cookies whose domain are “.foo.com” returned by “bar.foo.com” host will be permitted to save. This is only recommended if the host issuing the cookie is well trusted.

This option is disabled by default, which means that the parent-domain cookies are not permitted to save by default.

◆ authenticator

CBLAuthenticator* _cbl_nullable CBLReplicatorConfiguration::authenticator

Authentication credentials, if needed.

◆ channels

FLArray _cbl_nullable CBLReplicatorConfiguration::channels

Optional set of channels to pull from.

◆ conflictResolver

CBLConflictResolver _cbl_nullable CBLReplicatorConfiguration::conflictResolver

Optional conflict-resolver callback.

◆ context

void* _cbl_nullable CBLReplicatorConfiguration::context

Arbitrary value that will be passed to callbacks.

◆ continuous

bool CBLReplicatorConfiguration::continuous

Continuous replication?

◆ database

CBLDatabase* CBLReplicatorConfiguration::database

The database to replicate.

◆ disableAutoPurge

bool CBLReplicatorConfiguration::disableAutoPurge

If auto purge is active, then the library will automatically purge any documents that the replicating user loses access to via the Sync Function on Sync Gateway.

If disableAutoPurge is true, this behavior is disabled and an access removed event will be sent to any document listeners that are active on the replicator.

IMPORTANT: For performance reasons, the document listeners must be added before the replicator is started or they will not receive the events.

◆ documentIDs

FLArray _cbl_nullable CBLReplicatorConfiguration::documentIDs

Optional set of document IDs to replicate.

◆ endpoint

CBLEndpoint* CBLReplicatorConfiguration::endpoint

The address of the other database to replicate with.

◆ headers

FLDict _cbl_nullable CBLReplicatorConfiguration::headers

Extra HTTP headers to add to the WebSocket request.

◆ heartbeat

unsigned CBLReplicatorConfiguration::heartbeat

The heartbeat interval in seconds. Specify 0 to use the default value of 300 seconds.

◆ maxAttempts

unsigned CBLReplicatorConfiguration::maxAttempts

Max retry attempts where the initial connect to replicate counts toward the given value.

Specify 0 to use the default value, 10 times for a non-continuous replicator and max-int time for a continuous replicator. Specify 1 means there will be no retry after the first attempt.

◆ maxAttemptWaitTime

unsigned CBLReplicatorConfiguration::maxAttemptWaitTime

Max wait time between retry attempts in seconds. Specify 0 to use the default value of 300 seconds.

◆ pinnedServerCertificate

FLSlice CBLReplicatorConfiguration::pinnedServerCertificate

An X.509 cert to "pin" TLS connections to (PEM or DER)

◆ propertyDecryptor

CBLPropertyDecryptor _cbl_nullable CBLReplicatorConfiguration::propertyDecryptor

Optional callback to decrypt encrypted CBLEncryptable values.

◆ propertyEncryptor

CBLPropertyEncryptor _cbl_nullable CBLReplicatorConfiguration::propertyEncryptor

Optional callback to encrypt CBLEncryptable values.

◆ proxy

const CBLProxySettings* _cbl_nullable CBLReplicatorConfiguration::proxy

HTTP client proxy settings.

◆ pullFilter

CBLReplicationFilter _cbl_nullable CBLReplicatorConfiguration::pullFilter

Optional callback to validate incoming docs.

◆ pushFilter

CBLReplicationFilter _cbl_nullable CBLReplicatorConfiguration::pushFilter

Optional callback to filter which docs are pushed.

◆ replicatorType

CBLReplicatorType CBLReplicatorConfiguration::replicatorType

Push, pull or both.

◆ trustedRootCertificates

FLSlice CBLReplicatorConfiguration::trustedRootCertificates

Set of anchor certs (PEM format)


The documentation for this struct was generated from the following file: