Skip to content
This repository has been archived by the owner on Dec 7, 2022. It is now read-only.

Commit

Permalink
Adds banner warning about migration runtime
Browse files Browse the repository at this point in the history
Migration 2 can take a long time. This outputs a banner to
the logs and the foreground of pulp-manage-db warning the user
that it could take a long time.

https://pulp.plan.io/issues/2060
re #2060
  • Loading branch information
Brian Bouterse committed Jul 11, 2016
1 parent 139659c commit bc005ca
Showing 1 changed file with 12 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -1,12 +1,24 @@
import logging

from pulp.server.db import connection

from pulp.plugins.migration.standard_storage_path import Migration, Plan, Unit


_logger = logging.getLogger(__name__)


def migrate(*args, **kwargs):
"""
Migrate content units to use the standard storage path introduced in pulp 2.8.
"""
msg = '* NOTE: This migration may take a long time depending on the size of your Pulp content *'
stars = '*' * len(msg)

_logger.info(stars)
_logger.info(msg)
_logger.info(stars)

migration = Migration()
migration.add(blob_plan())
migration.add(ImagePlan())
Expand Down

0 comments on commit bc005ca

Please sign in to comment.