Skip to content

Commit

Permalink
Add pipeline_lifetime field to enable alert end nodes.
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 650743239
  • Loading branch information
tfx-copybara committed Jul 11, 2024
1 parent ce6f947 commit 1e9c12b
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 24 deletions.
5 changes: 2 additions & 3 deletions tfx/components/statistics_gen/executor.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
from absl import logging
import tensorflow_data_validation as tfdv
from tensorflow_data_validation.statistics import stats_options as options
from tensorflow_data_validation.utils import dashboard_util
from tfx import types
from tfx.components.statistics_gen import stats_artifact_utils
from tfx.components.util import examples_utils
Expand All @@ -27,7 +28,6 @@
from tfx.types import standard_component_specs
from tfx.utils import io_utils
from tfx.utils import json_utils
from tfx.utils import stats_utils


# Default file name for stats generated.
Expand Down Expand Up @@ -151,8 +151,7 @@ def Do(

try:
statistics_artifact.set_string_custom_property(
STATS_DASHBOARD_LINK,
stats_utils.generate_stats_dashboard_link(statistics_artifact),
STATS_DASHBOARD_LINK, dashboard_util.generate_stats_dashboard_link()
)
except Exception as e: # pylint: disable=broad-except
# log on failures to not bring down Statsgen jobs
Expand Down
5 changes: 5 additions & 0 deletions tfx/proto/orchestration/pipeline.proto
Original file line number Diff line number Diff line change
Expand Up @@ -638,6 +638,11 @@ message NodeExecutionOptions {
// If set then the node this NodeExecutionOptions belongs to marks the end
// of some lifetime.
string lifetime_start = 1;
// If True then the node this NodeExecutionOptions belongs to will execute
// when the pipeline is considered "finalized". Noted that the node will
// not have a start node and the node will always be triggered when the
// pipeline is finalized.
bool pipeline_lifetime = 2;
}
}

Expand Down
21 changes: 0 additions & 21 deletions tfx/utils/stats_utils.py

This file was deleted.

0 comments on commit 1e9c12b

Please sign in to comment.