-
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
Fix missing datasource issue on pod restart #1358
Fix missing datasource issue on pod restart #1358
Conversation
Signed-off-by: Saad Khan <[email protected]>
@khansaad - I still see the issue, Is this working for you? |
@@ -144,6 +144,10 @@ public void addDataSourcesFromConfigFile(String configFileName) { | |||
DataSourceInfo dataSourceInfo = new ExperimentDBService().loadDataSourceFromDBByName(name); | |||
if (null != dataSourceInfo) { | |||
LOGGER.error("Datasource: {} already exists!", name); | |||
// add the auth details to local object | |||
AuthenticationConfig authConfig = getAuthenticationDetails(dataSourceObject, name); |
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.
Do we need to check if getAuthenticationConfig() will retun null
if so then do setAuthenticationConfig() ?
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.
We don't need that because in case of missing auth, getAuthenticationDetails()
will return the default auth i.e. noAuth
Reference:
authConfig = AuthenticationConfig.noAuth(); |
Signed-off-by: Saad Khan <[email protected]>
@chandrams Looks like you're not passing the I have updated the error message now to indicate the |
I have tested with the below in the manifest file:
|
I have included datasource in the bulk config, with this I don't see the invalid datasource issue. |
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.
LGTM
@khansaad if required please feel free add negative testcases |
Signed-off-by: Saad Khan <[email protected]>
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.
LGTM
Description
This PR fixes the issue with datasource which is causing a
missing or invalid datasource
exception. Details for the same are mentioned in Issue 1356Fixes 1356
Type of change
How has this been tested?
Please describe the tests that were run to verify your changes and steps to reproduce. Please specify any test configuration required.
Test Configuration
Checklist 🎯
Additional information
Include any additional information such as links, test results, screenshots here