Run replication task from shell

Phil1295

Explorer
Joined
Sep 20, 2020
Messages
79
As the title suggests, can we start the replication task programmed in GUI from shell ? Or we'll have to script the replication task its self ?
 

sretalla

Powered by Neutrality
Moderator
Joined
Jan 1, 2016
Messages
9,700
You can probably use the middleware client to call it via API.

start by querying the list to get the ID of the job you want to run:
midclt call replication.query

Then, using that ID (let's say it's 1 in this case).
midclt call replication.run 1
 

Phil1295

Explorer
Joined
Sep 20, 2020
Messages
79
You can probably use the middleware client to call it via API.

start by querying the list to get the ID of the job you want to run:
midclt call replication.query

Then, using that ID (let's say it's 1 in this case).
midclt call replication.run 1
Thank you a lot,
I was not aware of the middleware APIs
I took a look at the docs now. Thank you a lot. This really makes it easier to script.
However, I will have to think if it is worth it since any change in the APIs will break the code, unlike a bash scripting

Thank you again
 

sretalla

Powered by Neutrality
Moderator
Joined
Jan 1, 2016
Messages
9,700
The API is pretty stable as far as I can see... iX hasn't got a lot of reason to throw out the work they have done and the Web GUI actually relies on it too, so it unlikely they will kill it so badly that it impacts you.
 
Top