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

com.github.ltsopensource.example.spring.SpringJobClientTest Maven / Gradle / Ivy

The newest version!
package com.github.ltsopensource.example.spring;

import com.github.ltsopensource.example.support.BaseJobClientTest;
import com.github.ltsopensource.jobclient.JobClient;

import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

import java.io.IOException;

/**
 * @author Robert HG ([email protected]) on 8/4/15.
 */
@SuppressWarnings({"rawtypes","resource"})
public class SpringJobClientTest extends BaseJobClientTest {

    public static void main(String[] args) throws IOException {

        ApplicationContext context = new ClassPathXmlApplicationContext("/spring/lts-jobclient.xml");

        JobClient jobClient = (JobClient) context.getBean("jobClient");

        jobClient.start();

        SpringJobClientTest jobClientTest = new SpringJobClientTest();
        jobClientTest.jobClient = jobClient;
        jobClientTest.startConsole();

        System.in.read();
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy