How mlcp Uses the Host List
You must specify at least one host with -host
command line option. You can specify multiple hosts.
If any hostname listed in the value of the -host
option is not resolvable by mlcp at the beginning of a job, then mlcp will abort the job with an IllegalArgumentException
.
Assuming all hostnames are resolvable, mlcp uses the first of these hosts to gather information about the target database. If mlcp is unable to connect to the first host in the -host
list, then mlcp will move on to the next host in the list. If mlcp cannot connect to any of the listed hosts, then the job will fail with an IOException
.
If mlcp successfully retrieves a list of forest hosts, then mlcp subsequently connects directly to these hosts when distributing work across the cluster, whether or not these hosts are specified in the -host
option. In this way, your job does not need to be aware cluster topology.
This behavior applies to the import
, export
, and copy
commands. (For a copy job, you specify hosts through -input_host
and -output_host
, rather than -host
.)
You can also restrict mlcp to just the hosts listed by the -host
option. For details, see Restricting the Hosts That mlcp Uses to Connect to MarkLogic.