- 
                Notifications
    You must be signed in to change notification settings 
- Fork 451
Fix: Skip the non-exist namespaces when there are multiple mongo instance metrics to scrape #1146
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
base: main
Are you sure you want to change the base?
Changes from 2 commits
23c3c41
              b70a24b
              2ac37cb
              8c6a3c1
              File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | 
|---|---|---|
|  | @@ -199,8 +199,9 @@ func TestCheckNamespacesForViews(t *testing.T) { | |
| defer cleanupDB(ctx, client) | ||
|  | ||
| t.Run("Views in provided collection list (should fail)", func(t *testing.T) { | ||
| _, err := checkNamespacesForViews(ctx, client, []string{"testdb01.col01", "testdb01.system.views", "testdb01.view01"}) | ||
| assert.EqualError(t, err, "namespace testdb01.view01 is a view and cannot be used for collstats/indexstats") | ||
| filtered, err := checkNamespacesForViews(ctx, client, []string{"testdb01.col01", "testdb01.system.views", "testdb01.view01"}) | ||
| assert.NoError(t, err) | ||
| assert.Equal(t, []string{"testdb01.col01", "testdb01.system.views"}, filtered) | ||
|          | ||
| }) | ||
|  | ||
| t.Run("No Views in provided collection list", func(t *testing.T) { | ||
|  | ||
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.
let's log that we are skipping this collection
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.
yeah good idea