Skip to content

Commit

Permalink
when registering on the pull thread, we need to also syncTriggers.
Browse files Browse the repository at this point in the history
  • Loading branch information
chenson42 committed Jul 18, 2008
1 parent c35f739 commit db3d3c6
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
Expand Up @@ -29,6 +29,7 @@
import org.apache.commons.logging.LogFactory;
import org.jumpmind.symmetric.common.ErrorConstants;
import org.jumpmind.symmetric.model.Node;
import org.jumpmind.symmetric.service.IBootstrapService;
import org.jumpmind.symmetric.service.INodeService;
import org.jumpmind.symmetric.service.IDataLoaderService;
import org.jumpmind.symmetric.service.IPullService;
Expand All @@ -46,12 +47,15 @@ public class PullService extends AbstractService implements IPullService {
private IDataLoaderService dataLoaderService;

private IRegistrationService registrationService;

private IBootstrapService bootstrapService;

public void pullData() {

// register if we haven't already been registered
if (!registrationService.isRegisteredWithServer()) {
registrationService.registerWithServer();
bootstrapService.syncTriggers();
}

List<Node> nodes = nodeService.findNodesToPull();
Expand Down Expand Up @@ -93,4 +97,9 @@ public void setDataLoaderService(IDataLoaderService dataLoaderService) {
public void setRegistrationService(IRegistrationService registrationService) {
this.registrationService = registrationService;
}

public void setBootstrapService(IBootstrapService bootstrapService) {
this.bootstrapService = bootstrapService;
}

}
1 change: 1 addition & 0 deletions symmetric/src/main/resources/symmetric-services.xml
Expand Up @@ -122,6 +122,7 @@
<property name="registrationService" ref="registrationService" />
<property name="dataLoaderService" ref="dataLoaderService" />
<property name="nodeService" ref="nodeService" />
<property name="bootstrapService" ref="bootstrapService" />
<property name="parameterService" ref="parameterService" />
</bean>

Expand Down

0 comments on commit db3d3c6

Please sign in to comment.