-
Notifications
You must be signed in to change notification settings - Fork 37
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
Delete ES element. #733
base: v5-unstable
Are you sure you want to change the base?
Delete ES element. #733
Conversation
Refer to this link for build results (access rights to CI server needed): |
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 with one comment
internal/charmstore/store.go
Outdated
@@ -1284,7 +1286,13 @@ func (s *Store) DeleteEntity(id *router.ResolvedURL) error { | |||
return errgo.Notef(err, "cannot remove compatibility blob %s", name) | |||
} | |||
} | |||
|
|||
if s.ES == nil || s.ES.Database == nil { |
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.
you don't need to do this check in both places, just call s.ES.delete and let it return nil if its not configured.
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.
When charm/5 is deleted, charm/4 needs to be reindexed. We have to keep the promise of indexing the last revision/
Refer to this link for build results (access rights to CI server needed): |
Refer to this link for build results (access rights to CI server needed): |
No description provided.