It's all about the answers!

Ask a question

Force repository syncing after resource change


Srimanth Gunturi (206125) | asked Oct 26 '07, 6:59 p.m.
JAZZ DEVELOPER
Hello,
After I make a change to a resource, I would like to automatically
deliver the change to the server. However the creation of a change-set
etc. happens in a separate job and is not available immediately after
changing the resource. Is there anyway to force the sync mechanism to
finish creating the change-set from a resource change?
Regards,
Sri.

3 answers



permanent link
Srimanth Gunturi (206125) | answered Nov 01 '07, 1:15 a.m.
JAZZ DEVELOPER
Hello,
Ive been unsuccessful with various API to force a reconcile of local
workspace changes -
FileSystemResourcesPlugin.getComponentSyncModel().refresh(true, monitor);
FileSystemCore.getSharingManager().getLocalChangeManager().refreshChanges(sd.getConnectionHandle(),
sd.getComponent(), monitor);
FileSystemCore.getSharingManager().getLocalChangeManager().syncPendingChanges(sd.getConnectionHandle(),
sd.getComponent(), ResourcesPlugin.getWorkspace().getRoot().getFullPath());

Could someone dealing with local SCM changes please provide some
guidance as to how one can force resource changes to turn up in
change-sets synchronously.. currently it seems to be happening in the
background and there seems to be no way to find out when it finishes.
Regards,
Sri.



Srimanth Gunturi wrote:
Hello,
After I make a change to a resource, I would like to automatically
deliver the change to the server. However the creation of a change-set
etc. happens in a separate job and is not available immediately after
changing the resource. Is there anyway to force the sync mechanism to
finish creating the change-set from a resource change?
Regards,
Sri.

permanent link
Dmitry Karasik (1.8k11) | answered Nov 01 '07, 4:04 a.m.
JAZZ DEVELOPER
On Thu, 01 Nov 2007 01:15:35 -0400, Srimanth Gunturi wrote:

Could someone dealing with local SCM changes please provide some
guidance as to how one can force resource changes to turn up in
change-sets synchronously..


call new EclipseWorkspaceCommitOperation(workspace, component, "comment",
null).run();

- Dmitry

permanent link
Srimanth Gunturi (206125) | answered Nov 01 '07, 11:06 a.m.
JAZZ DEVELOPER
That has helped very much. Thank you for taking time to provide this
information.
Regards,
Sri.


Dmitry Karasik wrote:
On Thu, 01 Nov 2007 01:15:35 -0400, Srimanth Gunturi wrote:

Could someone dealing with local SCM changes please provide some
guidance as to how one can force resource changes to turn up in
change-sets synchronously..


call new EclipseWorkspaceCommitOperation(workspace, component, "comment",
null).run();

- Dmitry

Your answer


Register or to post your answer.