Skip to content

fix: Skip entity/join-key columns in lookup metrics - #378

Merged
vanitabhagwat merged 1 commit into
masterfrom
fix/lookup-metrics-skip-entity-columns
Aug 20, 2026
Merged

fix: Skip entity/join-key columns in lookup metrics#378
vanitabhagwat merged 1 commit into
masterfrom
fix/lookup-metrics-skip-entity-columns

Conversation

@vanitabhagwat

Copy link
Copy Markdown
Collaborator

What this PR does / why we need it:

The feature server's lookup-metrics aggregator recorded every entry in the merged featureVectors slice returned by GetOnlineFeatures, including entity/join-key columns (e.g. exp_user_id, eg_user_id). Those columns are intentionally given an empty FeatureViewName since they don't belong to any feature view (see onlineserving.EntitiesToFeatureVectors), but the metrics code treated the empty name as an unresolved feature view, tagging it feature_view:unknown and logging:

WARNING: Lookup metrics feature_view tag set to 'unknown' for feature: exp_user_id. This may indicate FeatureViewName was not populated.

on every request. This produced constant log/Datadog noise and an inflated/misleading "missing lookup" metric in production.

This PR filters out vectors with FeatureViewName == "" in LookupMetricsAggregator.RecordFromFeatureVectors / RecordFromRangeFeatureVectors before they're recorded, so entity columns are no longer reported as feature lookups. This brings the mlpfs.featureserver.feature_lookup_requests metric in line with the debug-logging FeaturesReturnedCount metric in server_commons.go, which already excludes entity columns.

Which issue(s) this PR fixes:

Fixes EAPC-22642 (internal Jira: https://expediagroup.atlassian.net/browse/EAPC-22642)

Misc

Added unit tests TestRecordFromFeatureVectors_SkipsEntityColumns and TestRecordFromRangeFeatureVectors_SkipsEntityColumns covering the new filtering behavior. Verified go test ./internal/feast/metrics/... ./internal/feast/server/... passes with no regressions.

Entity columns are prepended to the feature vector slice returned by
GetOnlineFeatures with FeatureViewName left empty, but the lookup
metrics aggregator recorded every vector as if it were a feature. This
tagged entity keys (e.g. exp_user_id, eg_user_id) as feature_view:unknown
and logged a spurious warning on every request.

Fixes EAPC-22642

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@vanitabhagwat vanitabhagwat changed the title fix: skip entity/join-key columns in lookup metrics fix: Skip entity/join-key columns in lookup metrics Aug 20, 2026
@vanitabhagwat
vanitabhagwat merged commit a79e21c into master Aug 20, 2026
29 of 30 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants