Package org.springframework.xd.test.fixtures

Examples of org.springframework.xd.test.fixtures.HdfsJdbcJob


   *
   */
  @Test
  public void testHdfsJdbcJob() {
    String data = UUID.randomUUID().toString();
    HdfsJdbcJob job = jobs.hdfsJdbcJob();
    job.fileName(HdfsJdbcJob.DEFAULT_FILE_NAME + "-0.txt");
    // Create a stream that writes to a hdfs file. This file will be used by the job.
    stream("dataSender", sources.http() + XD_DELIMITER + sinks.hdfs()
        .directoryName(HdfsJdbcJob.DEFAULT_DIRECTORY).fileName(DEFAULT_FILE_NAME).toDSL());
    sources.http(getContainerHostForSource("dataSender")).postData(data);
    job(job.toDSL());
    waitForXD();
    //Undeploy the dataSender stream to force XD to close the file.
    undeployStream("dataSender");
    waitForXD();
    jobLaunch();
View Full Code Here

TOP

Related Classes of org.springframework.xd.test.fixtures.HdfsJdbcJob

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.