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

Only query allocated remote assets #498

Merged

Conversation

william-richard
Copy link
Contributor

If you decommission an asset for multicollins, it shouldn't try to query it anymore.

I have tested this and it works as expected.

@tumblr/collins @byxorna @discordianfish

If you decommisssion an asset for multicollins, it shouldn't try to query it anymore
@discordianfish
Copy link
Contributor

@Primer42 I never used multicollins (but we're planning to), so not sure about the details. But why limit it to allocated assets? Shouldn't it possible to search for any kind of asset, even decomissioned?

@roymarantz
Copy link
Contributor

I believe this code is used to find the remote collins instances to query so it 👍

@william-richard
Copy link
Contributor Author

@discordianfish sorry for the confusion - the way multicollins works is that you create an asset (usually of type DATA_CENTER) in your local instance of collins, and set an attribute (default is LOCATION) with the url with creds that allow you to query the remote collins i.e. http://user:pass@collins.other-dc.example.com/. If you ask collins to do a remote query, it searches its local database for all of the assets of the correct type with the LOCATION attribute set, and uses the value of that LOCATION attribute to query the remote collins, and returns the results all together.
I'm modifying the code that does that local search, so when it's trying to find the remote datacenter assets, it only chooses Allocated assets instead of choosing all datacenter assets regardless of state.
Does that make more sense?

@discordianfish
Copy link
Contributor

@Primer42 Ah! Got it. In this case, LGTM!

@defect
Copy link
Contributor

defect commented Dec 16, 2016

👍

@william-richard william-richard merged commit 5081f5a into master Dec 20, 2016
@william-richard william-richard deleted the will-multicollins-only-query-allocated-assets branch December 20, 2016 17:17
@ssgelm
Copy link
Contributor

ssgelm commented Sep 15, 2020

Just FYI this should be documented somewhere. Nowhere is it specified in the docs that DATA_CENTER assets must be in the allocated state and ours were not (cause it never seemed to matter in the past).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants