Class MigrationUtilities

java.lang.Object
de.hybris.platform.util.migration.MigrationUtilities

public class MigrationUtilities extends Object
  • Constructor Details

    • MigrationUtilities

      public MigrationUtilities()
  • Method Details

    • registerTypecodeMapper

      public static void registerTypecodeMapper(TypecodeMapper mapper)
    • unregisterTypecodeMapper

      public static boolean unregisterTypecodeMapper(TypecodeMapper mapper)
    • unregisterPKMapper

      public static boolean unregisterPKMapper(PKMapper mapper)
    • registerPKMapper

      public static void registerPKMapper(PKMapper mapper)
    • convertOldPK

      public static PK convertOldPK(String oldPKString)
      This methods converts the old PK format (Platform <=22) to the new format. For the same input string this method ensures that always the same new PK is created. Some details about the calculation rules:

       old timestamp   -> new timestamp 1:1 (can only work if TS was not before 1995)
       old typecode    -> new typecode  1:1 (note that some typecode can be too big (new format allows only 32768, they have to be converted manually=
       old randomvalue -> last digits of randomvalue used for new millicnt (4bit) and clusterid (4bit)
       old IP          -> not used
       

      sample for old PK: P0buIyC2LQkpATPjDHiNia-1, typecode: 1, creationtime: 09.07.2007, 13:58:49

      Parameters:
      oldPKString - the old string
      Returns:
      the new PK or null, if the oldPKString was null
    • isOldPK

      public static boolean isOldPK(String oldPKString)