-
Notifications
You must be signed in to change notification settings - Fork 998
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add validation when feature type is changed #1102
Conversation
serving/src/main/java/feast/serving/service/OnlineServingServiceV2.java
Outdated
Show resolved
Hide resolved
allValueMaps.putAll(valueMap); | ||
|
||
boolean isNotFound = false; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
isn't it the same as
isNotFound = !isSameType
HashMap<String, String> typingMap = | ||
new HashMap<>() { | ||
{ | ||
put("BYTES", "BYTES_VAL"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why convert to string? Can we use original enum values instead?
@@ -196,11 +241,11 @@ public GetOnlineFeaturesResponse getOnlineFeatures(GetOnlineFeaturesRequestV2 re | |||
} | |||
|
|||
private static Map<String, ValueProto.Value> unpackValueMap( | |||
Optional<Feature> feature, boolean isOutsideMaxAge) { | |||
Optional<Feature> feature, boolean isOutsideMaxAge, boolean isSameType) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sameType
name seems not very clear here
Signed-off-by: Terence <terencelimxp@gmail.com>
Signed-off-by: Terence <terencelimxp@gmail.com>
5e9adc1
to
1f407e3
Compare
Signed-off-by: Terence <terencelimxp@gmail.com>
Signed-off-by: Terence <terencelimxp@gmail.com>
/test test-end-to-end-gcp |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: pyalex, terryyylim The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/lgtm |
Signed-off-by: Terence terencelimxp@gmail.com
What this PR does / why we need it:
In the past, we didn't allow changes to feature types so this validation was not necessary. As we think about implementing deletion of feature tables, we'll need to consider how old values stored in redis will be retrieved. This PR is the first step to handling older values that are based of older types.
Which issue(s) this PR fixes:
Fixes #
Does this PR introduce a user-facing change?: