Skip to content

Commit

Permalink
Rename package collectors -> collector
Browse files Browse the repository at this point in the history
  • Loading branch information
talal committed Jan 14, 2020
1 parent d45f9bd commit 067b0e7
Show file tree
Hide file tree
Showing 10 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion collectors/collector.go → collector/collector.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.

package collectors
package collector

import (
"fmt"
Expand Down
2 changes: 1 addition & 1 deletion collectors/dispersion.go → collector/dispersion.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.

package collectors
package collector

import (
"encoding/json"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.

package collectors
package collector

import (
"path/filepath"
Expand Down
2 changes: 1 addition & 1 deletion collectors/recon.go → collector/recon.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.

package collectors
package collector

import (
"bytes"
Expand Down
2 changes: 1 addition & 1 deletion collectors/recon_test.go → collector/recon_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.

package collectors
package collector

import (
"path/filepath"
Expand Down
6 changes: 3 additions & 3 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,16 +25,16 @@ import (
"github.com/prometheus/client_golang/prometheus/promhttp"
"github.com/sapcc/go-bits/httpee"
"github.com/sapcc/go-bits/logg"
"github.com/sapcc/swift-health-exporter/collectors"
"github.com/sapcc/swift-health-exporter/collector"
)

func main() {
logg.ShowDebug, _ = strconv.ParseBool(os.Getenv("DEBUG"))
swiftDispersionReportPath := getExecutablePath("SWIFT_DISPERSION_REPORT_PATH", "swift-dispersion-report")
swiftReconPath := getExecutablePath("SWIFT_RECON_PATH", "swift-recon")

prometheus.MustRegister(collectors.NewDispersionCollector(swiftDispersionReportPath))
prometheus.MustRegister(collectors.NewReconCollector(swiftReconPath))
prometheus.MustRegister(collector.NewDispersionCollector(swiftDispersionReportPath))
prometheus.MustRegister(collector.NewReconCollector(swiftReconPath))

// this port has been allocated for Swift health exporter
// See: https://github.com/prometheus/prometheus/wiki/Default-port-allocations
Expand Down

0 comments on commit 067b0e7

Please sign in to comment.