
org.jberet.spi.JobTask Maven / Gradle / Ivy
The newest version!
/*
* Copyright (c) 2015 Red Hat, Inc. and/or its affiliates.
*
* This program and the accompanying materials are made
* available under the terms of the Eclipse Public License 2.0
* which is available at https://www.eclipse.org/legal/epl-2.0/
*
* SPDX-License-Identifier: EPL-2.0
*/
package org.jberet.spi;
/**
* A task to be used with the {@link JobExecutor} for leaving permits in a thread-pool open if required by the task
* being executed.
*
* @author James R. Perkins
*/
public interface JobTask extends Runnable {
/**
* The number of threads in the pool required to be remaining before this task should execute.
*
* @return the number of threads that should be available
*/
int getRequiredRemainingPermits();
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy