Package cascading.tap

Examples of cascading.tap.TapException


      {
      return FileSystem.getLocal( conf );
      }
    catch( IOException exception )
      {
      throw new TapException( "unable to get handle to get local filesystem", exception );
      }
    }
View Full Code Here


      {
      taps = makeTaps( conf );
      }
    catch( IOException exception )
      {
      throw new TapException( "unable to resolve taps for globing path: " + pathPattern );
      }

    return taps;
    }
View Full Code Here

      statusList = fileSystem.globStatus( path );
    else
      statusList = fileSystem.globStatus( path, pathFilter );

    if( statusList == null || statusList.length == 0 )
      throw new TapException( "unable to find paths matching path pattern: " + pathPattern );

    List<Hfs> notEmpty = new ArrayList<Hfs>();

    for( int i = 0; i < statusList.length; i++ )
      {
      // remove empty files. some hadoop versions return non-zero for dirs
      // so this jives with the expectations set in the above javadoc
      if( statusList[ i ].isDir() || statusList[ i ].getLen() != 0 )
        notEmpty.add( new Hfs( getScheme(), statusList[ i ].getPath().toString() ) );
      }

    if( notEmpty.isEmpty() )
      throw new TapException( "all paths matching path pattern are zero length and not directories: " + pathPattern );

    return notEmpty.toArray( new Hfs[ notEmpty.size() ] );
    }
View Full Code Here

      ( (Hfs) getParent() ).applySourceConfInitIdentifiers( flowProcess, conf, childPartitions );
      }
    catch( IOException exception )
      {
      throw new TapException( "unable to retrieve child partitions", exception );
      }
    }
View Full Code Here

        openedCollectors++;
        flowProcess.increment( Counters.Paths_Opened, 1 );
        }
      catch( IOException exception )
        {
        throw new TapException( "unable to open partition path: " + path, exception );
        }

      if( collectors.size() > openWritesThreshold )
        purgeCollectors();
View Full Code Here

        if( failProperty != null )
          failOnError = Boolean.parseBoolean( failProperty.toString() );

        if( failOnError )
          throw new TapException( exception );
        }
      }
View Full Code Here

      {
      partition.toTuple( childIdentifier.substring( parentIdentifier.length() + 1 ), partitionEntry );
      }
    catch( Exception exception )
      {
      throw new TapException( "unable to parse partition given parent: " + parentIdentifier + " and child: " + childIdentifier );
      }

    base = TupleViews.createOverride( sourceFields, partitionEntry.getFields() );

    TupleViews.reset( base, Tuple.size( sourceFields.size() ), partitionEntry.getTuple() );
View Full Code Here

    private URI getURI() {
        try {
            return new URI(SCHEME, "//" + _accessKeyId + "/" + _baseDomainName, null);
        } catch (URISyntaxException exception) {
            throw new TapException("unable to create uri", exception);
        }
    }
View Full Code Here

    try {
      LOG.info("closing tap collector for: {}", tap);
      writer.close(reporter);
    } catch (IOException exception) {
      LOG.warn("exception closing: {}", exception);
      throw new TapException("exception closing HBaseTapCollector", exception);
    } finally {
      super.close();
    }
  }
View Full Code Here

      return uriScheme;
      }
    catch( URISyntaxException exception )
      {
      throw new TapException( "could not determine scheme from path: " + stringPath, exception );
      }
    }
View Full Code Here

TOP

Related Classes of cascading.tap.TapException

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.