Add dashboard required fields

This commit is contained in:
pmbrull 2022-04-18 16:45:33 +02:00
parent 188e5e886e
commit c7fe4f8968
9 changed files with 38 additions and 13 deletions

View File

@ -41,5 +41,6 @@
"$ref": "../connectionBasicType.json#/definitions/supportsMetadataExtraction" "$ref": "../connectionBasicType.json#/definitions/supportsMetadataExtraction"
} }
}, },
"additionalProperties": false "additionalProperties": false,
"required": ["hostPort", "username"]
} }

View File

@ -40,5 +40,9 @@
"$ref": "../connectionBasicType.json#/definitions/supportsMetadataExtraction" "$ref": "../connectionBasicType.json#/definitions/supportsMetadataExtraction"
} }
}, },
"additionalProperties": false "additionalProperties": false,
"required": [
"hostPort",
"username"
]
} }

View File

@ -36,7 +36,7 @@
"description": "Dashboard redirect URI for the PowerBI.", "description": "Dashboard redirect URI for the PowerBI.",
"type": "string" "type": "string"
}, },
"dashboardURL": { "hostPort": {
"description": "Dashboard URL for the power BI.", "description": "Dashboard URL for the power BI.",
"type": "string", "type": "string",
"format": "uri", "format": "uri",
@ -54,5 +54,10 @@
"$ref": "../connectionBasicType.json#/definitions/supportsMetadataExtraction" "$ref": "../connectionBasicType.json#/definitions/supportsMetadataExtraction"
} }
}, },
"additionalProperties": false "additionalProperties": false,
"required": [
"hostPort",
"clientId",
"clientSecret"
]
} }

View File

@ -23,7 +23,7 @@
"description": "username for the Redash", "description": "username for the Redash",
"type": "string" "type": "string"
}, },
"redashURL": { "hostPort": {
"description": "URL for the redash instance", "description": "URL for the redash instance",
"type": "string", "type": "string",
"format": "uri", "format": "uri",
@ -37,5 +37,10 @@
"$ref": "../connectionBasicType.json#/definitions/supportsMetadataExtraction" "$ref": "../connectionBasicType.json#/definitions/supportsMetadataExtraction"
} }
}, },
"additionalProperties": false "additionalProperties": false,
"required": [
"hostPort",
"username",
"apiKey"
]
} }

View File

@ -52,5 +52,9 @@
"$ref": "../connectionBasicType.json#/definitions/supportsMetadataExtraction" "$ref": "../connectionBasicType.json#/definitions/supportsMetadataExtraction"
} }
}, },
"additionalProperties": false "additionalProperties": false,
"required": [
"hostPort",
"username"
]
} }

View File

@ -57,5 +57,9 @@
"$ref": "../connectionBasicType.json#/definitions/supportsMetadataExtraction" "$ref": "../connectionBasicType.json#/definitions/supportsMetadataExtraction"
} }
}, },
"additionalProperties": false "additionalProperties": false,
"required": [
"hostPort",
"username"
]
} }

View File

@ -7,7 +7,7 @@
"clientId": "client_id", "clientId": "client_id",
"clientSecret": "client_secret", "clientSecret": "client_secret",
"redirectURI": "http://localhost:8585/callback", "redirectURI": "http://localhost:8585/callback",
"dashboardURL": "https://analysis.windows.net/powerbi", "hostPort": "https://analysis.windows.net/powerbi",
"scope": [ "scope": [
"scope", "scope",
"https://analysis.windows.net/powerbi/api/App.Read.All" "https://analysis.windows.net/powerbi/api/App.Read.All"

View File

@ -5,8 +5,9 @@
"serviceConnection": { "serviceConnection": {
"config": { "config": {
"type": "Redash", "type": "Redash",
"redashURL": "http://localhost:5000", "hostPort": "http://localhost:5000",
"apiKey": "api_key" "apiKey": "api_key",
"username": "random"
} }
}, },
"sourceConfig": { "sourceConfig": {

View File

@ -546,7 +546,7 @@ def test_powerbi():
"clientId": "client_id", "clientId": "client_id",
"clientSecret": "client_secret", "clientSecret": "client_secret",
"redirectURI": "http://localhost:8585/callback", "redirectURI": "http://localhost:8585/callback",
"dashboardURL": "https://analysis.windows.net/powerbi", "hostPort": "https://analysis.windows.net/powerbi",
"scope": [ "scope": [
"scope", "scope",
"https://analysis.windows.net/powerbi/api/App.Read.All", "https://analysis.windows.net/powerbi/api/App.Read.All",
@ -590,7 +590,8 @@ def test_redash():
"serviceConnection": { "serviceConnection": {
"config": { "config": {
"type": "Redash", "type": "Redash",
"redashURL": "http://localhost:5000", "hostPort": "http://localhost:5000",
"username": "random",
"apiKey": "api_key", "apiKey": "api_key",
} }
}, },