Package de.hybris.platform.catalog.jalo
Class SyncItemJob
- java.lang.Object
-
- All Implemented Interfaces:
TriggerableJob,java.io.Serializable,java.lang.Comparable
- Direct Known Subclasses:
GeneratedCatalogVersionSyncJob
@Deprecated public class SyncItemJob extends GeneratedSyncItemJob implements TriggerableJob
Deprecated.since ages - useCatalogVersionSyncJobinsteadSuperclass for job which synchronizes content of a catalog version to another catalog version.- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classSyncItemJob.CompletionInfoDeprecated.CompletionInfostatic classSyncItemJob.ModifiedItemsPairDeprecated.ModifiedItemsPairstatic classSyncItemJob.SyncAttributeDescriptorConfigDataDeprecated.classSyncItemJob.SyncItemCopyContextDeprecated.Own copy context from inside the job.-
Nested classes/interfaces inherited from class de.hybris.platform.cronjob.jalo.Job
Job.JobFileLogContainer, Job.Synchronicity
-
Nested classes/interfaces inherited from class de.hybris.platform.jalo.GenericItem
GenericItem.GenericItemImpl
-
Nested classes/interfaces inherited from class de.hybris.platform.jalo.c2l.LocalizableItem
LocalizableItem.LocalizableItemImpl
-
Nested classes/interfaces inherited from class de.hybris.platform.jalo.ExtensibleItem
ExtensibleItem.ExtensibleItemImpl
-
Nested classes/interfaces inherited from class de.hybris.platform.jalo.Item
Item.AttributeFilter, Item.AttributeMode, Item.CachedGetter, Item.CachedSetter, Item.ItemAttributeMap, Item.ItemConstraint, Item.ItemImpl, Item.JaloCachedComputationException
-
-
Field Summary
Fields Modifier and Type Field Description static java.util.Set<java.lang.String>HIDDEN_ATTRIBUTESDeprecated.protected static java.lang.StringSTART_TIMEDeprecated.-
Fields inherited from class de.hybris.platform.catalog.jalo.GeneratedSyncItemJob
CREATENEWITEMS, DEFAULT_INITIAL_ATTRIBUTES, EFFECTIVESYNCLANGUAGES, EXCLUSIVEMODE, EXECUTIONS, EXPORTATTRIBUTEDESCRIPTORS, REMOVEMISSINGITEMS, ROOTTYPES, SOURCEVERSION, SOURCEVERSIONHANDLER, SYNCATTRIBUTECONFIGURATIONS, SYNCITEMJOB2PRINCIPAL_MARKMODIFIED, SYNCITEMJOB2PRINCIPAL_SRC_ORDERED, SYNCITEMJOB2PRINCIPAL_TGT_ORDERED, SYNCJOB2LANGREL_MARKMODIFIED, SYNCJOB2LANGREL_SRC_ORDERED, SYNCJOB2LANGREL_TGT_ORDERED, SYNCJOB2TYPEREL_MARKMODIFIED, SYNCJOB2TYPEREL_SRC_ORDERED, SYNCJOB2TYPEREL_TGT_ORDERED, SYNCLANGUAGES, SYNCORDER, SYNCPRINCIPALS, SYNCPRINCIPALSONLY, TARGETVERSION, TARGETVERSIONHANDLER
-
Fields inherited from class de.hybris.platform.cronjob.jalo.Job
CTX_CURRENTCRONJOB, CTX_CURRENTJOB
-
Fields inherited from class de.hybris.platform.cronjob.jalo.GeneratedJob
ACTIVE, ALTERNATIVEDATASOURCEID, CHANGERECORDINGENABLED, CODE, CRONJOBS, CRONJOBSHANDLER, EMAILADDRESS, EMAILNOTIFICATIONTEMPLATE, ERRORMODE, LOGLEVELDATABASE, LOGLEVELFILE, LOGTODATABASE, LOGTOFILE, NODEGROUP, NODEID, PRIORITY, REMOVEONEXIT, REQUESTABORT, REQUESTABORTSTEP, RESTRICTIONS, RESTRICTIONSHANDLER, RETRY, SENDEMAIL, SESSIONCONTEXTVALUES, SESSIONCURRENCY, SESSIONLANGUAGE, SESSIONUSER, SINGLEEXECUTABLE, TRIGGERS, TRIGGERSHANDLER
-
Fields inherited from class de.hybris.platform.jalo.c2l.LocalizableItem
LANGUAGE_FALLBACK_ENABLED
-
Fields inherited from class de.hybris.platform.jalo.Item
_CREATION_TIME_INTERNAL, _MODIFIED_TIME_INTERNAL, accessorLog, CREATION_TIME, DISABLE_ATTRIBUTE_CHECK, DISABLE_ITEMCHECK_BEFORE_REMOVABLE, EVEN, FEATURE_ACCESSMAP_QUALIFIER, HJMPTS, INITIAL_CREATION_FLAG, isJaloOnly, MODIFIED_TIME, NEGATIVE, NOT_FOUND, OWNER, PK, POSITIVE, SAVE_FROM_SERVICE_LAYER, staticTransientObjects, TYPE
-
Fields inherited from class de.hybris.platform.util.BridgeAbstraction
impl, tenant
-
-
Constructor Summary
Constructors Constructor Description SyncItemJob()Deprecated.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description voidaddCatalogItemsToSync(SyncItemCronJob cronJob, java.util.Collection<? extends Item> items)Deprecated.Added any catalog item except categories to a syncronization.voidaddCategoriesToSync(SyncItemCronJob cronJob, java.util.Collection<? extends Category> categories, boolean includeSubcategories, boolean includeProducts)Deprecated.protected java.util.List<ComposedType>assureCatalogItemTypes(java.util.List<ComposedType> types)Deprecated.protected booleancanSelectAttribute(AttributeDescriptor attributeDescriptor)Deprecated.protected booleancanUndo(CronJob cronJob)Deprecated.This job does not support undo!protected booleancheckCatalogVersionValidity(SyncItemCronJob cronJob, SyncItemJob.SyncItemCopyContext syncItemCopyContext)Deprecated.Use this method to check if the given catalog version is valid for synchronization.protected booleanconfigAlreadyExists(AttributeDescriptor attributeDescriptor)Deprecated.protected voidconfigureFullSyncForItemType(SessionContext ctx, SyncItemCronJob cronJob, ComposedType type, java.lang.String additionalQueryRestrictions, boolean removeMissing, boolean createNew, boolean forceUpdate, int range)Deprecated.Configures a full synchronization of the items of a given type according to the specified sync cronjob settings.voidconfigureFullVersionSync(SyncItemCronJob cronJob)Deprecated.Collects all changes between the source and target version of this job.protected voidcopyItem(ItemCopyContext itemCopyContext, SyncItemCronJob cronJob, Item src, Item tgt)Deprecated.protected ItemCopyContextcreateCopyContext(SyncItemCronJob cronJob, CatalogVersion srcV, CatalogVersion tgtV, java.util.Map<PK,PK> alreadyFinished)Deprecated.protected SyncAttributeDescriptorConfigcreateDefaultConfigFor(SessionContext ctx, AttributeDescriptor attributeDescriptor)Deprecated.protected ItemcreateItem(SessionContext ctx, ComposedType type, Item.ItemAttributeMap allAttributes)Deprecated.Superclass method overridden to ensure initial attributesGeneratedSyncItemJob.SOURCEVERSION, andGeneratedSyncItemJob.TARGETVERSION.protected SessionContextcreateSyncSessionContext(SyncItemCronJob cronJob)Deprecated.Returns a newSessionContextwith the following settings.
LANGUAGE: null DISABLE_RESTRICTIONS: false DISABLE_RESTRICTION_GROUP_INHERITANCE: false USE_FAST_ALGORITHMS: true DISABLE_ATTRIBUTE_CHECK: true DISABLE_SUBCATEGORY_REMOVALCHECK: true DISABLE_SETALLOWEDPRINCIPAL_RECURSIVELY: true LANGUAGE_FALLBACK_ENABLED: false TRANSACTION_4_ALLATTRIBUTES: falseprotected CronJob.CronJobResultdoAbort(SyncItemCronJob cronJob)Deprecated.This method is called if abort is requested by the user while still executing this job.protected booleandoSynchronization(SyncItemJob.SyncItemCopyContext syncItemCopyContext, SyncItemCronJob cronJob)Deprecated.Executes actual synchronization.protected java.lang.StringgetAdditionalQueryRestrictions(SessionContext ctx, ComposedType rootType, SyncItemCronJob cronJob)Deprecated.java.util.Map<AttributeDescriptor,java.lang.Boolean>getAllExportAttributeDescriptors(SessionContext ctx)Deprecated.Getter for HMC editor - we pass a map { AttributeDescriptor -> Boolean }protected java.util.List<java.util.List>getAttributeAndConfigPairs()Deprecated.Returns [AttributeDescriptor,SyncAttributeDescriptorConfig] pairs for all existing declared attribute descriptors and their sync config item if it exists for this job.SyncItemJob.CompletionInfogetCompletionInfo(SyncItemCronJob cronJob)Deprecated.SyncAttributeDescriptorConfiggetConfigFor(SessionContext ctx, AttributeDescriptor attributeDescriptor, boolean createOnDemand)Deprecated.Returns theSyncAttributeDescriptorConfiginstance which is responsible for all publication settings of the specified attribute descriptor.SyncAttributeDescriptorConfiggetConfigFor(AttributeDescriptor attributeDescriptor, boolean createOnDemand)Deprecated.Returns theSyncAttributeDescriptorConfiginstance which is responsible for all publication settings of the specified attribute descriptor.static java.util.List<ComposedType>getDefaultRootTypes()Deprecated.Provides the list of default root types.protected intgetDuplicatedCatalogItemsCount(SessionContext ctx, CatalogVersion version, SyncItemCronJob cronJob, ComposedType type)Deprecated.java.util.Collection<Language>getEffectiveSyncLanguages(SessionContext ctx)Deprecated.Calculates current effective sync languages.longgetElapsedMillis(SyncItemCronJob cronJob)Deprecated.java.util.CollectiongetExecutions(SessionContext ctx)Deprecated.Generated method - Getter of theSyncItemJob.executionsattribute.protected java.util.Set<Item>getMissingTargetItems(java.util.Collection<? extends Item> sourceItems, java.util.Collection<? extends Item> targetItems, CatalogVersion sourceVersion)Deprecated.protected java.util.List<SyncItemJob.ModifiedItemsPair>getModifiedCatalogItemPairs(SessionContext ctx, ComposedType type, int start, int range, boolean forceUpdate)Deprecated.protected java.util.List<SyncItemJob.ModifiedItemsPair>getPossibleCatalogItemPairs(SessionContext ctx, ComposedType type, java.lang.String additionalQueryRestrictions, int start, int range)Deprecated.java.util.List<ComposedType>getRootTypes(SessionContext ctx)Deprecated.Generated method - Getter of theSyncItemJob.rootTypesattribute.protected java.util.List<PK>getSingleVersionCatalogItems(SessionContext ctx, ComposedType type, java.lang.String additionalQueryRestrictions, boolean fromSource, int start, int range)Deprecated.java.util.Collection<SyncAttributeDescriptorConfig>getSyncAttributeConfigurations(SessionContext ctx)Deprecated.Returns a collection containing aSyncAttributeDescriptorConfiginstance for each declared attribute of any catalog item type.protected voidinitializeTimeCounter(SyncItemCronJob cronJob)Deprecated.booleanisAbortable(CronJob conJob)Deprecated.The SyncCatalogVersionJob supports aborting.SyncItemCronJobnewExcecution()Deprecated.since ages - please usenewExecution()SyncItemCronJobnewExecution()Deprecated.New execution.protected CronJob.CronJobResultperformCronJob(CronJob cronJob)Deprecated.You have to implement this method in yourJob.protected voidregisterSynchronizedItem(SyncItemCronJob cronjob, Item source, Item copy, java.lang.String message)Deprecated.Registers a synchronized item pair permanently by creating aChangeDescriptorfor them.voidremove(SessionContext ctx)Deprecated.Removes itsItemSyncTimestampinstances as well.protected voidremoveItem(ItemCopyContext itemCopyContext, SyncItemCronJob cronJob, Item removeItem)Deprecated.protected voidremoveSyncTimestamps(SessionContext ctx)Deprecated.voidsetAllExportAttributeDescriptors(SessionContext ctx, java.util.Map syncMap)Deprecated.setter for HMC editor - we just set the 'includedInSync' attributevoidsetRootTypes(SessionContext ctx, java.util.List<ComposedType> value)Deprecated.Overwritten to ensure that each root type is a catalog item type.voidsetSyncAttributeConfigurations(SessionContext ctx, java.util.Collection param)Deprecated.Generated method - Setter of theSyncItemJob.syncAttributeConfigurationsattribute.protected java.util.List<PK[]>toPendingItemsList(java.util.List<SyncItemJob.ModifiedItemsPair> itemPairs)Deprecated.protected java.util.List<PK[]>toPendingItemsList(java.util.List<PK> itemPKs, boolean remove)Deprecated.-
Methods inherited from class de.hybris.platform.catalog.jalo.GeneratedSyncItemJob
addToRootTypes, addToRootTypes, addToSyncLanguages, addToSyncLanguages, addToSyncPrincipals, addToSyncPrincipals, getAllExportAttributeDescriptors, getDefaultAttributeModes, getEffectiveSyncLanguages, getExecutions, getRootTypes, getRootTypesCount, getRootTypesCount, getSourceVersion, getSourceVersion, getSyncAttributeConfigurations, getSyncLanguages, getSyncLanguages, getSyncLanguagesCount, getSyncLanguagesCount, getSyncOrder, getSyncOrder, getSyncOrderAsPrimitive, getSyncOrderAsPrimitive, getSyncPrincipals, getSyncPrincipals, getSyncPrincipalsCount, getSyncPrincipalsCount, getTargetVersion, getTargetVersion, isCreateNewItems, isCreateNewItems, isCreateNewItemsAsPrimitive, isCreateNewItemsAsPrimitive, isExclusiveMode, isExclusiveMode, isExclusiveModeAsPrimitive, isExclusiveModeAsPrimitive, isMarkModifiedDisabled, isRemoveMissingItems, isRemoveMissingItems, isRemoveMissingItemsAsPrimitive, isRemoveMissingItemsAsPrimitive, isSyncPrincipalsOnly, isSyncPrincipalsOnly, isSyncPrincipalsOnlyAsPrimitive, isSyncPrincipalsOnlyAsPrimitive, removeFromRootTypes, removeFromRootTypes, removeFromSyncLanguages, removeFromSyncLanguages, removeFromSyncPrincipals, removeFromSyncPrincipals, setAllExportAttributeDescriptors, setCreateNewItems, setCreateNewItems, setCreateNewItems, setCreateNewItems, setExclusiveMode, setExclusiveMode, setExclusiveMode, setExclusiveMode, setRemoveMissingItems, setRemoveMissingItems, setRemoveMissingItems, setRemoveMissingItems, setRootTypes, setSourceVersion, setSourceVersion, setSyncAttributeConfigurations, setSyncLanguages, setSyncLanguages, setSyncOrder, setSyncOrder, setSyncOrder, setSyncOrder, setSyncPrincipals, setSyncPrincipals, setSyncPrincipalsOnly, setSyncPrincipalsOnly, setSyncPrincipalsOnly, setSyncPrincipalsOnly, setTargetVersion, setTargetVersion
-
Methods inherited from class de.hybris.platform.cronjob.jalo.Job
canPerform, checkRemovable, configureCronjob, createLogContext, debug, error, fatal, getConfigAttributes, getCronJobsByCode, getCronJobsByCode, getCurrentLogContainer, getEffectiveLogLevel, getNonInitialAttributes, info, isDebugEnabled, isEnabledFor, isErrorEnabled, isInfoEnabled, isPerformable, isPerformable, isUndoable, isWarnEnabled, jobIsCurrentlyRunning, log, logToFile, perform, perform, perform, prepareAfterFinishEvent, prepareBeforeStartEvent, saveToLogFile, sendFinishedEvent, sendStartEvent, setCode, setCronJobs, setCurrentLogContainer, setNonInitialAttributes, startOwnSession, stopOwnSession, switchDataSource, undo, undo, undoCronJob, unsetAlternativeDataSource, unsetCurrentLogContainer, warn
-
Methods inherited from class de.hybris.platform.cronjob.jalo.GeneratedJob
addToRestrictions, addToRestrictions, addToTriggers, addToTriggers, getAlternativeDataSourceID, getAlternativeDataSourceID, getCode, getCode, getCronJobs, getCronJobs, getEmailAddress, getEmailAddress, getEmailNotificationTemplate, getEmailNotificationTemplate, getErrorMode, getErrorMode, getLogLevelDatabase, getLogLevelDatabase, getLogLevelFile, getLogLevelFile, getNodeGroup, getNodeGroup, getNodeID, getNodeID, getNodeIDAsPrimitive, getNodeIDAsPrimitive, getPriority, getPriority, getPriorityAsPrimitive, getPriorityAsPrimitive, getRestrictions, getRestrictions, getSessionCurrency, getSessionCurrency, getSessionLanguage, getSessionLanguage, getSessionUser, getSessionUser, getTriggers, getTriggers, isActive, isActive, isActiveAsPrimitive, isActiveAsPrimitive, isChangeRecordingEnabled, isChangeRecordingEnabled, isChangeRecordingEnabledAsPrimitive, isChangeRecordingEnabledAsPrimitive, isLogToDatabase, isLogToDatabase, isLogToDatabaseAsPrimitive, isLogToDatabaseAsPrimitive, isLogToFile, isLogToFile, isLogToFileAsPrimitive, isLogToFileAsPrimitive, isRemoveOnExit, isRemoveOnExit, isRemoveOnExitAsPrimitive, isRemoveOnExitAsPrimitive, isRequestAbort, isRequestAbort, isRequestAbortAsPrimitive, isRequestAbortAsPrimitive, isRequestAbortStep, isRequestAbortStep, isRequestAbortStepAsPrimitive, isRequestAbortStepAsPrimitive, isRetry, isRetry, isRetryAsPrimitive, isRetryAsPrimitive, isSendEmail, isSendEmail, isSendEmailAsPrimitive, isSendEmailAsPrimitive, isSingleExecutable, isSingleExecutable, isSingleExecutableAsPrimitive, isSingleExecutableAsPrimitive, removeFromRestrictions, removeFromRestrictions, removeFromTriggers, removeFromTriggers, setActive, setActive, setActive, setActive, setAlternativeDataSourceID, setAlternativeDataSourceID, setChangeRecordingEnabled, setChangeRecordingEnabled, setChangeRecordingEnabled, setChangeRecordingEnabled, setCode, setEmailAddress, setEmailAddress, setEmailNotificationTemplate, setEmailNotificationTemplate, setErrorMode, setErrorMode, setLogLevelDatabase, setLogLevelDatabase, setLogLevelFile, setLogLevelFile, setLogToDatabase, setLogToDatabase, setLogToDatabase, setLogToDatabase, setLogToFile, setLogToFile, setLogToFile, setLogToFile, setNodeGroup, setNodeGroup, setNodeID, setNodeID, setNodeID, setNodeID, setPriority, setPriority, setPriority, setPriority, setRemoveOnExit, setRemoveOnExit, setRemoveOnExit, setRemoveOnExit, setRequestAbort, setRequestAbort, setRequestAbort, setRequestAbort, setRequestAbortStep, setRequestAbortStep, setRequestAbortStep, setRequestAbortStep, setRestrictions, setRestrictions, setRetry, setRetry, setRetry, setRetry, setSendEmail, setSendEmail, setSendEmail, setSendEmail, setSessionCurrency, setSessionCurrency, setSessionLanguage, setSessionLanguage, setSessionUser, setSessionUser, setSingleExecutable, setSingleExecutable, setSingleExecutable, setSingleExecutable, setTriggers, setTriggers
-
Methods inherited from class de.hybris.platform.jalo.GenericItem
getImplementation, getInitialProperties, getRelatedItems, setRelatedItems
-
Methods inherited from class de.hybris.platform.jalo.c2l.LocalizableItem
getAllLocalizedProperties, getAllLocalizedProperties, getAllLocalizedProperties, getAllLocalizedProperties, getAllValuesSessionContext, getLocalizedProperty, getLocalizedProperty, getLocalizedPropertyInternal, getLocalizedPropertyNames, getLocalizedPropertyNames, hasLanguage, isEmptyValue, isFallbackEnabled, removeLocalizedProperty, removeLocalizedProperty, setAllLocalizedProperties, setAllLocalizedProperties, setLocalizedProperty, setLocalizedProperty
-
Methods inherited from class de.hybris.platform.jalo.ExtensibleItem
createNonClassAccessor, getAllProperties, getAllProperties, getProperty, getProperty, getPropertyNames, getPropertyNames, removeProperty, removeProperty, setAllProperties, setAllProperties, setProperty, setProperty
-
Methods inherited from class de.hybris.platform.jalo.Item
addLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addLinkedItems, addNegativePermission, addPermission, addPositivePermission, assureExtensionsLoaded, changeTypeAfterCreation, checkConstraint, checkItemPermission, checkMandatoryAttribute, checkMandatoryAttribute, checkPermission, checkPermission, clearPermission, compareTo, ctx, doAfterRemove, doBeforeRemove, equals, getAccessorFor, getAllAttributes, getAllAttributes, getAllAttributes, getAllAttributes, getAllAttributesInternal, getAllLinkedItems, getAndCheckCacheBoundItem, getAttribute, getAttribute, getCacheBoundItem, getComposedType, getComposedTypePK, getCreationTime, getCurrentlyRemovingCount, getLinkedItems, getLinkedItems, getLinkedItems, getLinkedItems, getLinkedItems, getLinkedItems, getLinkedItems, getLinkedItemsCount, getLinkedItemsCount, getLinkedItemsCount, getModificationTime, getNegativePermissions, getOwner, getPermissionMap, getPermissions, getPersistenceVersion, getPK, getPositivePermissions, getRestrictedPrincipals, getSession, getSyncObject, getTenant, getTransientObject, getTransientObjectMap, hashCode, hasRegisteredClassAccessorFor, internal_registerClassAccessorFor, internal_registerNonClassAccessorFor, invalidateLocalCaches, isAlive, isCacheBound, isCurrentlyRemoving, isCurrentlyRemoving, isEmptyRelationValue, isInCreate, isInstanceOf, isItemCheckBeforeRemoveableDisabled, isRelationLocalizationFallbackEnabled, newInstance, notifyExtensionsAfterItemCreation, notifyExtensionsBeforeItemCreation, notifyItemRemoval, notifyManagerAboutItemRemoval, readResolve, registerAccessFor, registerAccessFor, registerJaloInvalidationListeners, remove, removeItemCollection, removeItemCollection, removeLinkedItems, removeLinkedItems, removeLinkedItems, removeLinkedItems, removeLinks, removePartOfItems, removePartOfItems, setAllAttributes, setAllAttributes, setAllAttributesInternal, setAllLinkedItems, setAllLinkedItems, setAllLinkedItems, setAllLinkedItems, setAttribute, setAttribute, setAttributeFromString, setAttributeFromString, setCacheBound, setComposedType, setCreationTime, setImplementation, setLinkedItems, setLinkedItems, setLinkedItems, setLinkedItems, setLinkedItems, setLinkedItems, setLinkedItems, setLinkedItems, setModificationTime, setOwner, setPermissionsByMap, setTransientObject, setUseTA, toString, useTA, writeReplace
-
Methods inherited from class de.hybris.platform.util.BridgeAbstraction
setTenant
-
-
-
-
Field Detail
-
START_TIME
protected static final java.lang.String START_TIME
Deprecated.- See Also:
- Constant Field Values
-
HIDDEN_ATTRIBUTES
public static final java.util.Set<java.lang.String> HIDDEN_ATTRIBUTES
Deprecated.
-
-
Method Detail
-
createItem
protected Item createItem(SessionContext ctx, ComposedType type, Item.ItemAttributeMap allAttributes) throws JaloBusinessException
Deprecated.Superclass method overridden to ensure initial attributesGeneratedSyncItemJob.SOURCEVERSION, andGeneratedSyncItemJob.TARGETVERSION. Additionally it auto-fillsGeneratedJob.CODEin case it is not provided.- Overrides:
createItemin classGeneratedSyncItemJob- Parameters:
ctx- the current session context which this item is created withintype- the actual item type ( since subtypes may not provide a own jalo class this may be different from the type which this method was implemented for )- Returns:
- the new item instance
- Throws:
JaloBusinessException- indicates an error during creation - any changes will be rollbacked
-
remove
public void remove(SessionContext ctx) throws ConsistencyCheckException
Deprecated.Removes itsItemSyncTimestampinstances as well. Be careful, this may take a while!- Overrides:
removein classJob- Parameters:
ctx- A SessionContext object- Throws:
ConsistencyCheckException- if this item could not be removed for some reason- See Also:
Item.remove(de.hybris.platform.jalo.SessionContext)
-
removeSyncTimestamps
protected void removeSyncTimestamps(SessionContext ctx)
Deprecated.
-
getDefaultRootTypes
public static java.util.List<ComposedType> getDefaultRootTypes()
Deprecated.Provides the list of default root types. By now these are- Category
- Product
- Media
- Keyword
- PriceRow (global rows only)
- TaxRow (global rows only)
- DiscountRow (global rows only)
- MediaContainer
-
newExecution
public SyncItemCronJob newExecution()
Deprecated.Description copied from interface:TriggerableJobNew execution.- Specified by:
newExecutionin interfaceTriggerableJob- Returns:
- the cron job
-
newExcecution
@Deprecated public SyncItemCronJob newExcecution()
Deprecated.since ages - please usenewExecution()
-
getExecutions
public java.util.Collection getExecutions(SessionContext ctx)
Deprecated.Description copied from class:GeneratedSyncItemJobGenerated method - Getter of theSyncItemJob.executionsattribute.- Specified by:
getExecutionsin classGeneratedSyncItemJob- Returns:
- the executions
-
isAbortable
public boolean isAbortable(CronJob conJob)
Deprecated.The SyncCatalogVersionJob supports aborting.- Overrides:
isAbortablein classJob- Parameters:
conJob- the current execution of this job.- Returns:
trueif the cronjob is running and the job supports aborting viaGeneratedCronJob.setRequestAbort(boolean)
-
createSyncSessionContext
protected SessionContext createSyncSessionContext(SyncItemCronJob cronJob)
Deprecated.Returns a newSessionContextwith the following settings.
- LANGUAGE: null
- DISABLE_RESTRICTIONS: false
- DISABLE_RESTRICTION_GROUP_INHERITANCE: false
- USE_FAST_ALGORITHMS: true
- DISABLE_ATTRIBUTE_CHECK: true
- DISABLE_SUBCATEGORY_REMOVALCHECK: true
- DISABLE_SETALLOWEDPRINCIPAL_RECURSIVELY: true
- LANGUAGE_FALLBACK_ENABLED: false
- TRANSACTION_4_ALLATTRIBUTES: false
- Parameters:
cronJob- the assignedSyncItemCronJob- Returns:
- new
SessionContextinstance:
-
initializeTimeCounter
protected void initializeTimeCounter(SyncItemCronJob cronJob)
Deprecated.
-
getElapsedMillis
public long getElapsedMillis(SyncItemCronJob cronJob)
Deprecated.
-
canUndo
protected boolean canUndo(CronJob cronJob)
Deprecated.This job does not support undo!
-
getDuplicatedCatalogItemsCount
protected int getDuplicatedCatalogItemsCount(SessionContext ctx, CatalogVersion version, SyncItemCronJob cronJob, ComposedType type)
Deprecated.
-
checkCatalogVersionValidity
protected boolean checkCatalogVersionValidity(SyncItemCronJob cronJob, SyncItemJob.SyncItemCopyContext syncItemCopyContext)
Deprecated.Use this method to check if the given catalog version is valid for synchronization. As default this method will check whether or not duplicate product IDs exist or not. If so a error log is created.- Parameters:
cronJob-syncItemCopyContext-- Returns:
- true if the catalog version is valid (and synchronization may use it)
-
createCopyContext
protected ItemCopyContext createCopyContext(SyncItemCronJob cronJob, CatalogVersion srcV, CatalogVersion tgtV, java.util.Map<PK,PK> alreadyFinished)
Deprecated.
-
registerSynchronizedItem
protected void registerSynchronizedItem(SyncItemCronJob cronjob, Item source, Item copy, java.lang.String message)
Deprecated.Registers a synchronized item pair permanently by creating aChangeDescriptorfor them. If the current cronjob is aborted or crashes these changes are loaded on restart so that no item is synchronized twice.Please note that this feature is disabled if change recording is disabled dor the executed chronjob !
- Parameters:
cronjob- theSyncItemCronJobsource- sourceitemcopy- copyitemmessage- a message
-
getSingleVersionCatalogItems
protected java.util.List<PK> getSingleVersionCatalogItems(SessionContext ctx, ComposedType type, java.lang.String additionalQueryRestrictions, boolean fromSource, int start, int range)
Deprecated.
-
copyItem
protected void copyItem(ItemCopyContext itemCopyContext, SyncItemCronJob cronJob, Item src, Item tgt)
Deprecated.
-
getModifiedCatalogItemPairs
protected java.util.List<SyncItemJob.ModifiedItemsPair> getModifiedCatalogItemPairs(SessionContext ctx, ComposedType type, int start, int range, boolean forceUpdate)
Deprecated.- Returns:
- a list of
SyncItemJob.ModifiedItemsPairs.
-
getPossibleCatalogItemPairs
protected java.util.List<SyncItemJob.ModifiedItemsPair> getPossibleCatalogItemPairs(SessionContext ctx, ComposedType type, java.lang.String additionalQueryRestrictions, int start, int range)
Deprecated.- Returns:
- a list of
SyncItemJob.ModifiedItemsPairs.
-
removeItem
protected void removeItem(ItemCopyContext itemCopyContext, SyncItemCronJob cronJob, Item removeItem)
Deprecated.
-
getMissingTargetItems
protected java.util.Set<Item> getMissingTargetItems(java.util.Collection<? extends Item> sourceItems, java.util.Collection<? extends Item> targetItems, CatalogVersion sourceVersion)
Deprecated.
-
addCatalogItemsToSync
public void addCatalogItemsToSync(SyncItemCronJob cronJob, java.util.Collection<? extends Item> items)
Deprecated.Added any catalog item except categories to a syncronization.- Parameters:
cronJob- the synchronization cronjobitems- the items to add
-
addCategoriesToSync
public void addCategoriesToSync(SyncItemCronJob cronJob, java.util.Collection<? extends Category> categories, boolean includeSubcategories, boolean includeProducts)
Deprecated.
-
configureFullVersionSync
public void configureFullVersionSync(SyncItemCronJob cronJob)
Deprecated.Collects all changes between the source and target version of this job. Depending whether or not new item creation and missing item removal has been configured new (source version) items and missing (source version) items are scheduled too.
-
getAdditionalQueryRestrictions
protected java.lang.String getAdditionalQueryRestrictions(SessionContext ctx, ComposedType rootType, SyncItemCronJob cronJob)
Deprecated.
-
toPendingItemsList
protected java.util.List<PK[]> toPendingItemsList(java.util.List<PK> itemPKs, boolean remove)
Deprecated.
-
toPendingItemsList
protected java.util.List<PK[]> toPendingItemsList(java.util.List<SyncItemJob.ModifiedItemsPair> itemPairs)
Deprecated.
-
configureFullSyncForItemType
protected void configureFullSyncForItemType(SessionContext ctx, SyncItemCronJob cronJob, ComposedType type, java.lang.String additionalQueryRestrictions, boolean removeMissing, boolean createNew, boolean forceUpdate, int range)
Deprecated.Configures a full synchronization of the items of a given type according to the specified sync cronjob settings.- Parameters:
ctx- the enclosing session contextcronJob- the sync cronjob (among others) holding source and target versiontype- the item type specifying which items should be synchronizedadditionalQueryRestrictions- flexible search WHERE parameters to be considered when querying new, removed or possible item pairs when scheduling synchronizationremoveMissing- iftrueall items are removed which still exist in target version but do not exist in source versioncreateNew- iftruenew items are created with the target version if the exist in source versionforceUpdate- iftruethe process will include even item pairs which are considered up to daterange- if > 0 this parameter enables paging logic while collecting items via flexible search; otherwise all matches are processed at once ( read as PK so no actual item is loaded into memory! )
-
getCompletionInfo
public SyncItemJob.CompletionInfo getCompletionInfo(SyncItemCronJob cronJob)
Deprecated.
-
performCronJob
protected CronJob.CronJobResult performCronJob(CronJob cronJob)
Deprecated.Description copied from class:JobYou have to implement this method in yourJob. Here you can execute the job. You have to return aCronJobResultthat indicates whether theJobwas successfully executed or not.- Specified by:
performCronJobin classJob- Parameters:
cronJob- the CronJob to execute- Returns:
- a
CronJobResultthat indicates whether theJobwas successfully executed or not. - See Also:
CronJob.getFinishedResult(boolean),CronJob.getAbortResult()
-
doSynchronization
protected boolean doSynchronization(SyncItemJob.SyncItemCopyContext syncItemCopyContext, SyncItemCronJob cronJob) throws AbortCronJobException
Deprecated.Executes actual synchronization.- Parameters:
syncItemCopyContext- the copy contextcronJob- the cronjob- Returns:
- true if no (ignored) errors occured, false otherwise
- Throws:
AbortCronJobException- if the cronjob has been set to be aborted during execution
-
doAbort
protected CronJob.CronJobResult doAbort(SyncItemCronJob cronJob)
Deprecated.This method is called if abort is requested by the user while still executing this job.- Parameters:
cronJob- the currently executing cronjob- Returns:
- the abort cronjob result
-
canSelectAttribute
protected boolean canSelectAttribute(AttributeDescriptor attributeDescriptor)
Deprecated.
-
getAllExportAttributeDescriptors
public java.util.Map<AttributeDescriptor,java.lang.Boolean> getAllExportAttributeDescriptors(SessionContext ctx)
Deprecated.Getter for HMC editor - we pass a map { AttributeDescriptor -> Boolean }- Specified by:
getAllExportAttributeDescriptorsin classGeneratedSyncItemJob- Returns:
- the exportAttributeDescriptors
-
setAllExportAttributeDescriptors
public void setAllExportAttributeDescriptors(SessionContext ctx, java.util.Map syncMap)
Deprecated.setter for HMC editor - we just set the 'includedInSync' attribute- Specified by:
setAllExportAttributeDescriptorsin classGeneratedSyncItemJob- Parameters:
syncMap- Map<AttributeDescriptor,Boolean>
-
configAlreadyExists
protected boolean configAlreadyExists(AttributeDescriptor attributeDescriptor)
Deprecated.
-
getConfigFor
public SyncAttributeDescriptorConfig getConfigFor(AttributeDescriptor attributeDescriptor, boolean createOnDemand)
Deprecated.Returns theSyncAttributeDescriptorConfiginstance which is responsible for all publication settings of the specified attribute descriptor.Please note that the attribute descriptor cannot be a inherited one because publication settings are generally stored for declared attributes only!
- Parameters:
attributeDescriptor- the attribute descriptor to get settings item forcreateOnDemand- iftrueand no settings item exists create one
-
getConfigFor
public SyncAttributeDescriptorConfig getConfigFor(SessionContext ctx, AttributeDescriptor attributeDescriptor, boolean createOnDemand)
Deprecated.Returns theSyncAttributeDescriptorConfiginstance which is responsible for all publication settings of the specified attribute descriptor.Please note that the attribute descriptor cannot be a inherited one because publication settings are generally stored for declared attributes only!
- Parameters:
ctx- the enclosing session contextattributeDescriptor- the attribute descriptor to get settings item forcreateOnDemand- iftrueand no settings item exists create one
-
getAttributeAndConfigPairs
protected java.util.List<java.util.List> getAttributeAndConfigPairs()
Deprecated.Returns [AttributeDescriptor,SyncAttributeDescriptorConfig] pairs for all existing declared attribute descriptors and their sync config item if it exists for this job. Otherwise the second entry is null.
-
createDefaultConfigFor
protected SyncAttributeDescriptorConfig createDefaultConfigFor(SessionContext ctx, AttributeDescriptor attributeDescriptor)
Deprecated.
-
getSyncAttributeConfigurations
public java.util.Collection<SyncAttributeDescriptorConfig> getSyncAttributeConfigurations(SessionContext ctx)
Deprecated.Returns a collection containing aSyncAttributeDescriptorConfiginstance for each declared attribute of any catalog item type.There is no need to create them explicitly since this method creates them on demand.
- Specified by:
getSyncAttributeConfigurationsin classGeneratedSyncItemJob- Returns:
- the syncAttributeConfigurations
-
setSyncAttributeConfigurations
public void setSyncAttributeConfigurations(SessionContext ctx, java.util.Collection param)
Deprecated.Description copied from class:GeneratedSyncItemJobGenerated method - Setter of theSyncItemJob.syncAttributeConfigurationsattribute.- Specified by:
setSyncAttributeConfigurationsin classGeneratedSyncItemJobparam- the syncAttributeConfigurations
-
getRootTypes
public java.util.List<ComposedType> getRootTypes(SessionContext ctx)
Deprecated.Description copied from class:GeneratedSyncItemJobGenerated method - Getter of theSyncItemJob.rootTypesattribute.- Overrides:
getRootTypesin classGeneratedSyncItemJob- Returns:
- the rootTypes
-
assureCatalogItemTypes
protected java.util.List<ComposedType> assureCatalogItemTypes(java.util.List<ComposedType> types)
Deprecated.
-
setRootTypes
public void setRootTypes(SessionContext ctx, java.util.List<ComposedType> value)
Deprecated.Overwritten to ensure that each root type is a catalog item type.- Overrides:
setRootTypesin classGeneratedSyncItemJobvalue- the rootTypes- See Also:
GeneratedSyncItemJob.setRootTypes(de.hybris.platform.jalo.SessionContext, java.util.List)
-
getEffectiveSyncLanguages
public java.util.Collection<Language> getEffectiveSyncLanguages(SessionContext ctx)
Deprecated.Calculates current effective sync languages. This is either the collection fromGeneratedSyncItemJob.getSyncLanguages()or, if empty, the intersection of source version languages and target version languages.- Specified by:
getEffectiveSyncLanguagesin classGeneratedSyncItemJob- Returns:
- the effectiveSyncLanguages
-
-