atg.commerce.catalog.custom
Class CatalogMigration

java.lang.Object
  extended by atg.nucleus.logging.VariableArgumentApplicationLoggingImpl
      extended by atg.nucleus.GenericService
          extended by atg.commerce.catalog.custom.CatalogMigration
All Implemented Interfaces:
atg.naming.AbsoluteNameable, NameContextBindingListener, NameContextElement, atg.naming.NameContextParentable, NameResolver, AdminableService, atg.nucleus.Configured, ApplicationLogging, atg.nucleus.logging.ApplicationLoggingSender, atg.nucleus.logging.TraceApplicationLogging, VariableArgumentApplicationLogging, ComponentNameResolver, Service, ServiceListener, java.util.EventListener

public class CatalogMigration
extends GenericService

This class is used to migrate the old product catalog data to the custom Catalog.

One should run the runMigration method to initiate the whole migration process. One can customize the property file to choose which properties from the original catalog to migrate.

To run the whole migration, one should put the catalogMigration.xml into the definitionFiles property of the ProductCatalog.properties file. For example: ProductCatalog.properties

 definitionFiles=\
       /atg/commerce/catalog/custom/customCatalog.xml,\
       /atg/commerce/catalog/custom/catalogMigration.xml,\
       /atg/commerce/pricing/pricingModels.xml
 

 Also one should uncomment the following in atg/devtools/DCS/initsolid
   initSolid atg/projects/Commerce/sql/db_components/solid/product_catalog_ddl.sql
   initSolid atg/projects/Commerce/sql/db_components/solid/migrate_catalog_ddl.sql
 Uncomment the following in atg/devtools/DCS/dropsolid 
   initSolid atg/projects/Commerce/sql/db_components/solid/drop_product_catalog_ddl.sql
   initSolid atg/projects/Commerce/sql/db_components/solid/drop_migrate_catalog_ddl.sql
 


Field Summary
static java.lang.String CATALOG_ITEM_TYPE
           
static java.lang.String CATEGORY_ITEM_TYPE
           
static java.lang.String CATEGORY_MIGRATION_ITEM_TYPE
           
static java.lang.String CATEGORYINFO_ITEM_TYPE
           
static java.lang.String CLASS_VERSION
           
static java.lang.String PRODUCT_ITEM_TYPE
           
static java.lang.String PRODUCT_MIGRATION_ITEM_TYPE
           
static java.lang.String PRODUCTINFO_ITEM_TYPE
           
static java.lang.String SKU_ITEM_TYPE
           
static java.lang.String SKU_MIGRATION_ITEM_TYPE
           
static java.lang.String SKUINFO_ITEM_TYPE
           
static java.lang.String STATUS_CATALOG_MIGRATE
           
static java.lang.String STATUS_CATEGORY_MIGRATE
           
static java.lang.String STATUS_MIGRATE_FINISH
           
static java.lang.String STATUS_OTHER
           
static java.lang.String STATUS_PRODUCT_MIGRATE
           
static java.lang.String STATUS_SKU_MIGRATE
           
 
Fields inherited from class atg.nucleus.GenericService
SERVICE_INFO_KEY
 
Fields inherited from interface atg.nucleus.logging.TraceApplicationLogging
DEFAULT_LOG_TRACE_STATUS
 
Fields inherited from interface atg.nucleus.logging.ApplicationLogging
DEFAULT_LOG_DEBUG_STATUS, DEFAULT_LOG_ERROR_STATUS, DEFAULT_LOG_INFO_STATUS, DEFAULT_LOG_WARNING_STATUS
 
Constructor Summary
CatalogMigration()
           
 
Method Summary
protected  boolean checkValidCategoryProperty(java.lang.String pPropertyName)
          This method checks whether a particular category property the user want to migrate is a valid property that is allowed to migrate.
protected  boolean checkValidProductProperty(java.lang.String pPropertyName)
          This method checks whether a particular product property the user want to migrate is a valid property that is allowed to migrate.
