databricks / databricks-sdk-go

Databricks SDK for Go
https://docs.databricks.com/dev-tools/sdk-go.html
Apache License 2.0
46 stars 37 forks source link

[ISSUE] `workspaceClient.RegisteredModels.ListAll` fails to list all models #813

Open alexott opened 4 months ago

alexott commented 4 months ago

Code to list all models in a metastore:

models, err := ic.workspaceClient.RegisteredModels.ListAll(ctx, catalog.ListRegisteredModelsRequest{})

is failing with the following error:

If no catalog or schema is set, maxResults must be set.

Go SDK 0.30.0

mgyucht commented 4 months ago

Can you specify maxResults, catalog or schema?

However, it seems like a very weird requirement to have to specify max results. I think we should probably raise this to the backing team to see if they can lift this requirement (especially since with pagination, users should be able to get all models if need be).

alexott commented 4 months ago

Yep, it's a weird requirement. Can we push back to the corresponding team?