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

[integration][vsphere] Add optional vm include parameter #2459

Merged
merged 2 commits into from
May 18, 2016
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Small modification from nit
JohnLZeller committed May 18, 2016

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
commit 27702539da313965b854162d1640f63c030327b9
4 changes: 2 additions & 2 deletions checks.d/vsphere.py
Original file line number Diff line number Diff line change
@@ -609,7 +609,7 @@ def _cache_morlist_raw_atomic(self, i_key, obj_type, obj, tags, regexes=None, in
return
# Also, if include_only_marked is true, then check if there exists a
# custom field with the value DatadogMonitored
if _is_affirmative(include_only_marked):
if include_only_marked:
monitored = False
for field in obj.customValue:
if field.value == VM_MONITORING_FLAG:
@@ -650,7 +650,7 @@ def _cache_morlist_raw(self, instance):
'host_include': instance.get('host_include_only_regex'),
'vm_include': instance.get('vm_include_only_regex')
}
include_only_marked = instance.get('include_only_marked', False)
include_only_marked = _is_affirmative(instance.get('include_only_marked', False))
self.pool.apply_async(
self._cache_morlist_raw_atomic,
args=(i_key, 'rootFolder', root_folder, [instance_tag], regexes, include_only_marked)