@Override public void finishBundle() { doFnRunner.finishBundle(); }
@Override public void processElement(final WindowedValue<InputT> elem) { try (Closeable ignored = MetricsEnvironment.scopedMetricsContainer(metricsContainer())) { delegate.processElement(elem); } catch (IOException e) { throw new RuntimeException(e); } }
@Override public void startBundle() { underlying.startBundle(); }
doFnRunner.startBundle(); doFnRunner.processElement(value); doFnRunner.finishBundle();
WindowingStrategy.of(new GlobalWindows())); runner.startBundle(); runner.processElement( WindowedValue.timestampedValueInGlobalWindow(Duration.millis(1L), new Instant(0))); runner.processElement( WindowedValue.timestampedValueInGlobalWindow( Duration.millis(1L), BoundedWindow.TIMESTAMP_MIN_VALUE.plus(Duration.millis(1)))); runner.processElement( WindowedValue.timestampedValueInGlobalWindow(
@Override public void onTimer( String timerId, BoundedWindow window, Instant timestamp, TimeDomain timeDomain) { underlying.onTimer(timerId, window, timestamp, timeDomain); }
@Override public DoFn<InputT, OutputT> getFn() { return delegate.getFn(); } }
doFnRunner.startBundle(); doFnRunner.processElement(value); doFnRunner.finishBundle();
WindowingStrategy.of(new GlobalWindows())); runner.startBundle(); runner.processElement( WindowedValue.timestampedValueInGlobalWindow(Duration.ZERO, new Instant(0))); thrown.expect(UserCodeException.class); "the allowed skew (%s)", PeriodFormat.getDefault().print(Duration.ZERO.toPeriod()))); runner.processElement( WindowedValue.timestampedValueInGlobalWindow(Duration.millis(1L), new Instant(0)));
@Override public void onTimer( String timerId, BoundedWindow window, Instant timestamp, TimeDomain timeDomain) { doFnRunner.onTimer(timerId, window, timestamp, timeDomain); }
@Override public DoFn<KeyedWorkItem<K, InputT>, KV<K, OutputT>> getFn() { return doFnRunner.getFn(); }
doFnRunner.startBundle(); doFnRunner.processElement(value); doFnRunner.finishBundle();
@Override public void processElement(final WindowedValue<InputT> elem) { try (Closeable ignored = MetricsEnvironment.scopedMetricsContainer(container.getMetricsContainer(stepName))) { delegate.processElement(elem); } catch (IOException e) { throw new RuntimeException(e); } }
WindowingStrategy.of(new GlobalWindows())); runner.startBundle(); runner.processElement( WindowedValue.timestampedValueInGlobalWindow(Duration.standardMinutes(5L), new Instant(0))); thrown.expect(UserCodeException.class); PeriodFormat.getDefault().print(Duration.standardMinutes(10L).toPeriod()))); runner.processElement( WindowedValue.timestampedValueInGlobalWindow(Duration.standardHours(1L), new Instant(0)));
@Override public void finishBundle() { notReadyWindows = null; underlying.finishBundle(); } }
@Override public void startBundle() { doFnRunner.startBundle(); }
@Override public void onTimer( final String timerId, final BoundedWindow window, final Instant timestamp, final TimeDomain timeDomain) { try (Closeable ignored = MetricsEnvironment.scopedMetricsContainer(metricsContainer())) { delegate.onTimer(timerId, window, timestamp, timeDomain); } catch (IOException e) { throw new RuntimeException(e); } }
@Override public DoFn<InputT, OutputT> getFn() { return doFnRunner.getFn(); }
doFnRunner.startBundle(); doFnRunner.processElement(currentValue); while (iterator.hasNext()) { currentValue = iterator.next(); doFnRunner.processElement(currentValue); doFnRunner.finishBundle();
@Override public void processElement(final WindowedValue<InputT> elem) { try (Closeable ignored = MetricsEnvironment.scopedMetricsContainer(container.getMetricsContainer(stepName))) { delegate.processElement(elem); } catch (IOException e) { throw new RuntimeException(e); } }