(self, source_sql_catalog_id,
                          destination_sql_catalog_id, skin_selection_dict,
                          sql_connection_id_dict)
Exchange databases and finish reindexing in the same transaction.
Exchange databases and finish reindexing in the same transaction.
Exchange databases and finish reindexing in the same transaction .
def _finishHotReindexing(self, source_sql_catalog_id,
                          destination_sql_catalog_id, skin_selection_dict,
                          sql_connection_id_dict):
    """
      Exchange databases and finish reindexing in the same transaction.
    """
    if self.archive_path is not None  and \
           getattr(self, "portal_archives", None) is not None:
      current_archive = self.portal_archives.getCurrentArchive()
    else:
      current_archive = None
    default_catalog_id = self.getDefaultSqlCatalogId()
    self._exchangeDatabases(source_sql_catalog_id=source_sql_catalog_id,
                           destination_sql_catalog_id=destination_sql_catalog_id,
                           skin_selection_dict=skin_selection_dict,
                           sql_connection_id_dict=sql_connection_id_dict)
    # cancel archive use as current catalog before archiving
    if current_archive is not None:
      current_archive.cancel()
    self._setHotReindexingState(state=HOT_REINDEXING_FINISHED_STATE)
    clearCache(cache_factory_list=('erp5_content_short',))
def _finishHotReindexing ( self , source_sql_catalog_id , destination_sql_catalog_id , skin_selection_dict , sql_connection_id_dict ) : if self . archive_path is not None and getattr ( self , "portal_archives" , None ) is not None : current_archive = self . portal_archives . getCurrentArchive ( ) else : current_archive = None default_catalog_id = self . getDefaultSqlCatalogId ( ) self . _exchangeDatabases ( source_sql_catalog_id = source_sql_catalog_id , destination_sql_catalog_id = destination_sql_catalog_id , skin_selection_dict = skin_selection_dict , sql_connection_id_dict = sql_connection_id_dict ) # cancel archive use as current catalog before archiving if current_archive is not None : current_archive . cancel ( ) self . _setHotReindexingState ( state = HOT_REINDEXING_FINISHED_STATE ) clearCache ( cache_factory_list = ( 'erp5_content_short' , ) )