Skip to content
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

DXCDT-339: Fix issue with properties not being computed on oidc connections #443

Merged
merged 4 commits into from
Jan 27, 2023
Merged
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions internal/provider/resource_auth0_connection.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ var connectionSchema = map[string]*schema.Schema{
"display_name": {
Type: schema.TypeString,
Optional: true,
Computed: true,
Copy link
Contributor

@Widcket Widcket Jan 27, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The following option fields on the connection authorization_endpoint, issuer, jwks_uri, token_endpoint, or user_info_endpoint can be set to default values by the API

Just checking, display_name as well?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Apparently display_name is a computed value for OIDC connection types, defaulting to the name field if not defined. It's a bit of a toss-up of wether its' worth it to mark as computed for all connections to accommodate this single connection type, but the consequences are minimal either way. @sergiught and I just changed our minds on this and decided to remove to minimize the effects for the majority of users.

Description: "Name used in login screen.",
},
"is_domain_connection": {
Expand Down Expand Up @@ -561,11 +562,13 @@ var connectionSchema = map[string]*schema.Schema{
"issuer": {
Type: schema.TypeString,
Optional: true,
Computed: true,
Description: "Issuer URL, e.g. `https://auth.example.com`.",
},
"jwks_uri": {
Type: schema.TypeString,
Optional: true,
Computed: true,
Description: "JWKS URI.",
},
"discovery_url": {
Expand All @@ -576,16 +579,19 @@ var connectionSchema = map[string]*schema.Schema{
"token_endpoint": {
Type: schema.TypeString,
Optional: true,
Computed: true,
Description: "Token endpoint.",
},
"userinfo_endpoint": {
Type: schema.TypeString,
Optional: true,
Computed: true,
Description: "User info endpoint.",
},
"authorization_endpoint": {
Type: schema.TypeString,
Optional: true,
Computed: true,
Description: "Authorization endpoint.",
},
"debug": {
Expand Down