Hi,
I am making changes to the English pages programatically and live copy will copy those changes to Spanish. I would like to know when the live copy is completed copying the changes to Spanish. So I can make changes on top of them in Spanish. Is there anyway to get the live copy synchronization status in Java?
Thanks.
Solved! Go to Solution.
Views
Replies
Total Likes
bsloki wrote...
Are you looking to make the changes to the live copy programatically ??
No. Basically I am doing replication in both English and Spanish locales programatically. Live copy will copy the content from English to Spanish. Before I kick off the replication in Spanish, I want to know if the live copy is completed copying the content from English to Spanish. So I am looking for a flag to know whether live copy is completed copying that content.
I have written the below code to get the live status. I think it will work but not sure.
@Reference
private LiveRelationshipManager liveRelManager;
LiveRelationship liveRelationship;
try {
liveRelationship = liveRelManager.getLiveRelationship([LIVE COPY PATH], true);
Map < String, Boolean > map = liveRelationship.getStatus().getAdvancedStatus();
for (Entry < String, Boolean > element: map.entrySet()) {
System.out.println("Key is: " + element.getKey());
System.out.println("Value is: " + element.getValue());
}
}
Views
Replies
Total Likes
I see in MSM API that if we have LiveRelationship reference variable then we can get the live copy status.
Can you let me know how to get this reference variable?
Views
Replies
Total Likes
I will look for sample code. As far as I know - there are no articles on this subject.
Views
Replies
Total Likes
Are you looking to make the changes to the live copy programatically ??
Views
Replies
Total Likes
bsloki wrote...
Are you looking to make the changes to the live copy programatically ??
No. Basically I am doing replication in both English and Spanish locales programatically. Live copy will copy the content from English to Spanish. Before I kick off the replication in Spanish, I want to know if the live copy is completed copying the content from English to Spanish. So I am looking for a flag to know whether live copy is completed copying that content.
I have written the below code to get the live status. I think it will work but not sure.
@Reference
private LiveRelationshipManager liveRelManager;
LiveRelationship liveRelationship;
try {
liveRelationship = liveRelManager.getLiveRelationship([LIVE COPY PATH], true);
Map < String, Boolean > map = liveRelationship.getStatus().getAdvancedStatus();
for (Entry < String, Boolean > element: map.entrySet()) {
System.out.println("Key is: " + element.getKey());
System.out.println("Value is: " + element.getValue());
}
}
Views
Replies
Total Likes
Yes... that should work !! Let us know if you were able to get it !
Views
Replies
Total Likes
Views
Likes
Replies
Views
Likes
Replies