protected  boolean checkValidSkuProperty(java.lang.String pPropertyName)
          This method checks whether a particular sku property the user want to migrate is a valid property that is allowed to migrate.
protected  MutableRepositoryItem createCatalog()
          This method creates a catalog repository item and sets its displayName property.
protected  MutableRepositoryItem createCategoryInfo()
          This method creates a categoryInfo repository item
protected  MutableRepositoryItem createProductInfo()
          This method creates a productInfo repository item.
protected  MutableRepositoryItem createSkuInfo()
          This method creates a skuInfo repository item.
 java.lang.String getCatalogCreationDatePropertyName()
          The property catalogCreationDatePropertyName
 java.lang.String getCatalogDisplayName()
          The property catalogDisplayName
 java.lang.String getCatalogDisplayNamePropertyName()
          The property catalogDisplayNamePropertyName
 java.lang.String getCatalogItemType()
          The name of the item-descriptor used for a catalog
 java.lang.String getCatalogLastModifiedDatePropertyName()
          The property catalogLastModifiedDatePropertyName
 java.lang.String getCatalogPropertyName()
          The Property catalogPropertyName
 java.lang.String getCatalogViewName()
          The Property catalogViewName
 java.lang.String getCategoryInfoItemType()
          The name of the item-descriptor used for a categoryInfo
 java.lang.String getCategoryItemType()
          The name of the item-descriptor used for a category
 java.lang.String[] getCategoryMigratableProperties()
          The Property categoryMigratableProperties
 java.lang.String getCategoryMigrationItemType()
          The name of the item-descriptor used for a categoryMigration item
protected  java.lang.String[] getCategoryMigrationProperties()
          This method retrieves all the properties in the categoryMigration item-descriptor.
 java.lang.String getCategoryViewName()
          The Property categoryViewName
 java.lang.String getCatInfosPropertyName()
          The Property catInfosPropertyName
 java.lang.String getFixedRelatedCatsPropertyName()
          The Property fixedRelatedCatsPropertyName
 java.lang.String getFixedRelatedPrdsPropertyName()
          The Property fixedRelatedPrdsPropertyName
 java.lang.String getIdPropertyName()
          The name of the property in items with an id property.
 int getMaxItemsPerTransaction()
          The property maxItemsPerTransaction
 java.lang.String getMigrateIndexPropertyName()
          The property migrateIndexPropertyName
 java.lang.String getMigrateStatusPropertyName()
          The property migrateStatusPropertyName
 MutableRepository getMigrationRepository()
           
 java.lang.String getParentCategoryPropertyName()
          The Property parentCategoryPropertyName
 java.lang.String getPrdInfosPropertyName()
          The Property prdInfosPropertyName
 java.lang.String getProductInfoItemType()
          The name of the item-descriptor used for a productInfo
 java.lang.String getProductItemType()
          The name of the item-descriptor used for a product
 java.lang.String[] getProductMigratableProperties()
          The Property productMigratableProperties
 java.lang.String getProductMigrationItemType()
          The name of the item-descriptor used for a productMigration item
protected  java.lang.String[] getProductMigrationProperties()
          This method retrieves all the properties in the productMigration item-descriptor.
 java.lang.String getProductViewName()
          The Property productViewName
 java.lang.String getRelatedCatGroupPropertyName()
          The Property relatedCatGroupPropertyName
 java.lang.String getRelatedPrdGroupPropertyName()
          The Property relatedPrdGroupPropertyName
 java.lang.String getReplacementPrdsPropertyName()
          The Property replacementPrdsPropertyName
 java.lang.String getRootCatsPropertyName()
          The Property rootCatsPropertyName
 java.lang.String getRootPropertyName()
          The Property rootPropertyName
 java.lang.String getSkuInfoItemType()
          The name of the item-descriptor used for a skuInfo
 java.lang.String getSkuInfosPropertyName()
          The Property skuInfosPropertyName
 java.lang.String getSkuItemType()
          The name of the item-descriptor used for a sku
 java.lang.String[] getSkuMigratableProperties()
          The Property skuMigratableProperties
 java.lang.String getSkuMigrationItemType()
          The name of the item-descriptor used for SkuMigration
