salesforce-lib/src/main/java/com/streamsets/pipeline/stage/destination/waveanalytics/WaveAnalyticsTarget.java
@Override
  public void write(Batch batch) throws StageException {
    if (batch.getRecords().hasNext()) {
      if (datasetID == null) {
        LOG.info("Opening dataset");
        try {
          openDataset();
        } catch (ConnectionException ce) {
          throw new StageException(Errors.WAVE_01, ce);
        }
      }

      LOG.info("Writing batch to dataset");
      writeToDataset(batch);
      try {
        commitDataset();
      } catch (ConnectionException | IOException e) {
        throw new StageException(Errors.WAVE_01, e);
      }
    }
  }
@Override
  public void write(Batch batch) throws StageException {
    if (batch.getRecords().hasNext()) {
      if (datasetID == null) {
        LOG.info("Opening dataset");
        try {
          openDataset();
        } catch (ConnectionException ce) {
          throw new StageException(Errors.WAVE_01, ce);
        }
      }

      LOG.info("Writing batch to dataset");
      writeToDataset(batch);
      try {
        commitDataset();
      } catch (ConnectionException | IOException e) {
        throw new StageException(Errors.WAVE_01, e);
      }
    }
  }
@ Override public void write ( Batch batch ) throws StageException { if ( batch . getRecords ( ) . hasNext ( ) ) { if ( datasetID == null ) { LOG . info ( "Opening dataset" ) ; try { openDataset ( ) ; } catch ( ConnectionException ce ) { throw new StageException ( Errors . WAVE_01 , ce ) ; } } LOG . info ( "Writing batch to dataset" ) ; writeToDataset ( batch ) ; try { commitDataset ( ) ; } catch ( ConnectionException | IOException e ) { throw new StageException ( Errors . WAVE_01 , e ) ; } } }
{@inheritDoc}
{