-
Notifications
You must be signed in to change notification settings - Fork 55
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
Set up model registry context and apiHooks #360
Conversation
75118d0
to
f33b037
Compare
Test are failing, I opened the PR cause I wanted to ask why it's not working as expected |
@@ -17,7 +18,7 @@ const ( | |||
ModelRegistryId = "model_registry_id" | |||
RegisteredModelId = "registered_model_id" | |||
HealthCheckPath = PathPrefix + "/healthcheck" | |||
ModelRegistry = PathPrefix + "/model-registry" | |||
ModelRegistry = PathPrefix + "/model_registry" |
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.
@alexcreasy @ederign @Griffin-Sullivan I've just updated this enpoint cause it wasn't using the api specification and it was making the dev env to fail, I can leave this out of the PR if you guys wanna add it into other PR.
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.
I'm fine with this, but could you update the BFF readme so the examples are correct?
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.
Fixed, thanks a lot for the review!!
@@ -18,7 +18,6 @@ module.exports = merge(common('development'), { | |||
host: HOST, | |||
port: PORT, | |||
historyApiFallback: true, | |||
open: true, |
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.
I've just removed the auto open, we disabled it in other projects cause some people in the community tend to dislike it.
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.
Thanks... auto open drives me nuts because I'm lame and use Safari as my default browser but like to develop in chrome :D
(opts: APIOptions): Promise<ModelRegistry> => | ||
handleRestFailures(restGET(hostPath, `/api/${BFF_API_VERSION}/model_registry`, {}, opts)); | ||
(opts: APIOptions): Promise<ModelRegistry[]> => | ||
handleRestFailures(restGET(hostPath, `/api/${BFF_API_VERSION}/model_registry`, {}, opts)).then( |
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.
Just added here the conversion to make it easier to process in the rest of the dashboard.
|
||
export const createRegisteredModel = | ||
(hostPath: string, mrName: string) => | ||
(hostPath: string) => |
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.
It made more sense passing most of the path as hostPath
rather than parameters.
@@ -0,0 +1,32 @@ | |||
import * as React from 'react'; |
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.
Refactor of useApi for the proxy
e57758c
to
8538a76
Compare
Signed-off-by: lucferbux <[email protected]>
8538a76
to
d49c850
Compare
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.
I'm fine with the changes. Lots going on here so can't give a super great review but tests are passing, it works for me locally, and I don't want to get held up on this when we have more things depending on it.
@@ -42,7 +42,7 @@ export const useAdminSettings = (): NavDataItem[] => { | |||
export const useNavData = (): NavDataItem[] => [ | |||
{ | |||
label: 'Model Registry', | |||
path: '/', | |||
path: '/modelRegistry', |
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.
is it normal to do camel case for URLs?
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.
This is a valid point, im just porting midstream code but we can refactor in the future.
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.
yeah, agree with Griffin, but no need to change right now.
Signed-off-by: lucferbux <[email protected]>
d49c850
to
c08bd10
Compare
/lgtm |
/approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: alexcreasy, Griffin-Sullivan 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 |
Description
This is a really big PR, added some views to test the context and apiHooks cause there were some issues that I couldn't test until we could hook them into views.
Model Registry Context
Api Hooks
Model Registry Empty View and MR Selector
How Has This Been Tested?
Merge criteria:
DCO
check)If you have UI changes