All Downloads are FREE. Search and download functionalities are using the official Maven repository.

sirius.kernel.Killable Maven / Gradle / Ivy

Go to download

Provides common core classes and the microkernel powering all Sirius applications

There is a newer version: 12.9.1
Show newest version
/*
 * Made with all the love in the world
 * by scireum in Remshalden, Germany
 *
 * Copyright by scireum GmbH
 * http://www.scireum.de - [email protected]
 */

package sirius.kernel;

import sirius.kernel.di.std.Priorized;

/**
 * Classes implementing this interface get notified once the framework is being shut down.
 * 

* The framework lifecycle is split into three phases: *

    *
  • {@link Startable}: Each startable component is invoked during startup.
  • *
  • {@link Stoppable}: Each stoppable component is invoked during framework shutdown.
  • *
  • {@link Killable}: The the shutdown process has to wait for a task to finish, this can be used to block until a * task is completed.
  • *
*/ public interface Killable extends Priorized { @Override default int getPriority() { return DEFAULT_PRIORITY; } /** * Called after {@link Stoppable#stopped()} has been called to wait until all tasks are fully finished. *

* This method may block for a certain amount of time to permit the subsystem to shut down properly. However, * it should not block infinitely... */ void awaitTermination(); }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy