m-trieu commented on code in PR #31133:
URL: https://github.com/apache/beam/pull/31133#discussion_r1588487721
##########
runners/google-cloud-dataflow-java/worker/src/main/java/org/apache/beam/runners/dataflow/worker/StreamingDataflowWorker.java:
##########
@@ -718,100 +834,27 @@ int numCommitThreads() {
public void start() {
running.set(true);
- if (windmillServiceEnabled) {
- // Schedule the background getConfig thread. Blocks until windmillServer
stub is ready.
- schedulePeriodicGlobalConfigRequests();
- }
+ configFetcher.start();
memoryMonitorThread.start();
dispatchThread.start();
sampler.start();
- if (options.getPeriodicStatusPageOutputDirectory() != null) {
- ScheduledExecutorService statusPageTimer =
executorSupplier.apply("DumpStatusPages");
- statusPageTimer.scheduleWithFixedDelay(
- () -> {
- Collection<Capturable> pages = statusPages.getDebugCapturePages();
- if (pages.isEmpty()) {
- LOG.warn("No captured status pages.");
- }
- long timestamp = clock.get().getMillis();
- for (Capturable page : pages) {
- PrintWriter writer = null;
- try {
- File outputFile =
- new File(
- options.getPeriodicStatusPageOutputDirectory(),
- ("StreamingDataflowWorker"
- + options.getWorkerId()
- + "_"
- + page.pageName()
- + timestamp
- + ".html")
- .replaceAll("/", "_"));
- writer = new PrintWriter(outputFile, UTF_8.name());
- page.captureData(writer);
- } catch (IOException e) {
- LOG.warn("Error dumping status page.", e);
- } finally {
- if (writer != null) {
- writer.close();
- }
- }
- }
- },
- 60,
- 60,
- TimeUnit.SECONDS);
- scheduledExecutors.add(statusPageTimer);
- }
workCommitter.start();
workerStatusReporter.start();
activeWorkRefresher.start();
}
public void startStatusPages() {
Review Comment:
today we don't start them for tests (same across batch and streaming
harnesses)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]