-
Notifications
You must be signed in to change notification settings - Fork 143
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
Set connector status to CONNECTED after successful validation and ping #3059
Set connector status to CONNECTED after successful validation and ping #3059
Conversation
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, just have a question
if self.reusable: | ||
self.i = 0 |
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.
I can see it's only for tests so not a big deal but does this open a risk for infinite looping anywhere?
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.
It should not be, no. Here there's no return statement, so next line that raises an error will be triggered and iterations will stop. Next time this iterator is used it's going to be iterating over same original collection, before it would immediately stop iteration.
…and ping (#3059) (#3060) Co-authored-by: Artem Shelkovnikov <[email protected]>
…nd ping (#3059) (#3061) Co-authored-by: Artem Shelkovnikov <[email protected]>
…and ping (#3059) (#3062) Co-authored-by: Artem Shelkovnikov <[email protected]>
Closes #3021
Closes https://github.com/elastic/search-team/issues/8535
Currently connectors have no way to report they're connected.
This PR makes it so that if a data source succeeds in validation and ping, then its status is set to CONNECTED.
In practice it means, that a user who had problems with their setup will see an error in UI. If they fix the credentials, before the error would go away after a sync starts. After this change the error will disappear within the service poll interval from user's action.
Checklists
Pre-Review Checklist
config.yml.example
)v7.13.2
,v7.14.0
,v8.0.0
)Release Note
Fix a UI issue with connector reporting problems with connection even if wrong configuration was fixed. Before the error would go away only when a sync is executed.