protected  java.lang.String[] getSkuMigrationProperties()
          This method retrieves all the properties in the skuMigration item-descriptor.
 java.lang.String getSkuViewName()
          The Property skuViewName
 javax.transaction.TransactionManager getTransactionManager()
          The beginning and ending of transactions are handled by the transaction manager.
protected  void migrateCategoryInfoRelatedProperty(java.lang.String pPropertyName, RepositoryItem pCategory, MutableRepositoryItem pCategoryInfo)
          This method moves a particular category property from the category repository item to the categoryInfo repository item.
protected  void migrateCategoryProperty(java.lang.String pPropertyName, RepositoryItem pFromCategory, MutableRepositoryItem pTargetCategory, MutableRepositoryItem pCatalog, MutableRepositoryItem pCategoryInfo)
          This method sets the rootCategory property of the Catalog, the Catalogs and categoryInfos property of the category.
protected  void migrateProductInfoRelatedProperty(java.lang.String pPropertyName, RepositoryItem pProduct, MutableRepositoryItem pProductInfo)
          This method moves a particular product property from the product repository item to the productInfo repository item.
protected  void migrateProductProperty(java.lang.String pPropertyName, RepositoryItem pFromProduct, MutableRepositoryItem pTargetProduct, MutableRepositoryItem pCatalog, MutableRepositoryItem pProductInfo)
          This method sets the Catalogs and productInfos property of the product.
protected  void migrateSkuInfoRelatedProperty(java.lang.String pPropertyName, RepositoryItem pSku, MutableRepositoryItem pSkuInfo)
          This method moves a particular sku property from the sku repository item to the skuInfo repository item.
protected  void migrateSkuProperty(java.lang.String pPropertyName, RepositoryItem pFromSku, MutableRepositoryItem pTargetSku, MutableRepositoryItem pCatalog, MutableRepositoryItem pSkuInfo)
          This method sets the Catalogs and skuInfos property of the sku.
protected  void processCategory(RepositoryItem pFromCategory, MutableRepositoryItem pTargetCategory, MutableRepositoryItem pCatalog)
          This method processes each category for migration.
protected  void processProduct(RepositoryItem pFromProduct, MutableRepositoryItem pTargetProduct, MutableRepositoryItem pCatalog)
          This method processes each product for migration.
protected  void processSku(RepositoryItem pFromSku, MutableRepositoryItem pTargetSku, MutableRepositoryItem pCatalog)
          This method processes each sku for migration.
 void runMigration()
          This method runs the migration process for the entire repository.
 void setCatalogCreationDatePropertyName(java.lang.String pCatalogCreationDatePropertyName)
           
 void setCatalogDisplayName(java.lang.String pCatalogDisplayName)
           
 void setCatalogDisplayNamePropertyName(java.lang.String pCatalogDisplayNamePropertyName)
           
 void setCatalogItemType(java.lang.String pCatalogItemType)
           
 void setCatalogLastModifiedDatePropertyName(java.lang.String pCatalogLastModifiedDatePropertyName)
           
 void setCatalogPropertyName(java.lang.String pCatalogPropertyName)
           
 void setCatalogViewName(java.lang.String pCatalogViewName)
           
 void setCategoryInfoItemType(java.lang.String pCategoryInfoItemType)
           
 void setCategoryItemType(java.lang.String pCategoryItemType)
           
 void setCategoryMigratableProperties(java.lang.String[] pCategoryMigratableProperties)
           
 void setCategoryMigrationItemType(java.lang.String pCategoryMigrationItemType)
           
 void setCategoryViewName(java.lang.String pCategoryViewName)
           
 void setCatInfosPropertyName(java.lang.String pCatInfosPropertyName)
           
 void setFixedRelatedCatsPropertyName(java.lang.String pFixedRelatedCatsPropertyName)
           
 void setFixedRelatedPrdsPropertyName(java.lang.String pFixedRelatedPrdsPropertyName)
           
 void setIdPropertyName(java.lang.String pIdPropertyName)
           
 void setMaxItemsPerTransaction(int pMaxItemsPerTransaction)
           
 void setMigrateIndexPropertyName(java.lang.String pMigrateIndexPropertyName)
           
 void setMigrateStatusPropertyName(java.lang.String pMigrateStatusPropertyName)
           
 void setMigrationRepository(MutableRepository pMigrationRepository)
          The product catalog repository that contains the catalog to be migrated
 void setParentCategoryPropertyName(java.lang.String pParentCategoryPropertyName)
           
 void setPrdInfosPropertyName(java.lang.String pPrdInfosPropertyName)
           
 void setProductInfoItemType(java.lang.String pProductInfoItemType)
           
 void setProductItemType(java.lang.String pProductItemType)
           
 void setProductMigratableProperties(java.lang.String[] pProductMigratableProperties)
           
 void setProductMigrationItemType(java.lang.String pProductMigrationItemType)
           
 void setProductViewName(java.lang.String pProductViewName)
           
 void setRelatedCatGroupPropertyName(java.lang.String pRelatedCatGroupPropertyName)
           
 void setRelatedPrdGroupPropertyName(java.lang.String pRelatedPrdGroupPropertyName)
           
 void setReplacementPrdsPropertyName(java.lang.String pReplacementPrdsPropertyName)
           
 void setRootCatsPropertyName(java.lang.String pRootCatsPropertyName)
           
 void setRootPropertyName(java.lang.String pRootPropertyName)
           
 void setSkuInfoItemType(java.lang.String pSkuInfoItemType)
           
 void setSkuInfosPropertyName(java.lang.String pSkuInfosPropertyName)
           
 void setSkuItemType(java.lang.String pSkuItemType)
           
 void setSkuMigratableProperties(java.lang.String[] pSkuMigratableProperties)
           
 void setSkuMigrationItemType(java.lang.String pSkuMigrationItemType)
           
 void setSkuViewName(java.lang.String pSkuViewName)
           
 void setTransactionManager(javax.transaction.TransactionManager pTransactionManager)
           
 
Methods inherited from class atg.nucleus.GenericService
addLogListener, createAdminServlet, doStartService, doStopService, getAbsoluteName, getAdminServlet, getAdminServletOutputStreamEncoding, getLoggingForVlogging, getLogListenerCount, getLogListeners, getName, getNameContext, getNucleus, getRoot, getServiceConfiguration, getServiceInfo, isAdminServletUseServletOutputStream, isLoggingDebug, isLoggingError, isLoggingInfo, isLoggingTrace, isLoggingWarning, isRunning, logDebug, logDebug, logDebug, logError, logError, logError, logInfo, logInfo, logInfo, logTrace, logTrace, logTrace, logWarning, logWarning, logWarning, nameContextElementBound, nameContextElementUnbound, removeLogListener, reResolveThis, resolveName, resolveName, resolveName, resolveName, sendLogEvent, setAdminServletOutputStreamEncoding, setAdminServletUseServletOutputStream, setLoggingDebug, setLoggingError, setLoggingInfo, setLoggingTrace, setLoggingWarning, setNucleus, setServiceInfo, startService, stopService
 
Methods inherited from class atg.nucleus.logging.VariableArgumentApplicationLoggingImpl
vlogDebug, vlogDebug, vlogDebug, vlogDebug, vlogDebugTrace, vlogError, vlogError, vlogError, vlogError, vlogInfo, vlogInfo, vlogInfo, vlogInfo, vlogTrace, vlogTrace, vlogTrace, vlogTrace, vlogWarning, vlogWarning, vlogWarning, vlogWarning
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CLASS_VERSION

public static final java.lang.String CLASS_VERSION
See Also:
Constant Field Values

CATALOG_ITEM_TYPE

public static java.lang.String CATALOG_ITEM_TYPE

CATEGORY_ITEM_TYPE

public static java.lang.String CATEGORY_ITEM_TYPE

PRODUCT_ITEM_TYPE

