Skip to content

Service principal looses displayName variable at the account level when created in workspace context #4718

@justaskel

Description

@justaskel

Describe the issue

Working with Databricks on AWS - when creating service principal using workspace level authentication displayName variable isn't visible at the account level. It defaults to application_id value in the UI. For example:
db -p workspace-profile service-principals create --display-name name-test
{
"active":true,
"applicationId":"",
"displayName":"name-test",
"id":"78042222201909",
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:ServicePrincipal"
]
}
then in workspace context displayName is returned:
db -p workspace-profile service-principals get 78042222201909
{
"active":true,
"applicationId":"
*",
"displayName":"name-test",
"id":"78042222201909",
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:ServicePrincipal"
]
}

but in the account it is not visible anymore:

db -p account-profile account service-principals get 78042222201909
{
"active":true,
"applicationId":"********",
"id":"78042222201909",
"schemas": [
"urn:ietf:params:scim:schemas:core:2.0:ServicePrincipal"
]
}

Disclaimer - I have tested curl commands querying API directly and got the same results, it is likely the issue is there but, since API isn't a public repository reporting it here.

Steps to reproduce the behavior

Please list the steps required to reproduce the issue, for example:
Commands can be run as per description above.

Expected Behavior

Clear and concise description of what should have happened
Service principal created but displayName isn't visible at the account level.

Actual Behavior

Clear and concise description of what actually happened
As per description above

OS and CLI version

Please include the version of the CLI (eg: v0.1.2) and the operating system (eg: windows). You can run databricks --version to get the version of your Databricks CLI
Databricks CLI v0.287.0

Is this a regression?

Did this work in a previous version of the CLI? If so, which versions did you try?
Yes, this worked before but likely API related rather than CLI itself.

Debug Logs

Output logs if you run the command with debug logs enabled. Example: databricks clusters list --log-level=debug. Redact if needed

Metadata

Metadata

Assignees

No one assigned

    Labels

    CLICLI related issues

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions