-
Notifications
You must be signed in to change notification settings - Fork 154
Description
At the moment Model Registry has two client entrypoints in the codebase:
pkg/openapi: the auto generated client from the openapi schemapkg/core: a grpc client that talks directly with the MLMD service
This creates a strong dependency on the MLMD service and makes difficult changing the underlying service without major breaking changes in the future, also we cannot trace/log/audit what users are doing to the metadata store if they bypass our proxy. My proposal is to move the package from pkg/core to internal/core and do a refactoring to make it a switchable datastore for the model registry. What I mean by switchable datastore is to change the config arguments that we take in the proxy:
- (change) mlmd_hostname -> datastore_hostname
- (change) mlmd_port -> datastore_port
- (create) datastore_service(type?) = mlmd / sqlite / whatever
then in model registry we can use a factory method to use the correct datastore implementation of the interface ModelRegistryServiceAPIServicer
I did a check on which projects import pkg/core and for upstream I didn't find any (https://pkg.go.dev/github.com/kubeflow/model-registry/pkg/core?tab=importedby), but we have a breaking change in the midstream (https://pkg.go.dev/github.com/opendatahub-io/model-registry/pkg/core?tab=importedby) we should make the team that works on opendatahub-io/odh-model-controller aware of this change.
