-
Notifications
You must be signed in to change notification settings - Fork 5k
Refactor of system/memory metricset #26334
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
Merged
fearful-symmetry
merged 35 commits into
elastic:master
from
fearful-symmetry:system-refactor-memory
Jun 29, 2021
Merged
Changes from 16 commits
Commits
Show all changes
35 commits
Select commit
Hold shift + click to select a range
a8003d0
init commit
fearful-symmetry cc898a1
start on linux implementation
fearful-symmetry b243bd0
finish linux, start work on darwin
fearful-symmetry 59fc7d4
fix build platform issues
fearful-symmetry f51e0bf
fix metrics on darwin
fearful-symmetry 484d064
add openbsd
fearful-symmetry fa17efd
add freebsd
fearful-symmetry d9da0ea
add windows, aix
fearful-symmetry 6fea17d
fix aix build
fearful-symmetry b89318b
finish memory
fearful-symmetry 13fe38c
Merge remote-tracking branch 'upstream/master' into system-refactor-m…
fearful-symmetry 44065b3
fix up opt changes
fearful-symmetry cd760cb
cleanup metricset code
fearful-symmetry 4cec2e0
Merge remote-tracking branch 'upstream/master' into system-refactor-m…
fearful-symmetry 4e6618c
Merge remote-tracking branch 'upstream/master' into system-refactor-m…
fearful-symmetry 7c93b60
fix up folder methods
fearful-symmetry 5b28daa
fix calculations, Opt API, gomod
fearful-symmetry a517ecb
make notice
fearful-symmetry fd8cb86
Merge remote-tracking branch 'upstream/master' into system-refactor-m…
fearful-symmetry dd6a0e1
go mod tidy, mage fmt
fearful-symmetry 87aaeaa
fix up linux/memory
fearful-symmetry 0574d52
update fields
fearful-symmetry 4753d23
Merge remote-tracking branch 'upstream/master' into system-refactor-m…
fearful-symmetry c7fb4e7
update system tests
fearful-symmetry 6c0bc54
fix system tests, again
fearful-symmetry 316c501
Merge remote-tracking branch 'upstream/master' into system-refactor-m…
fearful-symmetry 5088c94
fix extra print statements
fearful-symmetry 7b52da1
fix if block in fillPercentages
fearful-symmetry 28fb3c9
Merge remote-tracking branch 'upstream/master' into system-refactor-m…
fearful-symmetry d5f5ea1
vix Value API
fearful-symmetry 0c12bd9
Merge remote-tracking branch 'upstream/master' into system-refactor-m…
fearful-symmetry 7e57c13
Merge remote-tracking branch 'upstream/master' into system-refactor-m…
fearful-symmetry 5ff4463
Merge remote-tracking branch 'upstream/master' into system-refactor-m…
fearful-symmetry e3e5542
Merge remote-tracking branch 'upstream/master' into system-refactor-m…
fearful-symmetry 8212fee
fix up tests, opt
fearful-symmetry File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,44 @@ | ||
| // Licensed to Elasticsearch B.V. under one or more contributor | ||
| // license agreements. See the NOTICE file distributed with | ||
| // this work for additional information regarding copyright | ||
| // ownership. Elasticsearch B.V. licenses this file to you under | ||
| // the Apache License, Version 2.0 (the "License"); you may | ||
| // not use this file except in compliance with the License. | ||
| // You may obtain a copy of the License at | ||
| // | ||
| // http://www.apache.org/licenses/LICENSE-2.0 | ||
| // | ||
| // Unless required by applicable law or agreed to in writing, | ||
| // software distributed under the License is distributed on an | ||
| // "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY | ||
| // KIND, either express or implied. See the License for the | ||
| // specific language governing permissions and limitations | ||
| // under the License. | ||
|
|
||
| package metrics | ||
|
|
||
| import ( | ||
| "github.com/elastic/go-structform" | ||
| ) | ||
|
|
||
| // Fold implements the folder interface for OptUint | ||
| func (in *OptUint) Fold(v structform.ExtVisitor) error { | ||
| if in.exists == true { | ||
| value := in.value | ||
| v.OnUint64(value) | ||
| } else { | ||
| v.OnNil() | ||
| } | ||
| return nil | ||
| } | ||
|
|
||
| // Fold implements the folder interface for OptUint | ||
| func (in *OptFloat) Fold(v structform.ExtVisitor) error { | ||
| if in.exists == true { | ||
| value := in.value | ||
| v.OnFloat64(value) | ||
| } else { | ||
| v.OnNil() | ||
| } | ||
| return nil | ||
| } | ||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.