-
Notifications
You must be signed in to change notification settings - Fork 1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: Make transformation_service_endpoint configuration optional (#4880)
* Make transformation_service_endpoint configuration optional Signed-off-by: Dimitris Stafylarakis <[email protected]> * Add custom error for transformation service, implement featurestore unit tests Signed-off-by: Dimitris Stafylarakis <[email protected]> --------- Signed-off-by: Dimitris Stafylarakis <[email protected]>
- Loading branch information
Showing
4 changed files
with
264 additions
and
93 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
package feast | ||
|
||
import ( | ||
"google.golang.org/genproto/googleapis/rpc/errdetails" | ||
"google.golang.org/grpc/codes" | ||
"google.golang.org/grpc/status" | ||
) | ||
|
||
type FeastTransformationServiceNotConfigured struct{} | ||
|
||
func (FeastTransformationServiceNotConfigured) GRPCStatus() *status.Status { | ||
errorStatus := status.New(codes.Internal, "No transformation service configured") | ||
ds, err := errorStatus.WithDetails(&errdetails.LocalizedMessage{Message: "No transformation service configured, required for on-demand feature transformations"}) | ||
if err != nil { | ||
return errorStatus | ||
} | ||
return ds | ||
} | ||
|
||
func (e FeastTransformationServiceNotConfigured) Error() string { | ||
return e.GRPCStatus().Err().Error() | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.