Class SyncConfig


  • public class SyncConfig
    extends java.lang.Object
    Configuration container for starting a new catalog synchronization. Allows to override several settings of the underlying SyncItemCronJobModel and CatalogVersionSyncCronJobModel.

    In addition it allows to schedule individual items to be synchronized and make the sync process running in partial mode. If no items are specified always a full sync is performed.

    • Constructor Detail

      • SyncConfig

        public SyncConfig()
    • Method Detail

      • getAbortWhenCollidingSyncIsRunning

        public boolean getAbortWhenCollidingSyncIsRunning()
      • setAbortWhenCollidingSyncIsRunning

        public void setAbortWhenCollidingSyncIsRunning​(boolean abortWhenCollidingSyncIsRunning)
      • getLogToFile

        public java.lang.Boolean getLogToFile()
      • setLogToFile

        public void setLogToFile​(java.lang.Boolean logToFile)
      • getLogToDatabase

        public java.lang.Boolean getLogToDatabase()
      • setLogToDatabase

        public void setLogToDatabase​(java.lang.Boolean logToDatabase)
      • getForceUpdate

        public java.lang.Boolean getForceUpdate()
      • setForceUpdate

        public void setForceUpdate​(java.lang.Boolean forceUpdate)
      • getKeepCronJob

        public java.lang.Boolean getKeepCronJob()
      • setKeepCronJob

        public void setKeepCronJob​(java.lang.Boolean keepCronJob)
      • getLogLevelFile

        public JobLogLevel getLogLevelFile()
      • setLogLevelFile

        public void setLogLevelFile​(JobLogLevel logLevelFile)
      • getLogLevelDatabase

        public JobLogLevel getLogLevelDatabase()
      • setLogLevelDatabase

        public void setLogLevelDatabase​(JobLogLevel logLevelDatabase)
      • getCreateSavedValues

        public java.lang.Boolean getCreateSavedValues()
      • setCreateSavedValues

        public void setCreateSavedValues​(java.lang.Boolean createSavedValues)
      • getErrorMode

        public ErrorMode getErrorMode()
      • setErrorMode

        public void setErrorMode​(ErrorMode errorMode)
      • getSynchronous

        public java.lang.Boolean getSynchronous()
      • setSynchronous

        public void setSynchronous​(java.lang.Boolean synchronous)
      • getFullSync

        @Deprecated
        public java.lang.Boolean getFullSync()
        Deprecated.
        since 6.3.0 - usehasPartialSyncSchedule() instead to determine whether a partial or full sync is to be executed
      • hasPartialSyncSchedule

        public boolean hasPartialSyncSchedule()
        Tells whether items have been added to the configuration and therefore the sync process is running in partial sync mode.
      • setFullSync

        @Deprecated
        public void setFullSync​(java.lang.Boolean fullSync)
        Deprecated.
        since 6.3.0 - not used any more
      • addItemToSync

        public void addItemToSync​(PK originalItemPK)
        Adds a specific item from the source catalog to be copied or updated. Even if no target item is specified here the process will detect the potentially existing copy.
        See Also:
        addItemToSync(PK, PK)
      • addItemToSync

        public void addItemToSync​(PK originalItemPK,
                                  PK copyItemPK)
        Adds a specific item from the source catalog to be copied or updated. This method allows to specify the existing copy of the item as well. Note that if the copy is omitted the sync process will perform a lookup for the copy any way.
        See Also:
        addItemToSync(PK)
      • addItemToDelete

        public void addItemToDelete​(PK copyItemPK)
        Adds a specific item from the target catalog version to be removed within the sync process. Use this to schedule removal of items which no longer exists in the source catalog version. However, be aware of the sync not checking whether there's really no original left and just deletes the scheduled item!
      • getPartialSyncSchedule

        public java.util.List<PK[]> getPartialSyncSchedule()
        Returns the partial sync schedule or an empty list if a full sync is intended.
        See Also:
        hasPartialSyncSchedule()