synchro_exec.php
Purpose
This service is used for data synchronization.
Invoke this service to trigger the synchronization of a given list of data sources.
This service is designed to be used when performing data synchronization with an ETL:
-
The ETL updates the data from tables `Synchro…`
-
The ETL invokes synchro_exec.php to make the synchronization effective
Example
php -q /var/www/itop/synchro/synchro_exec.php --auth_user=john --auth_pwd=trust,no1 --data_sources=1
Arguments
Argument | Description | Defaut value |
---|---|---|
param_file | Parameters file - see Parameters file | - |
auth_user | User login - CLI mode only | - |
auth_pwd | User password - CLI mode only | - |
data_sources | Coma separated list of data sources to be synchronized | Mandatory! |
max_chunk_size | integer: the maximum number of replicas to process in one pass. A separate PHP process will be spawned for processing each chunk of max_chunk_size replicas. This option can be handy if the synchronization uses a huge amount of memory and you suspect memory leaks in the synchro processing. | Optional |
simulate | If set to 1 the whole synchro process will be
enclosed inside a transaction and never committed, but the report
of the actions it should have actually performed is produced. This
parameter is NOT compatible with the
max_chunk_size parameter. |
Optional |
Output
Normal execution
Normal execution: Replicas: 123 Replicas touched since last synchro: 12 Objects deleted: 2 Objects deletion errors: 0 Objects obsoleted: 1 Objects obsolescence errors: 0 Objects created: 3 Objects creation errors: 1 Objects updated: 4 Objects update errors: 0 Objects reconciled (updated): 5 Objects reconciled (unchanged): 1 Objects reconciliation errors: 1 Replica disappeared, no action taken: 3
Error
In this example, the argument data_sources is set to “432”, which does not correspond to an existing data source.
ERROR: The data source (id=432) does not exist.
Allowed users
Administrators will always be allowed to execute this page.
Non administrators will be
allowed if they are marked as being owner of the data source.
History
Available since 1.1
2_7_0/advancedtopics/synchro_exec.txt · Last modified:
2021/03/10 16:59 by 127.0.0.1