public static interface MigrationService.MigrationContext
MigrationService.Migrator
.Modifier and Type | Method and Description |
---|---|
boolean |
isShutdownRequested()
Checks if shutdown has been requested.
|
void |
reportProgress(String message,
long num,
long total)
Notifies the migration context of the current progress.
|
void |
requestShutdown()
Requests a shutdown.
|
void reportProgress(String message, long num, long total)
message
- an informative message about what is being migratednum
- the current number of things migratedtotal
- the total number of things to migrate, or -1
if unknownvoid requestShutdown()
boolean isShutdownRequested()
This should be checked periodically by the migrator, and when true
the migrator should return as soon
as possible, even if its work is not complete.
This is a "nice" version of thread interruption, which will follow a short while later, and should also be checked by the migrator.
true
if migration should be stopped as soon as possibleCopyright © 2018 Nuxeo. All rights reserved.