クラス JobLauncherApplicationRunner

java.lang.ObjectSE
org.springframework.boot.autoconfigure.batch.JobLauncherApplicationRunner
実装されたすべてのインターフェース:
AwareInitializingBeanApplicationRunnerApplicationEventPublisherAwareOrdered

public class JobLauncherApplicationRunner extends ObjectSE implements ApplicationRunner, InitializingBean, Ordered, ApplicationEventPublisherAware
ApplicationRunner ~ launch Spring Batch ジョブ。コンテキスト内で単一のジョブが見つかった場合、それがデフォルトで実行されます。複数のジョブが見つかった場合は、jobName を指定して特定のジョブを起動します。
導入:
2.3.0
作成者:
Dave Syer, Jean-Pierre Bergamin, Mahmoud Ben Hassine, Stephane Nicoll, Akshay Dubey
  • フィールドの詳細

    • DEFAULT_ORDER

      public static final int DEFAULT_ORDER
      コマンドラインランナーのデフォルトの順序。
      関連事項:
  • コンストラクターの詳細

    • JobLauncherApplicationRunner

      public JobLauncherApplicationRunner(org.springframework.batch.core.launch.JobLauncher jobLauncher, org.springframework.batch.core.explore.JobExplorer jobExplorer, org.springframework.batch.core.repository.JobRepository jobRepository)
      新しい JobLauncherApplicationRunner を作成します。
      パラメーター:
      jobLauncher - ジョブを始める
      jobExplorer - 以前の実行についてジョブリポジトリを確認する
      jobRepository - ジョブの実行時に、指定されたパラメーターでジョブインスタンスが存在するかどうかを確認する
  • メソッドの詳細

    • afterPropertiesSet

      public void afterPropertiesSet()
      次で指定:
      インターフェース InitializingBeanafterPropertiesSet 
    • validate

      @DeprecatedSE(since="3.0.10", forRemoval=true) public void validate()
      非推奨、削除予定: この API 要素は、将来のバージョンで削除される可能性があります。
    • setOrder

      public void setOrder(int order)
    • getOrder

      public int getOrder()
      次で指定:
      インターフェース OrderedgetOrder 
    • setApplicationEventPublisher

      public void setApplicationEventPublisher(ApplicationEventPublisher publisher)
      次で指定:
      インターフェース ApplicationEventPublisherAwaresetApplicationEventPublisher 
    • setJobRegistry

      @Autowired(required=false) public void setJobRegistry(org.springframework.batch.core.configuration.JobRegistry jobRegistry)
    • setJobName

      public void setJobName(StringSE jobName)
    • setJobParametersConverter

      @Autowired(required=false) public void setJobParametersConverter(org.springframework.batch.core.converter.JobParametersConverter converter)
    • setJobs

      @Autowired(required=false) public void setJobs(CollectionSE<org.springframework.batch.core.Job> jobs)
    • run

      public void run(ApplicationArguments args) throws ExceptionSE
      インターフェースからコピーされた説明: ApplicationRunner
      Bean の実行に使用されるコールバック。
      次で指定:
      インターフェース ApplicationRunnerrun 
      パラメーター:
      args - 受信アプリケーション引数
      例外:
      ExceptionSE - エラー時
    • run

      public void run(StringSE... args) throws org.springframework.batch.core.JobExecutionException
      例外:
      org.springframework.batch.core.JobExecutionException
    • launchJobFromProperties

      protected void launchJobFromProperties(PropertiesSE properties) throws org.springframework.batch.core.JobExecutionException
      例外:
      org.springframework.batch.core.JobExecutionException
    • execute

      protected void execute(org.springframework.batch.core.Job job, org.springframework.batch.core.JobParameters jobParameters) throws org.springframework.batch.core.repository.JobExecutionAlreadyRunningException, org.springframework.batch.core.repository.JobRestartException, org.springframework.batch.core.repository.JobInstanceAlreadyCompleteException, org.springframework.batch.core.JobParametersInvalidException
      例外:
      org.springframework.batch.core.repository.JobExecutionAlreadyRunningException
      org.springframework.batch.core.repository.JobRestartException
      org.springframework.batch.core.repository.JobInstanceAlreadyCompleteException
      org.springframework.batch.core.JobParametersInvalidException