public static java.lang.String PRODUCT_ITEM_TYPE

SKU_ITEM_TYPE

public static java.lang.String SKU_ITEM_TYPE

CATEGORYINFO_ITEM_TYPE

public static java.lang.String CATEGORYINFO_ITEM_TYPE

PRODUCTINFO_ITEM_TYPE

public static java.lang.String PRODUCTINFO_ITEM_TYPE

SKUINFO_ITEM_TYPE

public static java.lang.String SKUINFO_ITEM_TYPE

CATEGORY_MIGRATION_ITEM_TYPE

public static java.lang.String CATEGORY_MIGRATION_ITEM_TYPE

PRODUCT_MIGRATION_ITEM_TYPE

public static java.lang.String PRODUCT_MIGRATION_ITEM_TYPE

SKU_MIGRATION_ITEM_TYPE

public static java.lang.String SKU_MIGRATION_ITEM_TYPE

STATUS_OTHER

public static java.lang.String STATUS_OTHER

STATUS_CATALOG_MIGRATE

public static java.lang.String STATUS_CATALOG_MIGRATE

STATUS_CATEGORY_MIGRATE

public static java.lang.String STATUS_CATEGORY_MIGRATE

STATUS_PRODUCT_MIGRATE

public static java.lang.String STATUS_PRODUCT_MIGRATE

STATUS_SKU_MIGRATE

public static java.lang.String STATUS_SKU_MIGRATE

STATUS_MIGRATE_FINISH

public static java.lang.String STATUS_MIGRATE_FINISH
Constructor Detail

CatalogMigration

public CatalogMigration()
Method Detail

setTransactionManager

public void setTransactionManager(javax.transaction.TransactionManager pTransactionManager)

getTransactionManager

public javax.transaction.TransactionManager getTransactionManager()
The beginning and ending of transactions are handled by the transaction manager.


getMigrationRepository

public MutableRepository getMigrationRepository()

setMigrationRepository

public void setMigrationRepository(MutableRepository pMigrationRepository)
The product catalog repository that contains the catalog to be migrated


setCatalogItemType

public void setCatalogItemType(java.lang.String pCatalogItemType)

getCatalogItemType

public java.lang.String getCatalogItemType()
The name of the item-descriptor used for a catalog


setCategoryItemType

public void setCategoryItemType(java.lang.String pCategoryItemType)

getCategoryItemType

public java.lang.String getCategoryItemType()
The name of the item-descriptor used for a category


setProductItemType

public void setProductItemType(java.lang.String pProductItemType)

getProductItemType

public java.lang.String getProductItemType()
The name of the item-descriptor used for a product


setSkuItemType

public void setSkuItemType(java.lang.String pSkuItemType)

getSkuItemType

public java.lang.String getSkuItemType()
The name of the item-descriptor used for a sku


setCategoryInfoItemType

public void setCategoryInfoItemType(java.lang.String pCategoryInfoItemType)

getCategoryInfoItemType

public java.lang.String getCategoryInfoItemType()
The name of the item-descriptor used for a categoryInfo


setProductInfoItemType

public void setProductInfoItemType(java.lang.String pProductInfoItemType)

getProductInfoItemType

public java.lang.String getProductInfoItemType()
The name of the item-descriptor used for a productInfo


setSkuInfoItemType

public void setSkuInfoItemType(java.lang.String pSkuInfoItemType)

getSkuInfoItemType

public java.lang.String getSkuInfoItemType()
The name of the item-descriptor used for a skuInfo


setCategoryMigrationItemType

public void setCategoryMigrationItemType(java.lang.String pCategoryMigrationItemType)

getCategoryMigrationItemType

public java.lang.String getCategoryMigrationItemType()
The name of the item-descriptor used for a categoryMigration item


setProductMigrationItemType

public void setProductMigrationItemType(java.lang.String pProductMigrationItemType)

getProductMigrationItemType

public java.lang.String getProductMigrationItemType()
The name of the item-descriptor used for a productMigration item


setSkuMigrationItemType

public void setSkuMigrationItemType(java.lang.String pSkuMigrationItemType)

getSkuMigrationItemType

public java.lang.String getSkuMigrationItemType()
The name of the item-descriptor used for SkuMigration


setParentCategoryPropertyName

public void setParentCategoryPropertyName(java.lang.String pParentCategoryPropertyName)

getParentCategoryPropertyName

public java.lang.String getParentCategoryPropertyName()
The Property parentCategoryPropertyName


setRootPropertyName

public void setRootPropertyName(java.lang.String pRootPropertyName)

getRootPropertyName

public java.lang.String getRootPropertyName()
The Property rootPropertyName


setRelatedCatGroupPropertyName

public void setRelatedCatGroupPropertyName(java.lang.String pRelatedCatGroupPropertyName)

getRelatedCatGroupPropertyName

public java.lang.String getRelatedCatGroupPropertyName()
The Property relatedCatGroupPropertyName


setRelatedPrdGroupPropertyName

public void setRelatedPrdGroupPropertyName(java.lang.String pRelatedPrdGroupPropertyName)

getRelatedPrdGroupPropertyName

public java.lang.String getRelatedPrdGroupPropertyName()
The Property relatedPrdGroupPropertyName


setRootCatsPropertyName

public void setRootCatsPropertyName(java.lang.String pRootCatsPropertyName)

getRootCatsPropertyName

public java.lang.String getRootCatsPropertyName()
The Property rootCatsPropertyName


setFixedRelatedCatsPropertyName

public void setFixedRelatedCatsPropertyName(java.lang.String pFixedRelatedCatsPropertyName)

getFixedRelatedCatsPropertyName

public java.lang.String getFixedRelatedCatsPropertyName()
The Property fixedRelatedCatsPropertyName


setFixedRelatedPrdsPropertyName

public void setFixedRelatedPrdsPropertyName(java.lang.String pFixedRelatedPrdsPropertyName)

getFixedRelatedPrdsPropertyName

public java.lang.String getFixedRelatedPrdsPropertyName()
The Property fixedRelatedPrdsPropertyName


setCatInfosPropertyName

public void setCatInfosPropertyName(java.lang.String pCatInfosPropertyName)

getCatInfosPropertyName

public java.lang.String getCatInfosPropertyName()
The Property catInfosPropertyName


setPrdInfosPropertyName

public void setPrdInfosPropertyName(java.lang.String pPrdInfosPropertyName)

getPrdInfosPropertyName

public java.lang.String getPrdInfosPropertyName()
The Property prdInfosPropertyName


setSkuInfosPropertyName

public void setSkuInfosPropertyName(java.lang.String pSkuInfosPropertyName)

getSkuInfosPropertyName

public java.lang.String getSkuInfosPropertyName()
The Property skuInfosPropertyName


setCatalogPropertyName

public void setCatalogPropertyName(java.lang.String pCatalogPropertyName)

getCatalogPropertyName

public java.lang.String getCatalogPropertyName()
The Property catalogPropertyName


setReplacementPrdsPropertyName

public void setReplacementPrdsPropertyName(java.lang.String pReplacementPrdsPropertyName)

getReplacementPrdsPropertyName

public java.lang.String getReplacementPrdsPropertyName()
The Property replacementPrdsPropertyName


setCatalogViewName

public void setCatalogViewName(java.lang.String pCatalogViewName)

getCatalogViewName

public java.lang.String getCatalogViewName()
The Property catalogViewName


setCategoryViewName

public void setCategoryViewName(java.lang.String pCategoryViewName)

getCategoryViewName

public java.lang.String getCategoryViewName()
The Property categoryViewName


setProductViewName

public void setProductViewName(java.lang.String pProductViewName)

getProductViewName

public java.lang.String getProductViewName()
The Property productViewName


setSkuViewName

public void setSkuViewName(java.lang.String pSkuViewName)

getSkuViewName

public java.lang.String getSkuViewName()
The Property skuViewName


setCategoryMigratableProperties

public void setCategoryMigratableProperties(java.lang.String[] pCategoryMigratableProperties)

getCategoryMigratableProperties

public java.lang.String[] getCategoryMigratableProperties()
The Property categoryMigratableProperties


setProductMigratableProperties

public void setProductMigratableProperties(java.lang.String[] pProductMigratableProperties)

getProductMigratableProperties

public java.lang.String[] getProductMigratableProperties()
The Property productMigratableProperties


setSkuMigratableProperties

public void setSkuMigratableProperties(java.lang.String[] pSkuMigratableProperties)

getSkuMigratableProperties

public java.lang.String[] getSkuMigratableProperties()
The Property skuMigratableProperties


setCatalogDisplayName

public void setCatalogDisplayName(java.lang.String pCatalogDisplayName)

getCatalogDisplayName

public java.lang.String getCatalogDisplayName()
The property catalogDisplayName


setCatalogDisplayNamePropertyName

public void setCatalogDisplayNamePropertyName(java.lang.String pCatalogDisplayNamePropertyName)

getCatalogDisplayNamePropertyName

public java.lang.String getCatalogDisplayNamePropertyName()
The property catalogDisplayNamePropertyName


setCatalogCreationDatePropertyName

public void setCatalogCreationDatePropertyName(java.lang.String pCatalogCreationDatePropertyName)

getCatalogCreationDatePropertyName

public java.lang.String getCatalogCreationDatePropertyName()
The property catalogCreationDatePropertyName


setCatalogLastModifiedDatePropertyName

public void setCatalogLastModifiedDatePropertyName(java.lang.String pCatalogLastModifiedDatePropertyName)

getCatalogLastModifiedDatePropertyName

public java.lang.String getCatalogLastModifiedDatePropertyName()
The property catalogLastModifiedDatePropertyName


setIdPropertyName

public void setIdPropertyName(java.lang.String pIdPropertyName)

getIdPropertyName

public java.lang.String getIdPropertyName()
The name of the property in items with an id property.


setMaxItemsPerTransaction

public void setMaxItemsPerTransaction(int pMaxItemsPerTransaction)

getMaxItemsPerTransaction

public int getMaxItemsPerTransaction()
The property maxItemsPerTransaction


setMigrateStatusPropertyName

public void setMigrateStatusPropertyName(java.lang.String pMigrateStatusPropertyName)

getMigrateStatusPropertyName

public java.lang.String getMigrateStatusPropertyName()
The property migrateStatusPropertyName


setMigrateIndexPropertyName

public void setMigrateIndexPropertyName(java.lang.String pMigrateIndexPropertyName)

getMigrateIndexPropertyName

public java.lang.String getMigrateIndexPropertyName()
The property migrateIndexPropertyName


createCatalog

protected MutableRepositoryItem createCatalog()
                                       throws MigrationException
This method creates a catalog repository item and sets its displayName property.

Throws:
MigrationException

createCategoryInfo

protected MutableRepositoryItem createCategoryInfo()
                                            throws MigrationException
This method creates a categoryInfo repository item

Throws:
MigrationException

createProductInfo

protected MutableRepositoryItem createProductInfo()
                                           throws MigrationException
This method creates a productInfo repository item.

Throws:
MigrationException

createSkuInfo

protected MutableRepositoryItem createSkuInfo()
                                       throws MigrationException
This method creates a skuInfo repository item.

Throws:
MigrationException

getCategoryMigrationProperties

protected java.lang.String[] getCategoryMigrationProperties()
                                                     throws MigrationException
This method retrieves all the properties in the categoryMigration item-descriptor. Those properties are the possible properties that will be moved from category to categoryInfo.

Throws:
MigrationException

getProductMigrationProperties

protected java.lang.String[] getProductMigrationProperties()
                                                    throws MigrationException
This method retrieves all the properties in the productMigration item-descriptor. Those properties are the possible properties that will be moved from product to productInfo.

Throws:
MigrationException

getSkuMigrationProperties

protected java.lang.String[] getSkuMigrationProperties()
                                                throws MigrationException
This method retrieves all the properties in the skuMigration item-descriptor. Those properties are the possible properties that will be moved from sku to skuInfo.

Throws:
MigrationException

checkValidCategoryProperty

protected boolean checkValidCategoryProperty(java.lang.String pPropertyName)
                                      throws MigrationException
This method checks whether a particular category property the user want to migrate is a valid property that is allowed to migrate.

Throws:
MigrationException

checkValidProductProperty

protected boolean checkValidProductProperty(java.lang.String pPropertyName)
                                     throws MigrationException
This method checks whether a particular product property the user want to migrate is a valid property that is allowed to migrate.

Throws:
MigrationException

checkValidSkuProperty

protected boolean checkValidSkuProperty(java.lang.String pPropertyName)
                                 throws MigrationException
This method checks whether a particular sku property the user want to migrate is a valid property that is allowed to migrate.

Throws:
MigrationException

migrateCategoryInfoRelatedProperty

protected void migrateCategoryInfoRelatedProperty(java.lang.String pPropertyName,
                                                  RepositoryItem pCategory,
                                                  MutableRepositoryItem pCategoryInfo)
                                           throws MigrationException
This method moves a particular category property from the category repository item to the categoryInfo repository item.

Throws:
MigrationException

migrateCategoryProperty

protected void migrateCategoryProperty(java.lang.String pPropertyName,
                                       RepositoryItem pFromCategory,
                                       MutableRepositoryItem pTargetCategory,
                                       MutableRepositoryItem pCatalog,
                                       MutableRepositoryItem pCategoryInfo)
                                throws MigrationException
This method sets the rootCategory property of the Catalog, the Catalogs and categoryInfos property of the category.

Throws:
MigrationException

processCategory

protected void processCategory(RepositoryItem pFromCategory,
                               MutableRepositoryItem pTargetCategory,
                               MutableRepositoryItem pCatalog)
                        throws MigrationException
This method processes each category for migration.

Throws:
MigrationException

migrateProductInfoRelatedProperty

protected void migrateProductInfoRelatedProperty(java.lang.String pPropertyName,
                                                 RepositoryItem pProduct,
                                                 MutableRepositoryItem pProductInfo)
                                          throws MigrationException
This method moves a particular product property from the product repository item to the productInfo repository item.

Throws:
MigrationException

migrateProductProperty

protected void migrateProductProperty(java.lang.String pPropertyName,
                                      RepositoryItem pFromProduct,
                                      MutableRepositoryItem pTargetProduct,
                                      MutableRepositoryItem pCatalog,
                                      MutableRepositoryItem pProductInfo)
                               throws MigrationException
This method sets the Catalogs and productInfos property of the product.

Throws:
MigrationException

processProduct

protected void processProduct(RepositoryItem pFromProduct,
                              MutableRepositoryItem pTargetProduct,
                              MutableRepositoryItem pCatalog)
                       throws MigrationException
This method processes each product for migration.

Throws:
MigrationException

migrateSkuInfoRelatedProperty

protected void migrateSkuInfoRelatedProperty(java.lang.String pPropertyName,
                                             RepositoryItem pSku,
                                             MutableRepositoryItem pSkuInfo)
                                      throws MigrationException
This method moves a particular sku property from the sku repository item to the skuInfo repository item.

Throws:
MigrationException

migrateSkuProperty

protected void migrateSkuProperty(java.lang.String pPropertyName,
                                  RepositoryItem pFromSku,
                                  MutableRepositoryItem pTargetSku,
                                  MutableRepositoryItem pCatalog,
                                  MutableRepositoryItem pSkuInfo)
                           throws MigrationException
This method sets the Catalogs and skuInfos property of the sku.

Throws:
MigrationException

processSku

protected void processSku(RepositoryItem pFromSku,
                          MutableRepositoryItem pTargetSku,
                          MutableRepositoryItem pCatalog)
                   throws MigrationException
This method processes each sku for migration.

Throws:
MigrationException

runMigration

public void runMigration()
                  throws MigrationException
This method runs the migration process for the entire repository.

Throws:
MigrationException