Examples of Pail


Examples of com.backtype.hadoop.pail.Pail

  @Override
  public void sourceConfInit(FlowProcess<JobConf> process, JobConf conf) {
    try {
      Path root = getQualifiedPath(conf);
      if (_options.attrs != null && _options.attrs.length > 0) {
        Pail pail = new Pail(_pailRoot);
        for (List<String> attr : _options.attrs) {
          String rel = Utils.join(attr, "/");
          pail.getSubPail(rel); //ensure the path exists
          Path toAdd = new Path(root, rel);
          LOG.info("Adding input path " + toAdd.toString());
          FileInputFormat.addInputPath(conf, toAdd);
        }
      } else {
View Full Code Here

Examples of com.backtype.hadoop.pail.Pail

    super.sinkConfInit(process, conf);
  }

  @Override
  public boolean commitResource(JobConf conf) throws IOException {
    Pail p = Pail.create(_pailRoot, ((PailScheme) getScheme()).getSpec(), false);
    FileSystem fs = p.getFileSystem();
    Path tmpPath = new Path(_pailRoot, "_temporary");
    if (fs.exists(tmpPath)) {
      LOG.info("Deleting _temporary directory left by Hadoop job: " + tmpPath.toString());
      fs.delete(tmpPath, true);
    }
View Full Code Here

Examples of com.backtype.hadoop.pail.Pail

    }

    @Override
    public void sourceConfInit(FlowProcess<JobConf> process,
        Tap<JobConf, RecordReader, OutputCollector> tap, JobConf conf) {
      Pail p;
      try {
        p = new Pail(_pailRoot); //make sure it exists
      } catch (IOException e) {
        throw new TapException(e);
      }
      conf.setInputFormat(p.getFormat().getInputFormatClass());
      PailFormatFactory.setPailPathLister(conf, _options.lister);
    }
View Full Code Here

Examples of com.backtype.hadoop.pail.Pail

    }

    public static TimeSliceStore create(FileSystem fs, String path, TimeSliceStoreSpec spec, boolean failOnExists) throws IOException {
        if(spec==null) spec = new TimeSliceStoreSpec();
        //TODO: if path is a pail but not the root, it's always an error
        Pail p = Pail.create(fs, path, spec.toPailSpec(), failOnExists);
        return new TimeSliceStore(fs, path);
    }
View Full Code Here

Examples of com.backtype.hadoop.pail.Pail

  @Override
  public void sourceConfInit(FlowProcess<JobConf> process, JobConf conf) {
    try {
      Path root = getQualifiedPath(conf);
      if (_options.attrs != null && _options.attrs.length > 0) {
        Pail pail = new Pail(_pailRoot, conf);
        for (List<String> attr : _options.attrs) {
          String rel = Utils.join(attr, "/");
          pail.getSubPail(rel); //ensure the path exists
          Path toAdd = new Path(root, rel);
          LOG.info("Adding input path " + toAdd.toString());
          FileInputFormat.addInputPath(conf, toAdd);
        }
      } else {
View Full Code Here

Examples of com.backtype.hadoop.pail.Pail

    super.sinkConfInit(process, conf);
  }

  @Override
  public boolean commitResource(JobConf conf) throws IOException {
    Pail p = Pail.create(_pailRoot, ((PailScheme) getScheme()).getSpec(), false);
    FileSystem fs = p.getFileSystem();
    Path tmpPath = new Path(_pailRoot, "_temporary");
    if (fs.exists(tmpPath)) {
      LOG.info("Deleting _temporary directory left by Hadoop job: " + tmpPath.toString());
      fs.delete(tmpPath, true);
    }
View Full Code Here

Examples of com.backtype.hadoop.pail.Pail

    }

    @Override
    public void sourceConfInit(FlowProcess<JobConf> process,
        Tap<JobConf, RecordReader, OutputCollector> tap, JobConf conf) {
      Pail p;
      try {
        p = new Pail(_pailRoot, conf); //make sure it exists
      } catch (IOException e) {
        throw new TapException(e);
      }
      conf.setInputFormat(p.getFormat().getInputFormatClass());
      PailFormatFactory.setPailPathLister(conf, _options.lister);
    }
View Full Code Here

Examples of com.backtype.hadoop.pail.Pail

  @Override
  public void sourceConfInit(FlowProcess<JobConf> process, JobConf conf) {
    try {
      Path root = getQualifiedPath(conf);
      if (_options.attrs != null && _options.attrs.length > 0) {
        Pail pail = new Pail(_pailRoot);
        for (List<String> attr : _options.attrs) {
          String rel = Utils.join(attr, "/");
          pail.getSubPail(rel); //ensure the path exists
          Path toAdd = new Path(root, rel);
          LOG.info("Adding input path " + toAdd.toString());
          FileInputFormat.addInputPath(conf, toAdd);
        }
      } else {
View Full Code Here

Examples of com.backtype.hadoop.pail.Pail

    super.sinkConfInit(process, conf);
  }

  @Override
  public boolean commitResource(JobConf conf) throws IOException {
    Pail p = Pail.create(_pailRoot, ((PailScheme) getScheme()).getSpec(), false);
    FileSystem fs = p.getFileSystem();
    Path tmpPath = new Path(_pailRoot, "_temporary");
    if (fs.exists(tmpPath)) {
      LOG.info("Deleting _temporary directory left by Hadoop job: " + tmpPath.toString());
      fs.delete(tmpPath, true);
    }
View Full Code Here

Examples of com.backtype.hadoop.pail.Pail

    }

    @Override
    public void sourceConfInit(FlowProcess<JobConf> process,
        Tap<JobConf, RecordReader, OutputCollector> tap, JobConf conf) {
      Pail p;
      try {
        p = new Pail(_pailRoot); //make sure it exists
      } catch (IOException e) {
        throw new TapException(e);
      }
      conf.setInputFormat(p.getFormat().getInputFormatClass());
      PailFormatFactory.setPailPathLister(conf, _options.lister);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.