-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
WIP Generate fields, dashboards, config from mage #8609
Conversation
package include | ||
|
||
import ( | ||
_ "github.com/elastic/beats/x-pack/filebeat/module/suricata" |
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.
a blank import should be only in a main or test package, or have a comment justifying it
numDashes /= 2 | ||
return strings.Repeat("-", numDashes) | ||
} | ||
func GenerateModuleReferenceConfig(out string, moduleDirs ...string) error { |
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.
exported function GenerateModuleReferenceConfig should have comment or be unexported
Generate the fields, dashboards, and config files from mage to make it reusable across Beats (include x-pack). This allows x-pack/filebeat to generate its own unique fields, dashboards, and config.
1d62b1d
to
cfe009b
Compare
@@ -82,10 +83,22 @@ func UseElasticBeatWithoutXPackPackaging() { | |||
} | |||
} | |||
|
|||
func LoadLocalNamedSpec(name string) { |
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.
exported function LoadLocalNamedSpec should have comment or be unexported
return assetCmd() | ||
} | ||
|
||
func GenerateModuleFieldsGo() error { |
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.
exported function GenerateModuleFieldsGo should have comment or be unexported
return generateFieldsYAML(OSSBeatDir(), moduleDirs...) | ||
} | ||
|
||
func OSSBeatDir(path ...string) string { |
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.
exported function OSSBeatDir should have comment or be unexported
import ( | ||
"github.com/elastic/beats/filebeat/cmd" | ||
|
||
_ "github.com/elastic/beats/x-pack/filebeat/include" |
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.
a blank import should be only in a main or test package, or have a comment justifying it
Closing in favor of #8615 which is less ambitious in that it only tries to affect x-pack/filebeat for 6.x. |
IN PROGRESS
Generate the fields, dashboards, and config files from mage to make it reusable across Beats (include x-pack). This allows x-pack/filebeat to generate its own unique fields, dashboards, and config.