From 2b6c1be8c4b78ed2bfe47097de2b3bcc4800de9f Mon Sep 17 00:00:00 2001 From: Alex Kristiansen Date: Wed, 15 Sep 2021 15:41:48 -0500 Subject: [PATCH 01/20] first pass at getting AIX to build --- go.mod | 9 +++++---- go.sum | 10 ++++++++++ libbeat/metric/system/diskio/doc.go | 1 + metricbeat/module/linux/iostat/data.go | 2 ++ metricbeat/module/linux/iostat/doc.go | 18 ++++++++++++++++++ metricbeat/module/linux/iostat/iostat.go | 2 ++ metricbeat/module/system/service/data.go | 2 +- metricbeat/module/system/service/dbus.go | 2 +- metricbeat/module/system/service/service.go | 2 +- .../module/system/service/service_test.go | 2 +- 10 files changed, 42 insertions(+), 8 deletions(-) create mode 100644 libbeat/metric/system/diskio/doc.go create mode 100644 metricbeat/module/linux/iostat/doc.go diff --git a/go.mod b/go.mod index 07baf547449..28c350e07ce 100644 --- a/go.mod +++ b/go.mod @@ -70,7 +70,7 @@ require ( github.com/elastic/go-seccomp-bpf v1.1.0 github.com/elastic/go-structform v0.0.9 github.com/elastic/go-sysinfo v1.7.0 - github.com/elastic/go-txfile v0.0.7 + github.com/elastic/go-txfile v0.0.8 github.com/elastic/go-ucfg v0.8.3 github.com/elastic/go-windows v1.0.1 github.com/elastic/gosigar v0.14.1 @@ -84,7 +84,7 @@ require ( github.com/gocarina/gocsv v0.0.0-20170324095351-ffef3ffc77be github.com/godbus/dbus v0.0.0-20190422162347-ade71ed3457e github.com/godror/godror v0.10.4 - github.com/gofrs/flock v0.7.2-0.20190320160742-5135e617513b + github.com/gofrs/flock v0.8.1 github.com/gofrs/uuid v3.3.0+incompatible github.com/gogo/protobuf v1.3.2 github.com/golang/mock v1.6.0 @@ -113,7 +113,7 @@ require ( github.com/jpillora/backoff v1.0.0 // indirect github.com/kardianos/service v1.2.1-0.20210728001519-a323c3813bc7 github.com/konsorten/go-windows-terminal-sequences v1.0.2 // indirect - github.com/lib/pq v1.1.2-0.20190507191818-2ff3cb3adc01 + github.com/lib/pq v1.10.3 github.com/magefile/mage v1.11.0 github.com/mailru/easyjson v0.7.1 // indirect github.com/mattn/go-colorable v0.1.6 @@ -152,6 +152,7 @@ require ( github.com/tsg/go-daemon v0.0.0-20200207173439-e704b93fd89b github.com/tsg/gopacket v0.0.0-20200626092518-2ab8e397a786 github.com/ugorji/go/codec v1.1.8 + github.com/urso/magetools v0.0.0-20200125210132-c2e338f92f3a // indirect github.com/urso/sderr v0.0.0-20210525210834-52b04e8f5c71 github.com/vmware/govmomi v0.0.0-20170802214208-2cad15190b41 github.com/xdg/scram v1.0.3 @@ -170,7 +171,7 @@ require ( golang.org/x/net v0.0.0-20210614182718-04defd469f4e golang.org/x/oauth2 v0.0.0-20200107190931-bf48bf16ab8d golang.org/x/sync v0.0.0-20200317015054-43a5402ce75a - golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c + golang.org/x/sys v0.0.0-20210910150752-751e447fb3d0 golang.org/x/text v0.3.6 golang.org/x/time v0.0.0-20191024005414-555d28b269f0 golang.org/x/tools v0.1.1 diff --git a/go.sum b/go.sum index c14acc22e90..f436e891d71 100644 --- a/go.sum +++ b/go.sum @@ -275,6 +275,8 @@ github.com/elastic/go-sysinfo v1.7.0 h1:4vVvcfi255+8+TyQ7TYUTEK3A+G8v5FLE+ZKYL1z github.com/elastic/go-sysinfo v1.7.0/go.mod h1:i1ZYdU10oLNfRzq4vq62BEwD2fH8KaWh6eh0ikPT9F0= github.com/elastic/go-txfile v0.0.7 h1:Yn28gclW7X0Qy09nSMSsx0uOAvAGMsp6XHydbiLVe2s= github.com/elastic/go-txfile v0.0.7/go.mod h1:H0nCoFae0a4ga57apgxFsgmRjevNCsEaT6g56JoeKAE= +github.com/elastic/go-txfile v0.0.8 h1:hqFMmLM+UCDMJeSyuCWe8YwS+HtoX7F+cz5fhPYRTn4= +github.com/elastic/go-txfile v0.0.8/go.mod h1:H0nCoFae0a4ga57apgxFsgmRjevNCsEaT6g56JoeKAE= github.com/elastic/go-ucfg v0.7.0/go.mod h1:iaiY0NBIYeasNgycLyTvhJftQlQEUO2hpF+FX0JKxzo= github.com/elastic/go-ucfg v0.8.3 h1:leywnFjzr2QneZZWhE6uWd+QN/UpP0sdJRHYyuFvkeo= github.com/elastic/go-ucfg v0.8.3/go.mod h1:iaiY0NBIYeasNgycLyTvhJftQlQEUO2hpF+FX0JKxzo= @@ -341,6 +343,8 @@ github.com/godror/godror v0.10.4/go.mod h1:9MVLtu25FBJBMHkPs0m3Ngf/VmwGcLpM2HS8P github.com/gofrs/flock v0.7.1/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU= github.com/gofrs/flock v0.7.2-0.20190320160742-5135e617513b h1:3QNh5Xo2pmr2nZXENtnztfpjej8XY8EPmvYxF5SzY9M= github.com/gofrs/flock v0.7.2-0.20190320160742-5135e617513b/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU= +github.com/gofrs/flock v0.8.1 h1:+gYjHKf32LDeiEEFhQaotPbLuUXjY5ZqxKgXy7n59aw= +github.com/gofrs/flock v0.8.1/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU= github.com/gofrs/uuid v3.3.0+incompatible h1:8K4tyRfvU1CYPgJsveYFQMhpFd/wXNM7iK6rR7UHz84= github.com/gofrs/uuid v3.3.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= @@ -531,6 +535,8 @@ github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= github.com/lib/pq v1.0.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= github.com/lib/pq v1.1.2-0.20190507191818-2ff3cb3adc01 h1:EPw7R3OAyxHBCyl0oqh3lUZqS5lu3KSxzzGasE0opXQ= github.com/lib/pq v1.1.2-0.20190507191818-2ff3cb3adc01/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= +github.com/lib/pq v1.10.3 h1:v9QZf2Sn6AmjXtQeFpdoq/eaNtYP6IN+7lcrygsIAtg= +github.com/lib/pq v1.10.3/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= github.com/magefile/mage v1.9.0/go.mod h1:z5UZb/iS3GoOSn0JgWuiw7dxlurVYTu+/jHXqQg881A= github.com/magefile/mage v1.11.0 h1:C/55Ywp9BpgVVclD3lRnSYCwXTYxmSppIgLeDYlNuls= github.com/magefile/mage v1.11.0/go.mod h1:z5UZb/iS3GoOSn0JgWuiw7dxlurVYTu+/jHXqQg881A= @@ -740,6 +746,8 @@ github.com/urso/go-bin v0.0.0-20180220135811-781c575c9f0e h1:NiofbjIUI5gR+ybDsGS github.com/urso/go-bin v0.0.0-20180220135811-781c575c9f0e/go.mod h1:6GfHrdWBQYjFRIznu7XuQH4lYB2w8nO4bnImVKkzPOM= github.com/urso/magetools v0.0.0-20190919040553-290c89e0c230 h1:Ft1EJ6JL0F/RV6o2qJ1Be+wYxjYUSfRA3srfHgSgojc= github.com/urso/magetools v0.0.0-20190919040553-290c89e0c230/go.mod h1:DFxTNgS/ExCGmmjVjSOgS2WjtfjKXgCyDzAFgbtovSA= +github.com/urso/magetools v0.0.0-20200125210132-c2e338f92f3a h1:jWAaRFnay3H2e6S0GGCl5nKrkgQNlarCE/kvcutzBmw= +github.com/urso/magetools v0.0.0-20200125210132-c2e338f92f3a/go.mod h1:DbaJnRzkGaWrMWm5Hz6QVnUj//x9/zjrfx8bF3J+GJY= github.com/urso/qcgen v0.0.0-20180131103024-0b059e7db4f4 h1:hhA8EBThzz9PztawVTycKvfETVuBqxAQ5keFlAVtbAw= github.com/urso/qcgen v0.0.0-20180131103024-0b059e7db4f4/go.mod h1:RspW+E2Yb7Fs7HclB2tiDaiu6Rp41BiIG4Wo1YaoXGc= github.com/urso/sderr v0.0.0-20210525210834-52b04e8f5c71 h1:CehQeKbysHV8J2V7AD0w8NL2x1h04kmmo/Ft5su4lU0= @@ -920,6 +928,8 @@ golang.org/x/sys v0.0.0-20210603125802-9665404d3644/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c h1:F1jZWGFhYfh0Ci55sIpILtKKK8p3i2/krTr0H1rg74I= golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20210910150752-751e447fb3d0 h1:xrCZDmdtoloIiooiA9q0OQb9r8HejIHYoHGhGCe1pGg= +golang.org/x/sys v0.0.0-20210910150752-751e447fb3d0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1 h1:v+OssWQX+hTHEmOBgwxdZxK4zHq3yOs8F9J7mk0PY8E= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= diff --git a/libbeat/metric/system/diskio/doc.go b/libbeat/metric/system/diskio/doc.go new file mode 100644 index 00000000000..3463e97e208 --- /dev/null +++ b/libbeat/metric/system/diskio/doc.go @@ -0,0 +1 @@ +package diskio diff --git a/metricbeat/module/linux/iostat/data.go b/metricbeat/module/linux/iostat/data.go index 4e546deaa34..ada2ec706e0 100644 --- a/metricbeat/module/linux/iostat/data.go +++ b/metricbeat/module/linux/iostat/data.go @@ -15,6 +15,8 @@ // specific language governing permissions and limitations // under the License. +// +build linux + package iostat import ( diff --git a/metricbeat/module/linux/iostat/doc.go b/metricbeat/module/linux/iostat/doc.go new file mode 100644 index 00000000000..6b64442ea1e --- /dev/null +++ b/metricbeat/module/linux/iostat/doc.go @@ -0,0 +1,18 @@ +// 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 iostat diff --git a/metricbeat/module/linux/iostat/iostat.go b/metricbeat/module/linux/iostat/iostat.go index 049b4daadf7..c26bc4e01e1 100644 --- a/metricbeat/module/linux/iostat/iostat.go +++ b/metricbeat/module/linux/iostat/iostat.go @@ -15,6 +15,8 @@ // specific language governing permissions and limitations // under the License. +// +build linux + package iostat import ( diff --git a/metricbeat/module/system/service/data.go b/metricbeat/module/system/service/data.go index 077c3770f4e..48b9abba072 100644 --- a/metricbeat/module/system/service/data.go +++ b/metricbeat/module/system/service/data.go @@ -15,7 +15,7 @@ // specific language governing permissions and limitations // under the License. -//+build !netbsd +//+build linux package service diff --git a/metricbeat/module/system/service/dbus.go b/metricbeat/module/system/service/dbus.go index c3c5bf1dc41..87804d800ba 100644 --- a/metricbeat/module/system/service/dbus.go +++ b/metricbeat/module/system/service/dbus.go @@ -15,7 +15,7 @@ // specific language governing permissions and limitations // under the License. -//+build !netbsd +//+build linux package service diff --git a/metricbeat/module/system/service/service.go b/metricbeat/module/system/service/service.go index 850a86b0a98..dfbaeba788d 100644 --- a/metricbeat/module/system/service/service.go +++ b/metricbeat/module/system/service/service.go @@ -15,7 +15,7 @@ // specific language governing permissions and limitations // under the License. -//+build !netbsd +//+build linux package service diff --git a/metricbeat/module/system/service/service_test.go b/metricbeat/module/system/service/service_test.go index 87581ff45f8..2649b037700 100644 --- a/metricbeat/module/system/service/service_test.go +++ b/metricbeat/module/system/service/service_test.go @@ -15,7 +15,7 @@ // specific language governing permissions and limitations // under the License. -//+build !netbsd +//+build linux package service From 10cff7bb037112d88ba790fd602eb69d64cd665b Mon Sep 17 00:00:00 2001 From: Alex Kristiansen Date: Wed, 15 Sep 2021 16:01:50 -0500 Subject: [PATCH 02/20] make notice --- NOTICE.txt | 231 +++++++++++++++++++++++++++++++++++++++++++++++++---- go.sum | 9 --- 2 files changed, 217 insertions(+), 23 deletions(-) diff --git a/NOTICE.txt b/NOTICE.txt index 9a9ae8e35f8..869688553b9 100644 --- a/NOTICE.txt +++ b/NOTICE.txt @@ -7986,11 +7986,11 @@ Contents of probable licence file $GOMODCACHE/github.com/elastic/go-sysinfo@v1.7 -------------------------------------------------------------------------------- Dependency : github.com/elastic/go-txfile -Version: v0.0.7 +Version: v0.0.8 Licence type (autodetected): Apache-2.0 -------------------------------------------------------------------------------- -Contents of probable licence file $GOMODCACHE/github.com/elastic/go-txfile@v0.0.7/LICENSE: +Contents of probable licence file $GOMODCACHE/github.com/elastic/go-txfile@v0.0.8/LICENSE: Apache License Version 2.0, January 2004 @@ -9655,13 +9655,13 @@ END OF TERMS AND CONDITIONS -------------------------------------------------------------------------------- Dependency : github.com/gofrs/flock -Version: v0.7.2-0.20190320160742-5135e617513b +Version: v0.8.1 Licence type (autodetected): BSD-3-Clause -------------------------------------------------------------------------------- -Contents of probable licence file $GOMODCACHE/github.com/gofrs/flock@v0.7.2-0.20190320160742-5135e617513b/LICENSE: +Contents of probable licence file $GOMODCACHE/github.com/gofrs/flock@v0.8.1/LICENSE: -Copyright (c) 2015, Tim Heckman +Copyright (c) 2015-2020, Tim Heckman All rights reserved. Redistribution and use in source and binary forms, with or without @@ -9674,9 +9674,9 @@ modification, are permitted provided that the following conditions are met: this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. -* Neither the name of linode-netint nor the names of its - contributors may be used to endorse or promote products derived from - this software without specific prior written permission. +* Neither the name of gofrs nor the names of its contributors may be used + to endorse or promote products derived from this software without + specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE @@ -12753,11 +12753,11 @@ freely, subject to the following restrictions: -------------------------------------------------------------------------------- Dependency : github.com/lib/pq -Version: v1.1.2-0.20190507191818-2ff3cb3adc01 +Version: v1.10.3 Licence type (autodetected): MIT -------------------------------------------------------------------------------- -Contents of probable licence file $GOMODCACHE/github.com/lib/pq@v1.1.2-0.20190507191818-2ff3cb3adc01/LICENSE.md: +Contents of probable licence file $GOMODCACHE/github.com/lib/pq@v1.10.3/LICENSE.md: Copyright (c) 2011-2013, 'pq' Contributors Portions Copyright (C) 2011 Blake Mizerany @@ -17222,11 +17222,11 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -------------------------------------------------------------------------------- Dependency : golang.org/x/sys -Version: v0.0.0-20210630005230-0f9fa26af87c +Version: v0.0.0-20210910150752-751e447fb3d0 Licence type (autodetected): BSD-3-Clause -------------------------------------------------------------------------------- -Contents of probable licence file $GOMODCACHE/golang.org/x/sys@v0.0.0-20210630005230-0f9fa26af87c/LICENSE: +Contents of probable licence file $GOMODCACHE/golang.org/x/sys@v0.0.0-20210910150752-751e447fb3d0/LICENSE: Copyright (c) 2009 The Go Authors. All rights reserved. @@ -40597,11 +40597,214 @@ Contents of probable licence file $GOMODCACHE/github.com/urso/go-bin@v0.0.0-2018 -------------------------------------------------------------------------------- Dependency : github.com/urso/magetools -Version: v0.0.0-20190919040553-290c89e0c230 +Version: v0.0.0-20200125210132-c2e338f92f3a Licence type (autodetected): Apache-2.0 -------------------------------------------------------------------------------- -No licence file provided. +Contents of probable licence file $GOMODCACHE/github.com/urso/magetools@v0.0.0-20200125210132-c2e338f92f3a/LICENSE: + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed 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. + -------------------------------------------------------------------------------- Dependency : github.com/urso/qcgen diff --git a/go.sum b/go.sum index f436e891d71..b14aff282f4 100644 --- a/go.sum +++ b/go.sum @@ -273,8 +273,6 @@ github.com/elastic/go-structform v0.0.9/go.mod h1:CZWf9aIRYY5SuKSmOhtXScE5uQiLZN github.com/elastic/go-sysinfo v1.1.1/go.mod h1:i1ZYdU10oLNfRzq4vq62BEwD2fH8KaWh6eh0ikPT9F0= github.com/elastic/go-sysinfo v1.7.0 h1:4vVvcfi255+8+TyQ7TYUTEK3A+G8v5FLE+ZKYL1z1Dg= github.com/elastic/go-sysinfo v1.7.0/go.mod h1:i1ZYdU10oLNfRzq4vq62BEwD2fH8KaWh6eh0ikPT9F0= -github.com/elastic/go-txfile v0.0.7 h1:Yn28gclW7X0Qy09nSMSsx0uOAvAGMsp6XHydbiLVe2s= -github.com/elastic/go-txfile v0.0.7/go.mod h1:H0nCoFae0a4ga57apgxFsgmRjevNCsEaT6g56JoeKAE= github.com/elastic/go-txfile v0.0.8 h1:hqFMmLM+UCDMJeSyuCWe8YwS+HtoX7F+cz5fhPYRTn4= github.com/elastic/go-txfile v0.0.8/go.mod h1:H0nCoFae0a4ga57apgxFsgmRjevNCsEaT6g56JoeKAE= github.com/elastic/go-ucfg v0.7.0/go.mod h1:iaiY0NBIYeasNgycLyTvhJftQlQEUO2hpF+FX0JKxzo= @@ -341,8 +339,6 @@ github.com/godbus/dbus/v5 v5.0.3/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5x github.com/godror/godror v0.10.4 h1:44FcfzDPp/PJZzen5Hm59SZQBhgrbR6E1KwCjg6gnJo= github.com/godror/godror v0.10.4/go.mod h1:9MVLtu25FBJBMHkPs0m3Ngf/VmwGcLpM2HS8PlNGw9U= github.com/gofrs/flock v0.7.1/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU= -github.com/gofrs/flock v0.7.2-0.20190320160742-5135e617513b h1:3QNh5Xo2pmr2nZXENtnztfpjej8XY8EPmvYxF5SzY9M= -github.com/gofrs/flock v0.7.2-0.20190320160742-5135e617513b/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU= github.com/gofrs/flock v0.8.1 h1:+gYjHKf32LDeiEEFhQaotPbLuUXjY5ZqxKgXy7n59aw= github.com/gofrs/flock v0.8.1/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU= github.com/gofrs/uuid v3.3.0+incompatible h1:8K4tyRfvU1CYPgJsveYFQMhpFd/wXNM7iK6rR7UHz84= @@ -533,8 +529,6 @@ github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= github.com/lib/pq v1.0.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= -github.com/lib/pq v1.1.2-0.20190507191818-2ff3cb3adc01 h1:EPw7R3OAyxHBCyl0oqh3lUZqS5lu3KSxzzGasE0opXQ= -github.com/lib/pq v1.1.2-0.20190507191818-2ff3cb3adc01/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= github.com/lib/pq v1.10.3 h1:v9QZf2Sn6AmjXtQeFpdoq/eaNtYP6IN+7lcrygsIAtg= github.com/lib/pq v1.10.3/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= github.com/magefile/mage v1.9.0/go.mod h1:z5UZb/iS3GoOSn0JgWuiw7dxlurVYTu+/jHXqQg881A= @@ -744,7 +738,6 @@ github.com/urso/diag v0.0.0-20200210123136-21b3cc8eb797 h1:OHNw/6pXODJAB32NujjdQ github.com/urso/diag v0.0.0-20200210123136-21b3cc8eb797/go.mod h1:pNWFTeQ+V1OYT/TzWpnWb6eQBdoXpdx+H+lrH97/Oyo= github.com/urso/go-bin v0.0.0-20180220135811-781c575c9f0e h1:NiofbjIUI5gR+ybDsGSVH1fWyjSeDYiYVJHT1+kcsak= github.com/urso/go-bin v0.0.0-20180220135811-781c575c9f0e/go.mod h1:6GfHrdWBQYjFRIznu7XuQH4lYB2w8nO4bnImVKkzPOM= -github.com/urso/magetools v0.0.0-20190919040553-290c89e0c230 h1:Ft1EJ6JL0F/RV6o2qJ1Be+wYxjYUSfRA3srfHgSgojc= github.com/urso/magetools v0.0.0-20190919040553-290c89e0c230/go.mod h1:DFxTNgS/ExCGmmjVjSOgS2WjtfjKXgCyDzAFgbtovSA= github.com/urso/magetools v0.0.0-20200125210132-c2e338f92f3a h1:jWAaRFnay3H2e6S0GGCl5nKrkgQNlarCE/kvcutzBmw= github.com/urso/magetools v0.0.0-20200125210132-c2e338f92f3a/go.mod h1:DbaJnRzkGaWrMWm5Hz6QVnUj//x9/zjrfx8bF3J+GJY= @@ -926,8 +919,6 @@ golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210603125802-9665404d3644/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c h1:F1jZWGFhYfh0Ci55sIpILtKKK8p3i2/krTr0H1rg74I= -golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210910150752-751e447fb3d0 h1:xrCZDmdtoloIiooiA9q0OQb9r8HejIHYoHGhGCe1pGg= golang.org/x/sys v0.0.0-20210910150752-751e447fb3d0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1 h1:v+OssWQX+hTHEmOBgwxdZxK4zHq3yOs8F9J7mk0PY8E= From 44f3c322b7f2fb56ebf08ac20b66e72b2e11fa34 Mon Sep 17 00:00:00 2001 From: Alex Kristiansen Date: Wed, 15 Sep 2021 16:51:58 -0500 Subject: [PATCH 03/20] format libbeat files --- libbeat/metric/system/diskio/doc.go | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/libbeat/metric/system/diskio/doc.go b/libbeat/metric/system/diskio/doc.go index 3463e97e208..53b3bc0ecf5 100644 --- a/libbeat/metric/system/diskio/doc.go +++ b/libbeat/metric/system/diskio/doc.go @@ -1 +1,18 @@ +// 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 diskio From b42ae68a73fb777abb5a841a271c35fd34e925a3 Mon Sep 17 00:00:00 2001 From: Alex Kristiansen Date: Wed, 15 Sep 2021 16:13:40 -0700 Subject: [PATCH 04/20] fix newer pgsql lib quoting --- .../module/postgresql/postgresql_test.go | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/metricbeat/module/postgresql/postgresql_test.go b/metricbeat/module/postgresql/postgresql_test.go index 85e3c7a332e..ea9e2d928fd 100644 --- a/metricbeat/module/postgresql/postgresql_test.go +++ b/metricbeat/module/postgresql/postgresql_test.go @@ -38,42 +38,42 @@ func TestParseUrl(t *testing.T) { { Name: "simple test", URL: "postgres://host1:5432", - Expected: "host=host1 port=5432", + Expected: "host='host1' port='5432'", }, { Name: "no port", URL: "postgres://host1", - Expected: "host=host1", + Expected: "host='host1'", }, { Name: "user/pass in URL", URL: "postgres://user:pass@host1:5432", - Expected: "host=host1 password=pass port=5432 user=user", + Expected: "host='host1' password='pass' port='5432' user='user'", }, { Name: "user/pass in params", URL: "postgres://host1:5432", Username: "user", Password: "secret", - Expected: "host=host1 password=secret port=5432 user=user", + Expected: "host='host1' password='secret' port='5432' user='user'", }, { Name: "user/pass in URL take precedence", URL: "postgres://user1:pass@host1:5432", Username: "user", Password: "secret", - Expected: "host=host1 password=pass port=5432 user=user1", + Expected: "host='host1' password='pass' port='5432' user='user1'", }, { Name: "timeout no override", URL: "postgres://host1:5432?connect_timeout=2", - Expected: "connect_timeout=2 host=host1 port=5432", + Expected: "connect_timeout='2' host='host1' port='5432'", }, { Name: "timeout from param", URL: "postgres://host1:5432", Timeout: 3 * time.Second, - Expected: "connect_timeout=3 host=host1 port=5432", + Expected: "connect_timeout='3' host='host1' port='5432'", }, { Name: "user/pass in URL take precedence, and timeout override", @@ -81,12 +81,12 @@ func TestParseUrl(t *testing.T) { Username: "user", Password: "secret", Timeout: 3 * time.Second, - Expected: "connect_timeout=3 host=host1 password=pass port=5432 user=user1", + Expected: "connect_timeout='3' host='host1' password='pass' port='5432' user='user1'", }, { Name: "unix socket", URL: "postgresql:///dbname?host=/var/lib/postgresql", - Expected: "dbname=dbname host=/var/lib/postgresql", + Expected: "dbname='dbname' host='/var/lib/postgresql'", }, } From 5d7df0c5690b42add24ae6c60c78154c24ffd260 Mon Sep 17 00:00:00 2001 From: Alex Kristiansen Date: Thu, 16 Sep 2021 09:52:01 -0700 Subject: [PATCH 05/20] fix build tags --- metricbeat/module/linux/iostat/data.go | 2 -- 1 file changed, 2 deletions(-) diff --git a/metricbeat/module/linux/iostat/data.go b/metricbeat/module/linux/iostat/data.go index ada2ec706e0..4e546deaa34 100644 --- a/metricbeat/module/linux/iostat/data.go +++ b/metricbeat/module/linux/iostat/data.go @@ -15,8 +15,6 @@ // specific language governing permissions and limitations // under the License. -// +build linux - package iostat import ( From b7e644e19c8055cd815c1095fc72ac9b80698c12 Mon Sep 17 00:00:00 2001 From: Alex Kristiansen Date: Thu, 16 Sep 2021 10:11:44 -0700 Subject: [PATCH 06/20] try to move around docker stat files --- metricbeat/module/docker/docker.go | 9 --------- metricbeat/module/docker/stat.go | 32 ++++++++++++++++++++++++++++++ 2 files changed, 32 insertions(+), 9 deletions(-) create mode 100644 metricbeat/module/docker/stat.go diff --git a/metricbeat/module/docker/docker.go b/metricbeat/module/docker/docker.go index b4a7b91a1cf..f96bbd2334b 100644 --- a/metricbeat/module/docker/docker.go +++ b/metricbeat/module/docker/docker.go @@ -35,9 +35,6 @@ import ( "github.com/elastic/beats/v7/metricbeat/mb/parse" ) -// Select Docker API version -const dockerAPIVersion = "1.22" - // HostParser is a TCP host parser function for docker tcp host addresses var HostParser = parse.URLHostParserBuilder{DefaultScheme: "tcp"}.Build() @@ -61,12 +58,6 @@ func NewModule(base mb.BaseModule) (mb.Module, error) { return &base, nil } -// Stat contains container and statistics information -type Stat struct { - Container *types.Container - Stats types.StatsJSON -} - // NewDockerClient initializes and returns a new Docker client func NewDockerClient(endpoint string, config Config) (*client.Client, error) { var httpClient *http.Client diff --git a/metricbeat/module/docker/stat.go b/metricbeat/module/docker/stat.go new file mode 100644 index 00000000000..826d2c958f5 --- /dev/null +++ b/metricbeat/module/docker/stat.go @@ -0,0 +1,32 @@ +// 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 docker + +import "github.com/docker/docker/api/types" + +// Types don't need build constraints, unlike the docker.Client code, which is linux-only. +// Put this here for client code that's importing it on non-linux systems + +// Select Docker API version +const dockerAPIVersion = "1.22" + +// Stat contains container and statistics information +type Stat struct { + Container *types.Container + Stats types.StatsJSON +} From 46a7fe6aae265405ee62d17fc7307facc4968da5 Mon Sep 17 00:00:00 2001 From: Alex Kristiansen Date: Wed, 22 Sep 2021 15:07:17 -0500 Subject: [PATCH 07/20] add diskio targets --- libbeat/metric/system/diskio/diskstat.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libbeat/metric/system/diskio/diskstat.go b/libbeat/metric/system/diskio/diskstat.go index 3cea37c552a..a5aa8d3748e 100644 --- a/libbeat/metric/system/diskio/diskstat.go +++ b/libbeat/metric/system/diskio/diskstat.go @@ -15,7 +15,7 @@ // specific language governing permissions and limitations // under the License. -// +build darwin freebsd linux windows +// +build darwin freebsd linux windows aix package diskio From d3dd1fa7fc53251562a075727f5b05fc6c4a0971 Mon Sep 17 00:00:00 2001 From: Alex Kristiansen Date: Wed, 22 Sep 2021 19:43:06 -0500 Subject: [PATCH 08/20] remove cloudfoundry from aix --- x-pack/filebeat/input/cloudfoundry/input.go | 2 ++ x-pack/filebeat/input/cloudfoundry/v1.go | 2 ++ x-pack/filebeat/input/cloudfoundry/v2.go | 2 ++ x-pack/libbeat/common/cloudfoundry/cache_integration_test.go | 1 + .../add_cloudfoundry_metadata/add_cloudfoundry_metadata.go | 2 ++ .../add_cloudfoundry_metadata/add_cloudfoundry_metadata_test.go | 2 ++ x-pack/libbeat/processors/add_cloudfoundry_metadata/doc.go | 1 + x-pack/metricbeat/module/cloudfoundry/cloudfoundry.go | 2 ++ x-pack/metricbeat/module/cloudfoundry/container/container.go | 2 ++ .../module/cloudfoundry/container/container_integration_test.go | 1 + .../metricbeat/module/cloudfoundry/container/container_test.go | 1 + x-pack/metricbeat/module/cloudfoundry/container/doc.go | 1 + x-pack/metricbeat/module/cloudfoundry/counter/counter.go | 2 ++ .../module/cloudfoundry/counter/counter_integration_test.go | 1 + x-pack/metricbeat/module/cloudfoundry/counter/counter_test.go | 1 + x-pack/metricbeat/module/cloudfoundry/counter/doc.go | 1 + x-pack/metricbeat/module/cloudfoundry/hub.go | 2 ++ x-pack/metricbeat/module/cloudfoundry/mtest/config.go | 2 ++ x-pack/metricbeat/module/cloudfoundry/mtest/modulemock.go | 2 ++ x-pack/metricbeat/module/cloudfoundry/v1.go | 2 ++ x-pack/metricbeat/module/cloudfoundry/v1_test.go | 2 ++ x-pack/metricbeat/module/cloudfoundry/v2.go | 2 ++ x-pack/metricbeat/module/cloudfoundry/value/doc.go | 1 + x-pack/metricbeat/module/cloudfoundry/value/value.go | 2 ++ .../module/cloudfoundry/value/value_integration_test.go | 1 + x-pack/metricbeat/module/cloudfoundry/value/value_test.go | 1 + 26 files changed, 41 insertions(+) create mode 100644 x-pack/libbeat/processors/add_cloudfoundry_metadata/doc.go create mode 100644 x-pack/metricbeat/module/cloudfoundry/container/doc.go create mode 100644 x-pack/metricbeat/module/cloudfoundry/counter/doc.go create mode 100644 x-pack/metricbeat/module/cloudfoundry/value/doc.go diff --git a/x-pack/filebeat/input/cloudfoundry/input.go b/x-pack/filebeat/input/cloudfoundry/input.go index 3d2b9b34e59..95f070967a7 100644 --- a/x-pack/filebeat/input/cloudfoundry/input.go +++ b/x-pack/filebeat/input/cloudfoundry/input.go @@ -2,6 +2,8 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix + package cloudfoundry import ( diff --git a/x-pack/filebeat/input/cloudfoundry/v1.go b/x-pack/filebeat/input/cloudfoundry/v1.go index 100fb944319..fc12a14f431 100644 --- a/x-pack/filebeat/input/cloudfoundry/v1.go +++ b/x-pack/filebeat/input/cloudfoundry/v1.go @@ -2,6 +2,8 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix + package cloudfoundry import ( diff --git a/x-pack/filebeat/input/cloudfoundry/v2.go b/x-pack/filebeat/input/cloudfoundry/v2.go index a8257e29a76..11488dffa8e 100644 --- a/x-pack/filebeat/input/cloudfoundry/v2.go +++ b/x-pack/filebeat/input/cloudfoundry/v2.go @@ -2,6 +2,8 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix + package cloudfoundry import ( diff --git a/x-pack/libbeat/common/cloudfoundry/cache_integration_test.go b/x-pack/libbeat/common/cloudfoundry/cache_integration_test.go index f799cc0615f..7bd1c0b73d4 100644 --- a/x-pack/libbeat/common/cloudfoundry/cache_integration_test.go +++ b/x-pack/libbeat/common/cloudfoundry/cache_integration_test.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix // +build integration // +build cloudfoundry diff --git a/x-pack/libbeat/processors/add_cloudfoundry_metadata/add_cloudfoundry_metadata.go b/x-pack/libbeat/processors/add_cloudfoundry_metadata/add_cloudfoundry_metadata.go index 50f551af969..73180927599 100644 --- a/x-pack/libbeat/processors/add_cloudfoundry_metadata/add_cloudfoundry_metadata.go +++ b/x-pack/libbeat/processors/add_cloudfoundry_metadata/add_cloudfoundry_metadata.go @@ -2,6 +2,8 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix + package add_cloudfoundry_metadata import ( diff --git a/x-pack/libbeat/processors/add_cloudfoundry_metadata/add_cloudfoundry_metadata_test.go b/x-pack/libbeat/processors/add_cloudfoundry_metadata/add_cloudfoundry_metadata_test.go index 34fe866104d..f57c80e1d59 100644 --- a/x-pack/libbeat/processors/add_cloudfoundry_metadata/add_cloudfoundry_metadata_test.go +++ b/x-pack/libbeat/processors/add_cloudfoundry_metadata/add_cloudfoundry_metadata_test.go @@ -2,6 +2,8 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix + package add_cloudfoundry_metadata import ( diff --git a/x-pack/libbeat/processors/add_cloudfoundry_metadata/doc.go b/x-pack/libbeat/processors/add_cloudfoundry_metadata/doc.go new file mode 100644 index 00000000000..913b8fb1df9 --- /dev/null +++ b/x-pack/libbeat/processors/add_cloudfoundry_metadata/doc.go @@ -0,0 +1 @@ +package add_cloudfoundry_metadata diff --git a/x-pack/metricbeat/module/cloudfoundry/cloudfoundry.go b/x-pack/metricbeat/module/cloudfoundry/cloudfoundry.go index 1486c9b14c0..19f9db684d7 100644 --- a/x-pack/metricbeat/module/cloudfoundry/cloudfoundry.go +++ b/x-pack/metricbeat/module/cloudfoundry/cloudfoundry.go @@ -2,6 +2,8 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix + package cloudfoundry import ( diff --git a/x-pack/metricbeat/module/cloudfoundry/container/container.go b/x-pack/metricbeat/module/cloudfoundry/container/container.go index a6f8d18191e..6263e8a3a95 100644 --- a/x-pack/metricbeat/module/cloudfoundry/container/container.go +++ b/x-pack/metricbeat/module/cloudfoundry/container/container.go @@ -2,6 +2,8 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix + package container import ( diff --git a/x-pack/metricbeat/module/cloudfoundry/container/container_integration_test.go b/x-pack/metricbeat/module/cloudfoundry/container/container_integration_test.go index 605f7145f64..12106fd9250 100644 --- a/x-pack/metricbeat/module/cloudfoundry/container/container_integration_test.go +++ b/x-pack/metricbeat/module/cloudfoundry/container/container_integration_test.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix // +build integration // +build cloudfoundry diff --git a/x-pack/metricbeat/module/cloudfoundry/container/container_test.go b/x-pack/metricbeat/module/cloudfoundry/container/container_test.go index ceabb62cc01..750d5e90944 100644 --- a/x-pack/metricbeat/module/cloudfoundry/container/container_test.go +++ b/x-pack/metricbeat/module/cloudfoundry/container/container_test.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix // +build !integration package container diff --git a/x-pack/metricbeat/module/cloudfoundry/container/doc.go b/x-pack/metricbeat/module/cloudfoundry/container/doc.go new file mode 100644 index 00000000000..92b957153de --- /dev/null +++ b/x-pack/metricbeat/module/cloudfoundry/container/doc.go @@ -0,0 +1 @@ +package container diff --git a/x-pack/metricbeat/module/cloudfoundry/counter/counter.go b/x-pack/metricbeat/module/cloudfoundry/counter/counter.go index 53d3833d810..a2bad03b7bd 100644 --- a/x-pack/metricbeat/module/cloudfoundry/counter/counter.go +++ b/x-pack/metricbeat/module/cloudfoundry/counter/counter.go @@ -2,6 +2,8 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix + package counter import ( diff --git a/x-pack/metricbeat/module/cloudfoundry/counter/counter_integration_test.go b/x-pack/metricbeat/module/cloudfoundry/counter/counter_integration_test.go index f7c13b1a603..ac17f06ee8d 100644 --- a/x-pack/metricbeat/module/cloudfoundry/counter/counter_integration_test.go +++ b/x-pack/metricbeat/module/cloudfoundry/counter/counter_integration_test.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix // +build integration // +build cloudfoundry diff --git a/x-pack/metricbeat/module/cloudfoundry/counter/counter_test.go b/x-pack/metricbeat/module/cloudfoundry/counter/counter_test.go index a315709878e..b35f4313e36 100644 --- a/x-pack/metricbeat/module/cloudfoundry/counter/counter_test.go +++ b/x-pack/metricbeat/module/cloudfoundry/counter/counter_test.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix // +build !integration package counter diff --git a/x-pack/metricbeat/module/cloudfoundry/counter/doc.go b/x-pack/metricbeat/module/cloudfoundry/counter/doc.go new file mode 100644 index 00000000000..ce35c8c4f7c --- /dev/null +++ b/x-pack/metricbeat/module/cloudfoundry/counter/doc.go @@ -0,0 +1 @@ +package counter diff --git a/x-pack/metricbeat/module/cloudfoundry/hub.go b/x-pack/metricbeat/module/cloudfoundry/hub.go index 5057a7bdbc5..aa046ce7c0e 100644 --- a/x-pack/metricbeat/module/cloudfoundry/hub.go +++ b/x-pack/metricbeat/module/cloudfoundry/hub.go @@ -2,6 +2,8 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix + package cloudfoundry import ( diff --git a/x-pack/metricbeat/module/cloudfoundry/mtest/config.go b/x-pack/metricbeat/module/cloudfoundry/mtest/config.go index 8f98d528f58..b33ba0fb208 100644 --- a/x-pack/metricbeat/module/cloudfoundry/mtest/config.go +++ b/x-pack/metricbeat/module/cloudfoundry/mtest/config.go @@ -2,6 +2,8 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix + package mtest import ( diff --git a/x-pack/metricbeat/module/cloudfoundry/mtest/modulemock.go b/x-pack/metricbeat/module/cloudfoundry/mtest/modulemock.go index 22b5260fd66..0dd5f095bb4 100644 --- a/x-pack/metricbeat/module/cloudfoundry/mtest/modulemock.go +++ b/x-pack/metricbeat/module/cloudfoundry/mtest/modulemock.go @@ -2,6 +2,8 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix + package mtest import ( diff --git a/x-pack/metricbeat/module/cloudfoundry/v1.go b/x-pack/metricbeat/module/cloudfoundry/v1.go index 8ad2e1e6e2a..df94be07509 100644 --- a/x-pack/metricbeat/module/cloudfoundry/v1.go +++ b/x-pack/metricbeat/module/cloudfoundry/v1.go @@ -2,6 +2,8 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix + package cloudfoundry import ( diff --git a/x-pack/metricbeat/module/cloudfoundry/v1_test.go b/x-pack/metricbeat/module/cloudfoundry/v1_test.go index b30952a9189..6ac96ef7297 100644 --- a/x-pack/metricbeat/module/cloudfoundry/v1_test.go +++ b/x-pack/metricbeat/module/cloudfoundry/v1_test.go @@ -2,6 +2,8 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix + package cloudfoundry import ( diff --git a/x-pack/metricbeat/module/cloudfoundry/v2.go b/x-pack/metricbeat/module/cloudfoundry/v2.go index d2987f3c401..01fa9ec3394 100644 --- a/x-pack/metricbeat/module/cloudfoundry/v2.go +++ b/x-pack/metricbeat/module/cloudfoundry/v2.go @@ -2,6 +2,8 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix + package cloudfoundry import ( diff --git a/x-pack/metricbeat/module/cloudfoundry/value/doc.go b/x-pack/metricbeat/module/cloudfoundry/value/doc.go new file mode 100644 index 00000000000..df8a848d9ae --- /dev/null +++ b/x-pack/metricbeat/module/cloudfoundry/value/doc.go @@ -0,0 +1 @@ +package value diff --git a/x-pack/metricbeat/module/cloudfoundry/value/value.go b/x-pack/metricbeat/module/cloudfoundry/value/value.go index 62fb02f5e39..c874a5004de 100644 --- a/x-pack/metricbeat/module/cloudfoundry/value/value.go +++ b/x-pack/metricbeat/module/cloudfoundry/value/value.go @@ -2,6 +2,8 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix + package value import ( diff --git a/x-pack/metricbeat/module/cloudfoundry/value/value_integration_test.go b/x-pack/metricbeat/module/cloudfoundry/value/value_integration_test.go index af815a3d4b7..0ad2062b6b9 100644 --- a/x-pack/metricbeat/module/cloudfoundry/value/value_integration_test.go +++ b/x-pack/metricbeat/module/cloudfoundry/value/value_integration_test.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix // +build integration // +build cloudfoundry diff --git a/x-pack/metricbeat/module/cloudfoundry/value/value_test.go b/x-pack/metricbeat/module/cloudfoundry/value/value_test.go index 2003388e228..0a910620383 100644 --- a/x-pack/metricbeat/module/cloudfoundry/value/value_test.go +++ b/x-pack/metricbeat/module/cloudfoundry/value/value_test.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix // +build !integration package value From 266aa3a519c46ecfb80775b999528fc4b80e7773 Mon Sep 17 00:00:00 2001 From: Alex Kristiansen Date: Thu, 23 Sep 2021 11:05:44 -0500 Subject: [PATCH 09/20] forgot formatting, again --- x-pack/libbeat/processors/add_cloudfoundry_metadata/doc.go | 4 ++++ x-pack/metricbeat/module/cloudfoundry/container/doc.go | 4 ++++ x-pack/metricbeat/module/cloudfoundry/counter/doc.go | 4 ++++ x-pack/metricbeat/module/cloudfoundry/value/doc.go | 4 ++++ 4 files changed, 16 insertions(+) diff --git a/x-pack/libbeat/processors/add_cloudfoundry_metadata/doc.go b/x-pack/libbeat/processors/add_cloudfoundry_metadata/doc.go index 913b8fb1df9..af83eda43f0 100644 --- a/x-pack/libbeat/processors/add_cloudfoundry_metadata/doc.go +++ b/x-pack/libbeat/processors/add_cloudfoundry_metadata/doc.go @@ -1 +1,5 @@ +// Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one +// or more contributor license agreements. Licensed under the Elastic License; +// you may not use this file except in compliance with the Elastic License. + package add_cloudfoundry_metadata diff --git a/x-pack/metricbeat/module/cloudfoundry/container/doc.go b/x-pack/metricbeat/module/cloudfoundry/container/doc.go index 92b957153de..3551ddfa76c 100644 --- a/x-pack/metricbeat/module/cloudfoundry/container/doc.go +++ b/x-pack/metricbeat/module/cloudfoundry/container/doc.go @@ -1 +1,5 @@ +// Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one +// or more contributor license agreements. Licensed under the Elastic License; +// you may not use this file except in compliance with the Elastic License. + package container diff --git a/x-pack/metricbeat/module/cloudfoundry/counter/doc.go b/x-pack/metricbeat/module/cloudfoundry/counter/doc.go index ce35c8c4f7c..d61d1e47b82 100644 --- a/x-pack/metricbeat/module/cloudfoundry/counter/doc.go +++ b/x-pack/metricbeat/module/cloudfoundry/counter/doc.go @@ -1 +1,5 @@ +// Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one +// or more contributor license agreements. Licensed under the Elastic License; +// you may not use this file except in compliance with the Elastic License. + package counter diff --git a/x-pack/metricbeat/module/cloudfoundry/value/doc.go b/x-pack/metricbeat/module/cloudfoundry/value/doc.go index df8a848d9ae..b69492763d6 100644 --- a/x-pack/metricbeat/module/cloudfoundry/value/doc.go +++ b/x-pack/metricbeat/module/cloudfoundry/value/doc.go @@ -1 +1,5 @@ +// Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one +// or more contributor license agreements. Licensed under the Elastic License; +// you may not use this file except in compliance with the Elastic License. + package value From e8825b98180576a50391d7ce12900beb6b313b16 Mon Sep 17 00:00:00 2001 From: Alex Kristiansen Date: Thu, 23 Sep 2021 17:22:47 -0500 Subject: [PATCH 10/20] get filebeat to build --- filebeat/autodiscover/defaults.go | 2 ++ libbeat/autodiscover/providers/docker/doc.go | 1 + .../autodiscover/providers/kubernetes/doc.go | 1 + .../autodiscover/providers/kubernetes/node.go | 2 ++ .../autodiscover/providers/kubernetes/pod.go | 2 ++ .../providers/kubernetes/service.go | 2 ++ .../statestore/backend/memlog/util_other.go | 2 +- .../azureeventhub_integration_test.go | 1 + x-pack/filebeat/input/azureeventhub/config.go | 2 ++ .../input/azureeventhub/config_test.go | 2 ++ x-pack/filebeat/input/azureeventhub/doc.go | 5 ++++ x-pack/filebeat/input/azureeventhub/eph.go | 2 ++ .../filebeat/input/azureeventhub/eph_test.go | 2 ++ .../azureeventhub/file_persister_test.go | 2 ++ x-pack/filebeat/input/azureeventhub/input.go | 2 ++ .../input/azureeventhub/input_test.go | 2 ++ x-pack/filebeat/input/cloudfoundry/doc.go | 5 ++++ .../filebeat/input/default-inputs/inputs.go | 15 ---------- .../input/default-inputs/inputs_aix.go | 25 ++++++++++++++++ .../input/default-inputs/inputs_other.go | 29 +++++++++++++++++++ 20 files changed, 90 insertions(+), 16 deletions(-) create mode 100644 libbeat/autodiscover/providers/docker/doc.go create mode 100644 libbeat/autodiscover/providers/kubernetes/doc.go create mode 100644 x-pack/filebeat/input/azureeventhub/doc.go create mode 100644 x-pack/filebeat/input/cloudfoundry/doc.go create mode 100644 x-pack/filebeat/input/default-inputs/inputs_aix.go create mode 100644 x-pack/filebeat/input/default-inputs/inputs_other.go diff --git a/filebeat/autodiscover/defaults.go b/filebeat/autodiscover/defaults.go index 701241ba625..945e210aaf5 100644 --- a/filebeat/autodiscover/defaults.go +++ b/filebeat/autodiscover/defaults.go @@ -15,6 +15,8 @@ // specific language governing permissions and limitations // under the License. +// +build !aix + package autodiscover import ( diff --git a/libbeat/autodiscover/providers/docker/doc.go b/libbeat/autodiscover/providers/docker/doc.go new file mode 100644 index 00000000000..1cdc3ff9108 --- /dev/null +++ b/libbeat/autodiscover/providers/docker/doc.go @@ -0,0 +1 @@ +package docker diff --git a/libbeat/autodiscover/providers/kubernetes/doc.go b/libbeat/autodiscover/providers/kubernetes/doc.go new file mode 100644 index 00000000000..276009a41a6 --- /dev/null +++ b/libbeat/autodiscover/providers/kubernetes/doc.go @@ -0,0 +1 @@ +package kubernetes diff --git a/libbeat/autodiscover/providers/kubernetes/node.go b/libbeat/autodiscover/providers/kubernetes/node.go index 728370f248a..b244c55d519 100644 --- a/libbeat/autodiscover/providers/kubernetes/node.go +++ b/libbeat/autodiscover/providers/kubernetes/node.go @@ -15,6 +15,8 @@ // specific language governing permissions and limitations // under the License. +// +build !aix + package kubernetes import ( diff --git a/libbeat/autodiscover/providers/kubernetes/pod.go b/libbeat/autodiscover/providers/kubernetes/pod.go index de63c3925e2..a4c5dc19b32 100644 --- a/libbeat/autodiscover/providers/kubernetes/pod.go +++ b/libbeat/autodiscover/providers/kubernetes/pod.go @@ -15,6 +15,8 @@ // specific language governing permissions and limitations // under the License. +// +build !aix + package kubernetes import ( diff --git a/libbeat/autodiscover/providers/kubernetes/service.go b/libbeat/autodiscover/providers/kubernetes/service.go index 3def44028bf..190e7997ed6 100644 --- a/libbeat/autodiscover/providers/kubernetes/service.go +++ b/libbeat/autodiscover/providers/kubernetes/service.go @@ -15,6 +15,8 @@ // specific language governing permissions and limitations // under the License. +// +build !aix + package kubernetes import ( diff --git a/libbeat/statestore/backend/memlog/util_other.go b/libbeat/statestore/backend/memlog/util_other.go index f975924853a..d5e60e8c7d5 100644 --- a/libbeat/statestore/backend/memlog/util_other.go +++ b/libbeat/statestore/backend/memlog/util_other.go @@ -15,7 +15,7 @@ // specific language governing permissions and limitations // under the License. -// +build linux dragonfly freebsd netbsd openbsd solaris +// +build linux dragonfly freebsd netbsd openbsd solaris aix package memlog diff --git a/x-pack/filebeat/input/azureeventhub/azureeventhub_integration_test.go b/x-pack/filebeat/input/azureeventhub/azureeventhub_integration_test.go index e14bb41a918..54f6543fc68 100644 --- a/x-pack/filebeat/input/azureeventhub/azureeventhub_integration_test.go +++ b/x-pack/filebeat/input/azureeventhub/azureeventhub_integration_test.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix // +build integration // +build azure diff --git a/x-pack/filebeat/input/azureeventhub/config.go b/x-pack/filebeat/input/azureeventhub/config.go index e24f3f2b0f6..e4f94dc92e5 100644 --- a/x-pack/filebeat/input/azureeventhub/config.go +++ b/x-pack/filebeat/input/azureeventhub/config.go @@ -2,6 +2,8 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix + package azureeventhub import ( diff --git a/x-pack/filebeat/input/azureeventhub/config_test.go b/x-pack/filebeat/input/azureeventhub/config_test.go index b6f264911d8..d001eeaf1ba 100644 --- a/x-pack/filebeat/input/azureeventhub/config_test.go +++ b/x-pack/filebeat/input/azureeventhub/config_test.go @@ -2,6 +2,8 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix + package azureeventhub import ( diff --git a/x-pack/filebeat/input/azureeventhub/doc.go b/x-pack/filebeat/input/azureeventhub/doc.go new file mode 100644 index 00000000000..e807f6a41c8 --- /dev/null +++ b/x-pack/filebeat/input/azureeventhub/doc.go @@ -0,0 +1,5 @@ +// Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one +// or more contributor license agreements. Licensed under the Elastic License; +// you may not use this file except in compliance with the Elastic License. + +package azureeventhub diff --git a/x-pack/filebeat/input/azureeventhub/eph.go b/x-pack/filebeat/input/azureeventhub/eph.go index 8fa976b6345..3020c17496c 100644 --- a/x-pack/filebeat/input/azureeventhub/eph.go +++ b/x-pack/filebeat/input/azureeventhub/eph.go @@ -2,6 +2,8 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix + package azureeventhub import ( diff --git a/x-pack/filebeat/input/azureeventhub/eph_test.go b/x-pack/filebeat/input/azureeventhub/eph_test.go index a803a29ebf1..89daa97ad3a 100644 --- a/x-pack/filebeat/input/azureeventhub/eph_test.go +++ b/x-pack/filebeat/input/azureeventhub/eph_test.go @@ -2,6 +2,8 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix + package azureeventhub import ( diff --git a/x-pack/filebeat/input/azureeventhub/file_persister_test.go b/x-pack/filebeat/input/azureeventhub/file_persister_test.go index ed055d75d3c..a354dd86520 100644 --- a/x-pack/filebeat/input/azureeventhub/file_persister_test.go +++ b/x-pack/filebeat/input/azureeventhub/file_persister_test.go @@ -2,6 +2,8 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix + package azureeventhub import ( diff --git a/x-pack/filebeat/input/azureeventhub/input.go b/x-pack/filebeat/input/azureeventhub/input.go index 5f0d1b3df5e..5799b83a24d 100644 --- a/x-pack/filebeat/input/azureeventhub/input.go +++ b/x-pack/filebeat/input/azureeventhub/input.go @@ -2,6 +2,8 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix + package azureeventhub import ( diff --git a/x-pack/filebeat/input/azureeventhub/input_test.go b/x-pack/filebeat/input/azureeventhub/input_test.go index d4268d9d96a..dc449df3bdb 100644 --- a/x-pack/filebeat/input/azureeventhub/input_test.go +++ b/x-pack/filebeat/input/azureeventhub/input_test.go @@ -2,6 +2,8 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +// +build !aix + package azureeventhub import ( diff --git a/x-pack/filebeat/input/cloudfoundry/doc.go b/x-pack/filebeat/input/cloudfoundry/doc.go new file mode 100644 index 00000000000..de397ce22eb --- /dev/null +++ b/x-pack/filebeat/input/cloudfoundry/doc.go @@ -0,0 +1,5 @@ +// Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one +// or more contributor license agreements. Licensed under the Elastic License; +// you may not use this file except in compliance with the Elastic License. + +package cloudfoundry diff --git a/x-pack/filebeat/input/default-inputs/inputs.go b/x-pack/filebeat/input/default-inputs/inputs.go index 7fc3737e37d..a426c65e530 100644 --- a/x-pack/filebeat/input/default-inputs/inputs.go +++ b/x-pack/filebeat/input/default-inputs/inputs.go @@ -10,11 +10,6 @@ import ( v2 "github.com/elastic/beats/v7/filebeat/input/v2" "github.com/elastic/beats/v7/libbeat/beat" "github.com/elastic/beats/v7/libbeat/logp" - "github.com/elastic/beats/v7/x-pack/filebeat/input/awss3" - "github.com/elastic/beats/v7/x-pack/filebeat/input/cloudfoundry" - "github.com/elastic/beats/v7/x-pack/filebeat/input/http_endpoint" - "github.com/elastic/beats/v7/x-pack/filebeat/input/httpjson" - "github.com/elastic/beats/v7/x-pack/filebeat/input/o365audit" ) func Init(info beat.Info, log *logp.Logger, store beater.StateStore) []v2.Plugin { @@ -23,13 +18,3 @@ func Init(info beat.Info, log *logp.Logger, store beater.StateStore) []v2.Plugin ossinputs.Init(info, log, store)..., ) } - -func xpackInputs(info beat.Info, log *logp.Logger, store beater.StateStore) []v2.Plugin { - return []v2.Plugin{ - cloudfoundry.Plugin(), - http_endpoint.Plugin(), - httpjson.Plugin(log, store), - o365audit.Plugin(log, store), - awss3.Plugin(store), - } -} diff --git a/x-pack/filebeat/input/default-inputs/inputs_aix.go b/x-pack/filebeat/input/default-inputs/inputs_aix.go new file mode 100644 index 00000000000..930c005b197 --- /dev/null +++ b/x-pack/filebeat/input/default-inputs/inputs_aix.go @@ -0,0 +1,25 @@ +// Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one +// or more contributor license agreements. Licensed under the Elastic License; +// you may not use this file except in compliance with the Elastic License. + +package inputs + +import ( + "github.com/elastic/beats/v7/filebeat/beater" + v2 "github.com/elastic/beats/v7/filebeat/input/v2" + "github.com/elastic/beats/v7/libbeat/beat" + "github.com/elastic/beats/v7/libbeat/logp" + "github.com/elastic/beats/v7/x-pack/filebeat/input/awss3" + "github.com/elastic/beats/v7/x-pack/filebeat/input/http_endpoint" + "github.com/elastic/beats/v7/x-pack/filebeat/input/httpjson" + "github.com/elastic/beats/v7/x-pack/filebeat/input/o365audit" +) + +func xpackInputs(info beat.Info, log *logp.Logger, store beater.StateStore) []v2.Plugin { + return []v2.Plugin{ + http_endpoint.Plugin(), + httpjson.Plugin(log, store), + o365audit.Plugin(log, store), + awss3.Plugin(store), + } +} diff --git a/x-pack/filebeat/input/default-inputs/inputs_other.go b/x-pack/filebeat/input/default-inputs/inputs_other.go new file mode 100644 index 00000000000..bad2a8e2578 --- /dev/null +++ b/x-pack/filebeat/input/default-inputs/inputs_other.go @@ -0,0 +1,29 @@ +// Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one +// or more contributor license agreements. Licensed under the Elastic License; +// you may not use this file except in compliance with the Elastic License. + +// +build !aix + +package inputs + +import ( + "github.com/elastic/beats/v7/filebeat/beater" + v2 "github.com/elastic/beats/v7/filebeat/input/v2" + "github.com/elastic/beats/v7/libbeat/beat" + "github.com/elastic/beats/v7/libbeat/logp" + "github.com/elastic/beats/v7/x-pack/filebeat/input/awss3" + "github.com/elastic/beats/v7/x-pack/filebeat/input/cloudfoundry" + "github.com/elastic/beats/v7/x-pack/filebeat/input/http_endpoint" + "github.com/elastic/beats/v7/x-pack/filebeat/input/httpjson" + "github.com/elastic/beats/v7/x-pack/filebeat/input/o365audit" +) + +func xpackInputs(info beat.Info, log *logp.Logger, store beater.StateStore) []v2.Plugin { + return []v2.Plugin{ + cloudfoundry.Plugin(), + http_endpoint.Plugin(), + httpjson.Plugin(log, store), + o365audit.Plugin(log, store), + awss3.Plugin(store), + } +} From 2c62f6f0c0af11c47c142d884bfbfbb3d26750db Mon Sep 17 00:00:00 2001 From: Alex Kristiansen Date: Mon, 27 Sep 2021 12:57:38 -0500 Subject: [PATCH 11/20] mage fmt --- libbeat/autodiscover/providers/docker/doc.go | 17 +++++++++++++++++ .../autodiscover/providers/kubernetes/doc.go | 17 +++++++++++++++++ .../composable/providers/kubernetes/config.go | 3 --- .../kubernetesleaderelection/config.go | 3 --- .../providers/kubernetessecrets/config.go | 3 --- .../osquerybeat/internal/action/action_test.go | 3 ++- x-pack/osquerybeat/internal/config/watcher.go | 3 ++- .../osquerybeat/internal/pub/publisher_test.go | 5 +++-- 8 files changed, 41 insertions(+), 13 deletions(-) diff --git a/libbeat/autodiscover/providers/docker/doc.go b/libbeat/autodiscover/providers/docker/doc.go index 1cdc3ff9108..252d2fdeaf1 100644 --- a/libbeat/autodiscover/providers/docker/doc.go +++ b/libbeat/autodiscover/providers/docker/doc.go @@ -1 +1,18 @@ +// 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 docker diff --git a/libbeat/autodiscover/providers/kubernetes/doc.go b/libbeat/autodiscover/providers/kubernetes/doc.go index 276009a41a6..ed7b00a5bc7 100644 --- a/libbeat/autodiscover/providers/kubernetes/doc.go +++ b/libbeat/autodiscover/providers/kubernetes/doc.go @@ -1 +1,18 @@ +// 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 kubernetes diff --git a/x-pack/elastic-agent/pkg/composable/providers/kubernetes/config.go b/x-pack/elastic-agent/pkg/composable/providers/kubernetes/config.go index 3d34db03a8b..4767d2d93cc 100644 --- a/x-pack/elastic-agent/pkg/composable/providers/kubernetes/config.go +++ b/x-pack/elastic-agent/pkg/composable/providers/kubernetes/config.go @@ -2,9 +2,6 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. -// TODO review the need for this -// +build linux darwin windows - package kubernetes import ( diff --git a/x-pack/elastic-agent/pkg/composable/providers/kubernetesleaderelection/config.go b/x-pack/elastic-agent/pkg/composable/providers/kubernetesleaderelection/config.go index a7f71cc32b5..cc8ebd66fae 100644 --- a/x-pack/elastic-agent/pkg/composable/providers/kubernetesleaderelection/config.go +++ b/x-pack/elastic-agent/pkg/composable/providers/kubernetesleaderelection/config.go @@ -2,9 +2,6 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. -// TODO review the need for this -// +build linux darwin windows - package kubernetesleaderelection // Config for kubernetes_leaderelection provider diff --git a/x-pack/elastic-agent/pkg/composable/providers/kubernetessecrets/config.go b/x-pack/elastic-agent/pkg/composable/providers/kubernetessecrets/config.go index 29463db148a..c7947977ec4 100644 --- a/x-pack/elastic-agent/pkg/composable/providers/kubernetessecrets/config.go +++ b/x-pack/elastic-agent/pkg/composable/providers/kubernetessecrets/config.go @@ -2,9 +2,6 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. -// TODO review the need for this -// +build linux darwin windows - package kubernetessecrets // Config for kubernetes provider diff --git a/x-pack/osquerybeat/internal/action/action_test.go b/x-pack/osquerybeat/internal/action/action_test.go index c61b3053324..5e46316b327 100644 --- a/x-pack/osquerybeat/internal/action/action_test.go +++ b/x-pack/osquerybeat/internal/action/action_test.go @@ -8,8 +8,9 @@ import ( "errors" "testing" - "github.com/elastic/beats/v7/x-pack/osquerybeat/internal/ecs" "github.com/google/go-cmp/cmp" + + "github.com/elastic/beats/v7/x-pack/osquerybeat/internal/ecs" ) func TestActionFromMap(t *testing.T) { diff --git a/x-pack/osquerybeat/internal/config/watcher.go b/x-pack/osquerybeat/internal/config/watcher.go index 20d9ab417b1..df850677de4 100644 --- a/x-pack/osquerybeat/internal/config/watcher.go +++ b/x-pack/osquerybeat/internal/config/watcher.go @@ -7,9 +7,10 @@ package config import ( "context" + "k8s.io/apimachinery/pkg/util/json" + "github.com/elastic/beats/v7/libbeat/common/reload" "github.com/elastic/beats/v7/libbeat/logp" - "k8s.io/apimachinery/pkg/util/json" ) type reloader struct { diff --git a/x-pack/osquerybeat/internal/pub/publisher_test.go b/x-pack/osquerybeat/internal/pub/publisher_test.go index 45dfbdbc534..3aadea3d23b 100644 --- a/x-pack/osquerybeat/internal/pub/publisher_test.go +++ b/x-pack/osquerybeat/internal/pub/publisher_test.go @@ -8,10 +8,11 @@ import ( "testing" "time" - "github.com/elastic/beats/v7/libbeat/beat/events" - "github.com/elastic/beats/v7/x-pack/osquerybeat/internal/ecs" "github.com/gofrs/uuid" "github.com/google/go-cmp/cmp" + + "github.com/elastic/beats/v7/libbeat/beat/events" + "github.com/elastic/beats/v7/x-pack/osquerybeat/internal/ecs" ) func TestHitToEvent(t *testing.T) { From 4ab670348a881d9976301e598116ad3be9389f6d Mon Sep 17 00:00:00 2001 From: Alex Kristiansen Date: Mon, 4 Oct 2021 11:20:19 -0700 Subject: [PATCH 12/20] fix bad import --- x-pack/osquerybeat/internal/config/watcher.go | 2 -- 1 file changed, 2 deletions(-) diff --git a/x-pack/osquerybeat/internal/config/watcher.go b/x-pack/osquerybeat/internal/config/watcher.go index 77ceec59988..6b91d85baef 100644 --- a/x-pack/osquerybeat/internal/config/watcher.go +++ b/x-pack/osquerybeat/internal/config/watcher.go @@ -8,8 +8,6 @@ import ( "context" "encoding/json" - "k8s.io/apimachinery/pkg/util/json" - "github.com/elastic/beats/v7/libbeat/common/reload" "github.com/elastic/beats/v7/libbeat/logp" ) From b5b28687dfc7910c69033f504ae081422affaadc Mon Sep 17 00:00:00 2001 From: Alex Kristiansen Date: Tue, 5 Oct 2021 10:09:36 -0700 Subject: [PATCH 13/20] fix merge --- NOTICE.txt | 4 ++-- go.mod | 6 ------ go.sum | 4 ++-- 3 files changed, 4 insertions(+), 10 deletions(-) diff --git a/NOTICE.txt b/NOTICE.txt index 08e96c25509..e037105cd6b 100644 --- a/NOTICE.txt +++ b/NOTICE.txt @@ -17264,11 +17264,11 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -------------------------------------------------------------------------------- Dependency : golang.org/x/sys -Version: v0.0.0-20210910150752-751e447fb3d0 +Version: v0.0.0-20210630005230-0f9fa26af87c Licence type (autodetected): BSD-3-Clause -------------------------------------------------------------------------------- -Contents of probable licence file $GOMODCACHE/golang.org/x/sys@v0.0.0-20210910150752-751e447fb3d0/LICENSE: +Contents of probable licence file $GOMODCACHE/golang.org/x/sys@v0.0.0-20210630005230-0f9fa26af87c/LICENSE: Copyright (c) 2009 The Go Authors. All rights reserved. diff --git a/go.mod b/go.mod index 52503b32797..864509aa22d 100644 --- a/go.mod +++ b/go.mod @@ -171,15 +171,9 @@ require ( golang.org/x/crypto v0.0.0-20210616213533-5ff15b29337e golang.org/x/lint v0.0.0-20210508222113-6edffad5e616 golang.org/x/net v0.0.0-20210614182718-04defd469f4e -<<<<<<< HEAD - golang.org/x/oauth2 v0.0.0-20200107190931-bf48bf16ab8d - golang.org/x/sync v0.0.0-20200317015054-43a5402ce75a - golang.org/x/sys v0.0.0-20210910150752-751e447fb3d0 -======= golang.org/x/oauth2 v0.0.0-20210514164344-f6687ab2804c golang.org/x/sync v0.0.0-20210220032951-036812b2e83c golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c ->>>>>>> upstream/master golang.org/x/text v0.3.6 golang.org/x/time v0.0.0-20191024005414-555d28b269f0 golang.org/x/tools v0.1.2 diff --git a/go.sum b/go.sum index 102843b3fee..85e49fff802 100644 --- a/go.sum +++ b/go.sum @@ -1048,8 +1048,8 @@ golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210514084401-e8d321eab015/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210603125802-9665404d3644/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210910150752-751e447fb3d0 h1:xrCZDmdtoloIiooiA9q0OQb9r8HejIHYoHGhGCe1pGg= -golang.org/x/sys v0.0.0-20210910150752-751e447fb3d0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c h1:F1jZWGFhYfh0Ci55sIpILtKKK8p3i2/krTr0H1rg74I= +golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1 h1:v+OssWQX+hTHEmOBgwxdZxK4zHq3yOs8F9J7mk0PY8E= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= From af73e59251269e4797470c807881281e2ff9aede Mon Sep 17 00:00:00 2001 From: Alex Kristiansen Date: Thu, 7 Oct 2021 09:40:40 -0700 Subject: [PATCH 14/20] changelog --- CHANGELOG.next.asciidoc | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.next.asciidoc b/CHANGELOG.next.asciidoc index 1aa74ca99a3..bc8f4b3e4a7 100644 --- a/CHANGELOG.next.asciidoc +++ b/CHANGELOG.next.asciidoc @@ -871,6 +871,7 @@ https://github.com/elastic/beats/compare/v7.0.0-alpha2...master[Check the HEAD d - Move openmetrics module to oss. {pull}26561[26561] - Add `gke` metricset collection to `gcp` module {pull}26824[26824] - Added a new beta `enterprisesearch` module for Elastic Enterprise Search {pull}27549[27549] +- Preliminary AIX support {pull}27954[27954] *Packetbeat* From e5736ca9aedd70666d2d4be6203d84f0e71620eb Mon Sep 17 00:00:00 2001 From: Alex Kristiansen Date: Mon, 11 Oct 2021 11:17:24 -0700 Subject: [PATCH 15/20] fmt --- libbeat/autodiscover/providers/kubernetes/node.go | 1 + libbeat/autodiscover/providers/kubernetes/pod.go | 1 + libbeat/autodiscover/providers/kubernetes/service.go | 1 + metricbeat/module/linux/iostat/iostat.go | 1 + x-pack/metricbeat/module/cloudfoundry/cloudfoundry.go | 1 + x-pack/metricbeat/module/cloudfoundry/container/container.go | 1 + x-pack/metricbeat/module/cloudfoundry/counter/counter.go | 1 + x-pack/metricbeat/module/cloudfoundry/hub.go | 1 + x-pack/metricbeat/module/cloudfoundry/mtest/config.go | 1 + x-pack/metricbeat/module/cloudfoundry/mtest/modulemock.go | 1 + x-pack/metricbeat/module/cloudfoundry/v1.go | 1 + x-pack/metricbeat/module/cloudfoundry/v1_test.go | 1 + x-pack/metricbeat/module/cloudfoundry/v2.go | 1 + x-pack/metricbeat/module/cloudfoundry/value/value.go | 1 + 14 files changed, 14 insertions(+) diff --git a/libbeat/autodiscover/providers/kubernetes/node.go b/libbeat/autodiscover/providers/kubernetes/node.go index b244c55d519..f52b9d9040d 100644 --- a/libbeat/autodiscover/providers/kubernetes/node.go +++ b/libbeat/autodiscover/providers/kubernetes/node.go @@ -15,6 +15,7 @@ // specific language governing permissions and limitations // under the License. +//go:build !aix // +build !aix package kubernetes diff --git a/libbeat/autodiscover/providers/kubernetes/pod.go b/libbeat/autodiscover/providers/kubernetes/pod.go index b5e78324046..e19f19b2ad1 100644 --- a/libbeat/autodiscover/providers/kubernetes/pod.go +++ b/libbeat/autodiscover/providers/kubernetes/pod.go @@ -15,6 +15,7 @@ // specific language governing permissions and limitations // under the License. +//go:build !aix // +build !aix package kubernetes diff --git a/libbeat/autodiscover/providers/kubernetes/service.go b/libbeat/autodiscover/providers/kubernetes/service.go index e66cf3b11e6..eec528a7df6 100644 --- a/libbeat/autodiscover/providers/kubernetes/service.go +++ b/libbeat/autodiscover/providers/kubernetes/service.go @@ -15,6 +15,7 @@ // specific language governing permissions and limitations // under the License. +//go:build !aix // +build !aix package kubernetes diff --git a/metricbeat/module/linux/iostat/iostat.go b/metricbeat/module/linux/iostat/iostat.go index c26bc4e01e1..9f40b260cbe 100644 --- a/metricbeat/module/linux/iostat/iostat.go +++ b/metricbeat/module/linux/iostat/iostat.go @@ -15,6 +15,7 @@ // specific language governing permissions and limitations // under the License. +//go:build linux // +build linux package iostat diff --git a/x-pack/metricbeat/module/cloudfoundry/cloudfoundry.go b/x-pack/metricbeat/module/cloudfoundry/cloudfoundry.go index 19f9db684d7..06fee26c16f 100644 --- a/x-pack/metricbeat/module/cloudfoundry/cloudfoundry.go +++ b/x-pack/metricbeat/module/cloudfoundry/cloudfoundry.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +//go:build !aix // +build !aix package cloudfoundry diff --git a/x-pack/metricbeat/module/cloudfoundry/container/container.go b/x-pack/metricbeat/module/cloudfoundry/container/container.go index 6263e8a3a95..5e6793556df 100644 --- a/x-pack/metricbeat/module/cloudfoundry/container/container.go +++ b/x-pack/metricbeat/module/cloudfoundry/container/container.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +//go:build !aix // +build !aix package container diff --git a/x-pack/metricbeat/module/cloudfoundry/counter/counter.go b/x-pack/metricbeat/module/cloudfoundry/counter/counter.go index a2bad03b7bd..5828a0ba1b7 100644 --- a/x-pack/metricbeat/module/cloudfoundry/counter/counter.go +++ b/x-pack/metricbeat/module/cloudfoundry/counter/counter.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +//go:build !aix // +build !aix package counter diff --git a/x-pack/metricbeat/module/cloudfoundry/hub.go b/x-pack/metricbeat/module/cloudfoundry/hub.go index aa046ce7c0e..13b593495a3 100644 --- a/x-pack/metricbeat/module/cloudfoundry/hub.go +++ b/x-pack/metricbeat/module/cloudfoundry/hub.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +//go:build !aix // +build !aix package cloudfoundry diff --git a/x-pack/metricbeat/module/cloudfoundry/mtest/config.go b/x-pack/metricbeat/module/cloudfoundry/mtest/config.go index b33ba0fb208..b93a57901dc 100644 --- a/x-pack/metricbeat/module/cloudfoundry/mtest/config.go +++ b/x-pack/metricbeat/module/cloudfoundry/mtest/config.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +//go:build !aix // +build !aix package mtest diff --git a/x-pack/metricbeat/module/cloudfoundry/mtest/modulemock.go b/x-pack/metricbeat/module/cloudfoundry/mtest/modulemock.go index 0dd5f095bb4..6662f5f547f 100644 --- a/x-pack/metricbeat/module/cloudfoundry/mtest/modulemock.go +++ b/x-pack/metricbeat/module/cloudfoundry/mtest/modulemock.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +//go:build !aix // +build !aix package mtest diff --git a/x-pack/metricbeat/module/cloudfoundry/v1.go b/x-pack/metricbeat/module/cloudfoundry/v1.go index df94be07509..b76ad1ad831 100644 --- a/x-pack/metricbeat/module/cloudfoundry/v1.go +++ b/x-pack/metricbeat/module/cloudfoundry/v1.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +//go:build !aix // +build !aix package cloudfoundry diff --git a/x-pack/metricbeat/module/cloudfoundry/v1_test.go b/x-pack/metricbeat/module/cloudfoundry/v1_test.go index 6ac96ef7297..17f315d287d 100644 --- a/x-pack/metricbeat/module/cloudfoundry/v1_test.go +++ b/x-pack/metricbeat/module/cloudfoundry/v1_test.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +//go:build !aix // +build !aix package cloudfoundry diff --git a/x-pack/metricbeat/module/cloudfoundry/v2.go b/x-pack/metricbeat/module/cloudfoundry/v2.go index 01fa9ec3394..7e35c2ddb7d 100644 --- a/x-pack/metricbeat/module/cloudfoundry/v2.go +++ b/x-pack/metricbeat/module/cloudfoundry/v2.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +//go:build !aix // +build !aix package cloudfoundry diff --git a/x-pack/metricbeat/module/cloudfoundry/value/value.go b/x-pack/metricbeat/module/cloudfoundry/value/value.go index c874a5004de..397fdafae37 100644 --- a/x-pack/metricbeat/module/cloudfoundry/value/value.go +++ b/x-pack/metricbeat/module/cloudfoundry/value/value.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +//go:build !aix // +build !aix package value From f23992334bf17ca06f6942c2d39eb59d6e6c642a Mon Sep 17 00:00:00 2001 From: Alex Kristiansen Date: Mon, 11 Oct 2021 11:54:18 -0700 Subject: [PATCH 16/20] fix filebeat --- filebeat/autodiscover/defaults.go | 1 + 1 file changed, 1 insertion(+) diff --git a/filebeat/autodiscover/defaults.go b/filebeat/autodiscover/defaults.go index 945e210aaf5..606bf042dc4 100644 --- a/filebeat/autodiscover/defaults.go +++ b/filebeat/autodiscover/defaults.go @@ -15,6 +15,7 @@ // specific language governing permissions and limitations // under the License. +//go:build !aix // +build !aix package autodiscover From 81f112e9ce0c2b0f7e5f8c48fb23e975d537f0b4 Mon Sep 17 00:00:00 2001 From: Alex Kristiansen Date: Mon, 11 Oct 2021 12:14:30 -0700 Subject: [PATCH 17/20] fix broken headers, again --- metricbeat/include/list_docker.go | 1 + x-pack/filebeat/input/azureeventhub/config.go | 1 + x-pack/filebeat/input/azureeventhub/config_test.go | 1 + x-pack/filebeat/input/azureeventhub/eph.go | 1 + x-pack/filebeat/input/azureeventhub/eph_test.go | 1 + x-pack/filebeat/input/azureeventhub/file_persister_test.go | 1 + x-pack/filebeat/input/azureeventhub/input.go | 1 + x-pack/filebeat/input/azureeventhub/input_test.go | 1 + x-pack/filebeat/input/cloudfoundry/input.go | 1 + x-pack/filebeat/input/cloudfoundry/v1.go | 1 + x-pack/filebeat/input/cloudfoundry/v2.go | 1 + x-pack/filebeat/input/default-inputs/inputs_other.go | 1 + .../add_cloudfoundry_metadata/add_cloudfoundry_metadata.go | 1 + .../add_cloudfoundry_metadata/add_cloudfoundry_metadata_test.go | 1 + 14 files changed, 14 insertions(+) diff --git a/metricbeat/include/list_docker.go b/metricbeat/include/list_docker.go index c2fc8197b90..1e8a7c494e7 100644 --- a/metricbeat/include/list_docker.go +++ b/metricbeat/include/list_docker.go @@ -17,6 +17,7 @@ // Code generated by beats/dev-tools/cmd/module_include_list/module_include_list.go - DO NOT EDIT. +//go:build linux || darwin || windows // +build linux darwin windows package include diff --git a/x-pack/filebeat/input/azureeventhub/config.go b/x-pack/filebeat/input/azureeventhub/config.go index e4f94dc92e5..354b2cfb0b5 100644 --- a/x-pack/filebeat/input/azureeventhub/config.go +++ b/x-pack/filebeat/input/azureeventhub/config.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +//go:build !aix // +build !aix package azureeventhub diff --git a/x-pack/filebeat/input/azureeventhub/config_test.go b/x-pack/filebeat/input/azureeventhub/config_test.go index d001eeaf1ba..8ba1b9f2aae 100644 --- a/x-pack/filebeat/input/azureeventhub/config_test.go +++ b/x-pack/filebeat/input/azureeventhub/config_test.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +//go:build !aix // +build !aix package azureeventhub diff --git a/x-pack/filebeat/input/azureeventhub/eph.go b/x-pack/filebeat/input/azureeventhub/eph.go index 3020c17496c..d9584952dbe 100644 --- a/x-pack/filebeat/input/azureeventhub/eph.go +++ b/x-pack/filebeat/input/azureeventhub/eph.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +//go:build !aix // +build !aix package azureeventhub diff --git a/x-pack/filebeat/input/azureeventhub/eph_test.go b/x-pack/filebeat/input/azureeventhub/eph_test.go index 89daa97ad3a..946e85c710a 100644 --- a/x-pack/filebeat/input/azureeventhub/eph_test.go +++ b/x-pack/filebeat/input/azureeventhub/eph_test.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +//go:build !aix // +build !aix package azureeventhub diff --git a/x-pack/filebeat/input/azureeventhub/file_persister_test.go b/x-pack/filebeat/input/azureeventhub/file_persister_test.go index a354dd86520..68aee200475 100644 --- a/x-pack/filebeat/input/azureeventhub/file_persister_test.go +++ b/x-pack/filebeat/input/azureeventhub/file_persister_test.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +//go:build !aix // +build !aix package azureeventhub diff --git a/x-pack/filebeat/input/azureeventhub/input.go b/x-pack/filebeat/input/azureeventhub/input.go index 5799b83a24d..2b60a8a1abe 100644 --- a/x-pack/filebeat/input/azureeventhub/input.go +++ b/x-pack/filebeat/input/azureeventhub/input.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +//go:build !aix // +build !aix package azureeventhub diff --git a/x-pack/filebeat/input/azureeventhub/input_test.go b/x-pack/filebeat/input/azureeventhub/input_test.go index dc449df3bdb..797a54876d4 100644 --- a/x-pack/filebeat/input/azureeventhub/input_test.go +++ b/x-pack/filebeat/input/azureeventhub/input_test.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +//go:build !aix // +build !aix package azureeventhub diff --git a/x-pack/filebeat/input/cloudfoundry/input.go b/x-pack/filebeat/input/cloudfoundry/input.go index 95f070967a7..4931cb035ca 100644 --- a/x-pack/filebeat/input/cloudfoundry/input.go +++ b/x-pack/filebeat/input/cloudfoundry/input.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +//go:build !aix // +build !aix package cloudfoundry diff --git a/x-pack/filebeat/input/cloudfoundry/v1.go b/x-pack/filebeat/input/cloudfoundry/v1.go index fc12a14f431..6b0b5077b13 100644 --- a/x-pack/filebeat/input/cloudfoundry/v1.go +++ b/x-pack/filebeat/input/cloudfoundry/v1.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +//go:build !aix // +build !aix package cloudfoundry diff --git a/x-pack/filebeat/input/cloudfoundry/v2.go b/x-pack/filebeat/input/cloudfoundry/v2.go index 11488dffa8e..229da01dd74 100644 --- a/x-pack/filebeat/input/cloudfoundry/v2.go +++ b/x-pack/filebeat/input/cloudfoundry/v2.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +//go:build !aix // +build !aix package cloudfoundry diff --git a/x-pack/filebeat/input/default-inputs/inputs_other.go b/x-pack/filebeat/input/default-inputs/inputs_other.go index bad2a8e2578..c31106c3baa 100644 --- a/x-pack/filebeat/input/default-inputs/inputs_other.go +++ b/x-pack/filebeat/input/default-inputs/inputs_other.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +//go:build !aix // +build !aix package inputs diff --git a/x-pack/libbeat/processors/add_cloudfoundry_metadata/add_cloudfoundry_metadata.go b/x-pack/libbeat/processors/add_cloudfoundry_metadata/add_cloudfoundry_metadata.go index 73180927599..e4d459d2a14 100644 --- a/x-pack/libbeat/processors/add_cloudfoundry_metadata/add_cloudfoundry_metadata.go +++ b/x-pack/libbeat/processors/add_cloudfoundry_metadata/add_cloudfoundry_metadata.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +//go:build !aix // +build !aix package add_cloudfoundry_metadata diff --git a/x-pack/libbeat/processors/add_cloudfoundry_metadata/add_cloudfoundry_metadata_test.go b/x-pack/libbeat/processors/add_cloudfoundry_metadata/add_cloudfoundry_metadata_test.go index f57c80e1d59..a5dfa7e9558 100644 --- a/x-pack/libbeat/processors/add_cloudfoundry_metadata/add_cloudfoundry_metadata_test.go +++ b/x-pack/libbeat/processors/add_cloudfoundry_metadata/add_cloudfoundry_metadata_test.go @@ -2,6 +2,7 @@ // or more contributor license agreements. Licensed under the Elastic License; // you may not use this file except in compliance with the Elastic License. +//go:build !aix // +build !aix package add_cloudfoundry_metadata From 0c47808041a137f97a03f559f91ea091dae0422d Mon Sep 17 00:00:00 2001 From: Alex Kristiansen Date: Mon, 11 Oct 2021 12:53:27 -0700 Subject: [PATCH 18/20] see if list_docker is fixed --- metricbeat/include/list_docker.go | 1 - 1 file changed, 1 deletion(-) diff --git a/metricbeat/include/list_docker.go b/metricbeat/include/list_docker.go index 1e8a7c494e7..c2fc8197b90 100644 --- a/metricbeat/include/list_docker.go +++ b/metricbeat/include/list_docker.go @@ -17,7 +17,6 @@ // Code generated by beats/dev-tools/cmd/module_include_list/module_include_list.go - DO NOT EDIT. -//go:build linux || darwin || windows // +build linux darwin windows package include From 42a37850cf670d4821733d25a834d067ad0ad698 Mon Sep 17 00:00:00 2001 From: Alex Kristiansen Date: Tue, 12 Oct 2021 10:28:02 -0700 Subject: [PATCH 19/20] fix CI --- metricbeat/include/list_docker.go | 1 + 1 file changed, 1 insertion(+) diff --git a/metricbeat/include/list_docker.go b/metricbeat/include/list_docker.go index c2fc8197b90..1e8a7c494e7 100644 --- a/metricbeat/include/list_docker.go +++ b/metricbeat/include/list_docker.go @@ -17,6 +17,7 @@ // Code generated by beats/dev-tools/cmd/module_include_list/module_include_list.go - DO NOT EDIT. +//go:build linux || darwin || windows // +build linux darwin windows package include From 8fefdf94fb78b9236aea8521bb3dab04872f864d Mon Sep 17 00:00:00 2001 From: Alex Kristiansen Date: Mon, 18 Oct 2021 15:26:33 -0700 Subject: [PATCH 20/20] go mod tidy --- go.mod | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/go.mod b/go.mod index 1b4734b388c..4cabf2326e8 100644 --- a/go.mod +++ b/go.mod @@ -70,8 +70,8 @@ require ( github.com/elastic/go-perf v0.0.0-20191212140718-9c656876f595 github.com/elastic/go-seccomp-bpf v1.2.0 github.com/elastic/go-structform v0.0.9 - github.com/elastic/go-txfile v0.0.8 github.com/elastic/go-sysinfo v1.7.1 + github.com/elastic/go-txfile v0.0.8 github.com/elastic/go-ucfg v0.8.3 github.com/elastic/go-windows v1.0.1 github.com/elastic/gosigar v0.14.1