From 2d3fe9795f792c62ad52603f013f8abe2f48ff22 Mon Sep 17 00:00:00 2001 From: TwinProduction Date: Sun, 3 Oct 2021 21:53:59 -0400 Subject: [PATCH] Add v3 to module path Gatus wasn't intended to be used as a library, but I have a use case now. --- alerting/config.go | 22 +++++++------- alerting/provider/custom/custom.go | 6 ++-- alerting/provider/custom/custom_test.go | 4 +-- alerting/provider/discord/discord.go | 6 ++-- alerting/provider/discord/discord_test.go | 4 +-- alerting/provider/mattermost/mattermost.go | 8 ++--- .../provider/mattermost/mattermost_test.go | 4 +-- alerting/provider/messagebird/messagebird.go | 6 ++-- .../provider/messagebird/messagebird_test.go | 4 +-- alerting/provider/pagerduty/pagerduty.go | 6 ++-- alerting/provider/pagerduty/pagerduty_test.go | 4 +-- alerting/provider/provider.go | 22 +++++++------- alerting/provider/provider_test.go | 2 +- alerting/provider/slack/slack.go | 6 ++-- alerting/provider/slack/slack_test.go | 4 +-- alerting/provider/teams/teams.go | 6 ++-- alerting/provider/teams/teams_test.go | 4 +-- alerting/provider/telegram/telegram.go | 6 ++-- alerting/provider/telegram/telegram_test.go | 4 +-- alerting/provider/twilio/twilio.go | 6 ++-- alerting/provider/twilio/twilio_test.go | 4 +-- config/config.go | 18 +++++------ config/config_test.go | 30 +++++++++---------- controller/controller.go | 8 ++--- controller/controller_test.go | 6 ++-- controller/handler/badge.go | 4 +-- controller/handler/badge_test.go | 8 ++--- controller/handler/chart.go | 4 +-- controller/handler/chart_test.go | 8 ++--- controller/handler/handler.go | 4 +-- controller/handler/service_status.go | 6 ++-- controller/handler/service_status_test.go | 8 ++--- controller/handler/spa.go | 2 +- controller/handler/spa_test.go | 8 ++--- controller/handler/util.go | 2 +- core/condition.go | 4 +-- core/dns_test.go | 2 +- core/service.go | 8 ++--- core/service_test.go | 4 +-- go.mod | 2 +- main.go | 8 ++--- metric/metric.go | 2 +- storage/storage.go | 6 ++-- storage/storage_test.go | 2 +- storage/store/memory/memory.go | 8 ++--- storage/store/memory/memory_test.go | 4 +-- storage/store/memory/uptime.go | 2 +- storage/store/memory/uptime_bench_test.go | 2 +- storage/store/memory/uptime_test.go | 2 +- storage/store/memory/util.go | 6 ++-- storage/store/memory/util_bench_test.go | 6 ++-- storage/store/memory/util_test.go | 6 ++-- storage/store/sql/sql.go | 8 ++--- storage/store/sql/sql_test.go | 6 ++-- storage/store/store.go | 8 ++--- storage/store/store_bench_test.go | 8 ++--- storage/store/store_test.go | 10 +++---- watchdog/alerting.go | 6 ++-- watchdog/alerting_test.go | 12 ++++---- watchdog/watchdog.go | 12 ++++---- 60 files changed, 199 insertions(+), 199 deletions(-) diff --git a/alerting/config.go b/alerting/config.go index 19651f62..0a18dfce 100644 --- a/alerting/config.go +++ b/alerting/config.go @@ -1,17 +1,17 @@ package alerting import ( - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/alerting/provider" - "github.com/TwinProduction/gatus/alerting/provider/custom" - "github.com/TwinProduction/gatus/alerting/provider/discord" - "github.com/TwinProduction/gatus/alerting/provider/mattermost" - "github.com/TwinProduction/gatus/alerting/provider/messagebird" - "github.com/TwinProduction/gatus/alerting/provider/pagerduty" - "github.com/TwinProduction/gatus/alerting/provider/slack" - "github.com/TwinProduction/gatus/alerting/provider/teams" - "github.com/TwinProduction/gatus/alerting/provider/telegram" - "github.com/TwinProduction/gatus/alerting/provider/twilio" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/alerting/provider" + "github.com/TwinProduction/gatus/v3/alerting/provider/custom" + "github.com/TwinProduction/gatus/v3/alerting/provider/discord" + "github.com/TwinProduction/gatus/v3/alerting/provider/mattermost" + "github.com/TwinProduction/gatus/v3/alerting/provider/messagebird" + "github.com/TwinProduction/gatus/v3/alerting/provider/pagerduty" + "github.com/TwinProduction/gatus/v3/alerting/provider/slack" + "github.com/TwinProduction/gatus/v3/alerting/provider/teams" + "github.com/TwinProduction/gatus/v3/alerting/provider/telegram" + "github.com/TwinProduction/gatus/v3/alerting/provider/twilio" ) // Config is the configuration for alerting providers diff --git a/alerting/provider/custom/custom.go b/alerting/provider/custom/custom.go index e757f80a..a74f02fb 100644 --- a/alerting/provider/custom/custom.go +++ b/alerting/provider/custom/custom.go @@ -9,9 +9,9 @@ import ( "os" "strings" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/client" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/client" + "github.com/TwinProduction/gatus/v3/core" ) // AlertProvider is the configuration necessary for sending an alert using a custom HTTP request diff --git a/alerting/provider/custom/custom_test.go b/alerting/provider/custom/custom_test.go index 18ac1431..97f7ec35 100644 --- a/alerting/provider/custom/custom_test.go +++ b/alerting/provider/custom/custom_test.go @@ -4,8 +4,8 @@ import ( "io/ioutil" "testing" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/core" ) func TestAlertProvider_IsValid(t *testing.T) { diff --git a/alerting/provider/discord/discord.go b/alerting/provider/discord/discord.go index 003654ac..429aebbd 100644 --- a/alerting/provider/discord/discord.go +++ b/alerting/provider/discord/discord.go @@ -4,9 +4,9 @@ import ( "fmt" "net/http" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/alerting/provider/custom" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/alerting/provider/custom" + "github.com/TwinProduction/gatus/v3/core" ) // AlertProvider is the configuration necessary for sending an alert using Discord diff --git a/alerting/provider/discord/discord_test.go b/alerting/provider/discord/discord_test.go index dc410288..44fb995e 100644 --- a/alerting/provider/discord/discord_test.go +++ b/alerting/provider/discord/discord_test.go @@ -6,8 +6,8 @@ import ( "strings" "testing" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/core" ) func TestAlertProvider_IsValid(t *testing.T) { diff --git a/alerting/provider/mattermost/mattermost.go b/alerting/provider/mattermost/mattermost.go index 326dd379..41fe92fd 100644 --- a/alerting/provider/mattermost/mattermost.go +++ b/alerting/provider/mattermost/mattermost.go @@ -4,10 +4,10 @@ import ( "fmt" "net/http" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/alerting/provider/custom" - "github.com/TwinProduction/gatus/client" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/alerting/provider/custom" + "github.com/TwinProduction/gatus/v3/client" + "github.com/TwinProduction/gatus/v3/core" ) // AlertProvider is the configuration necessary for sending an alert using Mattermost diff --git a/alerting/provider/mattermost/mattermost_test.go b/alerting/provider/mattermost/mattermost_test.go index 772b6c0f..30a49ff6 100644 --- a/alerting/provider/mattermost/mattermost_test.go +++ b/alerting/provider/mattermost/mattermost_test.go @@ -6,8 +6,8 @@ import ( "strings" "testing" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/core" ) func TestAlertProvider_IsValid(t *testing.T) { diff --git a/alerting/provider/messagebird/messagebird.go b/alerting/provider/messagebird/messagebird.go index 1931d19e..1ee9d2ea 100644 --- a/alerting/provider/messagebird/messagebird.go +++ b/alerting/provider/messagebird/messagebird.go @@ -4,9 +4,9 @@ import ( "fmt" "net/http" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/alerting/provider/custom" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/alerting/provider/custom" + "github.com/TwinProduction/gatus/v3/core" ) const ( diff --git a/alerting/provider/messagebird/messagebird_test.go b/alerting/provider/messagebird/messagebird_test.go index 03ec1a2c..11719303 100644 --- a/alerting/provider/messagebird/messagebird_test.go +++ b/alerting/provider/messagebird/messagebird_test.go @@ -6,8 +6,8 @@ import ( "strings" "testing" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/core" ) func TestMessagebirdAlertProvider_IsValid(t *testing.T) { diff --git a/alerting/provider/pagerduty/pagerduty.go b/alerting/provider/pagerduty/pagerduty.go index aa01994c..2f209d5f 100644 --- a/alerting/provider/pagerduty/pagerduty.go +++ b/alerting/provider/pagerduty/pagerduty.go @@ -4,9 +4,9 @@ import ( "fmt" "net/http" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/alerting/provider/custom" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/alerting/provider/custom" + "github.com/TwinProduction/gatus/v3/core" ) const ( diff --git a/alerting/provider/pagerduty/pagerduty_test.go b/alerting/provider/pagerduty/pagerduty_test.go index 08d65de2..31f046a6 100644 --- a/alerting/provider/pagerduty/pagerduty_test.go +++ b/alerting/provider/pagerduty/pagerduty_test.go @@ -6,8 +6,8 @@ import ( "strings" "testing" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/core" ) func TestAlertProvider_IsValid(t *testing.T) { diff --git a/alerting/provider/provider.go b/alerting/provider/provider.go index d276ce61..d34dbd3d 100644 --- a/alerting/provider/provider.go +++ b/alerting/provider/provider.go @@ -1,17 +1,17 @@ package provider import ( - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/alerting/provider/custom" - "github.com/TwinProduction/gatus/alerting/provider/discord" - "github.com/TwinProduction/gatus/alerting/provider/mattermost" - "github.com/TwinProduction/gatus/alerting/provider/messagebird" - "github.com/TwinProduction/gatus/alerting/provider/pagerduty" - "github.com/TwinProduction/gatus/alerting/provider/slack" - "github.com/TwinProduction/gatus/alerting/provider/teams" - "github.com/TwinProduction/gatus/alerting/provider/telegram" - "github.com/TwinProduction/gatus/alerting/provider/twilio" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/alerting/provider/custom" + "github.com/TwinProduction/gatus/v3/alerting/provider/discord" + "github.com/TwinProduction/gatus/v3/alerting/provider/mattermost" + "github.com/TwinProduction/gatus/v3/alerting/provider/messagebird" + "github.com/TwinProduction/gatus/v3/alerting/provider/pagerduty" + "github.com/TwinProduction/gatus/v3/alerting/provider/slack" + "github.com/TwinProduction/gatus/v3/alerting/provider/teams" + "github.com/TwinProduction/gatus/v3/alerting/provider/telegram" + "github.com/TwinProduction/gatus/v3/alerting/provider/twilio" + "github.com/TwinProduction/gatus/v3/core" ) // AlertProvider is the interface that each providers should implement diff --git a/alerting/provider/provider_test.go b/alerting/provider/provider_test.go index 187b0541..961fe4e6 100644 --- a/alerting/provider/provider_test.go +++ b/alerting/provider/provider_test.go @@ -3,7 +3,7 @@ package provider import ( "testing" - "github.com/TwinProduction/gatus/alerting/alert" + "github.com/TwinProduction/gatus/v3/alerting/alert" ) func TestParseWithDefaultAlert(t *testing.T) { diff --git a/alerting/provider/slack/slack.go b/alerting/provider/slack/slack.go index 1ed7fb62..c9293312 100644 --- a/alerting/provider/slack/slack.go +++ b/alerting/provider/slack/slack.go @@ -4,9 +4,9 @@ import ( "fmt" "net/http" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/alerting/provider/custom" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/alerting/provider/custom" + "github.com/TwinProduction/gatus/v3/core" ) // AlertProvider is the configuration necessary for sending an alert using Slack diff --git a/alerting/provider/slack/slack_test.go b/alerting/provider/slack/slack_test.go index 2efa78d2..7b5e1548 100644 --- a/alerting/provider/slack/slack_test.go +++ b/alerting/provider/slack/slack_test.go @@ -6,8 +6,8 @@ import ( "strings" "testing" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/core" ) func TestAlertProvider_IsValid(t *testing.T) { diff --git a/alerting/provider/teams/teams.go b/alerting/provider/teams/teams.go index 61ee3feb..ce89f7d5 100644 --- a/alerting/provider/teams/teams.go +++ b/alerting/provider/teams/teams.go @@ -4,9 +4,9 @@ import ( "fmt" "net/http" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/alerting/provider/custom" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/alerting/provider/custom" + "github.com/TwinProduction/gatus/v3/core" ) // AlertProvider is the configuration necessary for sending an alert using Teams diff --git a/alerting/provider/teams/teams_test.go b/alerting/provider/teams/teams_test.go index b7400d3d..36dd0ffd 100644 --- a/alerting/provider/teams/teams_test.go +++ b/alerting/provider/teams/teams_test.go @@ -6,8 +6,8 @@ import ( "strings" "testing" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/core" ) func TestAlertProvider_IsValid(t *testing.T) { diff --git a/alerting/provider/telegram/telegram.go b/alerting/provider/telegram/telegram.go index bdb84076..962358ec 100644 --- a/alerting/provider/telegram/telegram.go +++ b/alerting/provider/telegram/telegram.go @@ -4,9 +4,9 @@ import ( "fmt" "net/http" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/alerting/provider/custom" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/alerting/provider/custom" + "github.com/TwinProduction/gatus/v3/core" ) // AlertProvider is the configuration necessary for sending an alert using Telegram diff --git a/alerting/provider/telegram/telegram_test.go b/alerting/provider/telegram/telegram_test.go index 4098fbbf..a9d0855e 100644 --- a/alerting/provider/telegram/telegram_test.go +++ b/alerting/provider/telegram/telegram_test.go @@ -7,8 +7,8 @@ import ( "strings" "testing" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/core" ) func TestAlertProvider_IsValid(t *testing.T) { diff --git a/alerting/provider/twilio/twilio.go b/alerting/provider/twilio/twilio.go index cef05d8e..ef82fa06 100644 --- a/alerting/provider/twilio/twilio.go +++ b/alerting/provider/twilio/twilio.go @@ -6,9 +6,9 @@ import ( "net/http" "net/url" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/alerting/provider/custom" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/alerting/provider/custom" + "github.com/TwinProduction/gatus/v3/core" ) // AlertProvider is the configuration necessary for sending an alert using Twilio diff --git a/alerting/provider/twilio/twilio_test.go b/alerting/provider/twilio/twilio_test.go index 6da79a19..5f81e460 100644 --- a/alerting/provider/twilio/twilio_test.go +++ b/alerting/provider/twilio/twilio_test.go @@ -5,8 +5,8 @@ import ( "strings" "testing" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/core" ) func TestTwilioAlertProvider_IsValid(t *testing.T) { diff --git a/config/config.go b/config/config.go index 9ef21014..d18e7468 100644 --- a/config/config.go +++ b/config/config.go @@ -7,15 +7,15 @@ import ( "os" "time" - "github.com/TwinProduction/gatus/alerting" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/alerting/provider" - "github.com/TwinProduction/gatus/config/maintenance" - "github.com/TwinProduction/gatus/config/ui" - "github.com/TwinProduction/gatus/config/web" - "github.com/TwinProduction/gatus/core" - "github.com/TwinProduction/gatus/security" - "github.com/TwinProduction/gatus/storage" + "github.com/TwinProduction/gatus/v3/alerting" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/alerting/provider" + "github.com/TwinProduction/gatus/v3/config/maintenance" + "github.com/TwinProduction/gatus/v3/config/ui" + "github.com/TwinProduction/gatus/v3/config/web" + "github.com/TwinProduction/gatus/v3/core" + "github.com/TwinProduction/gatus/v3/security" + "github.com/TwinProduction/gatus/v3/storage" "gopkg.in/yaml.v2" ) diff --git a/config/config_test.go b/config/config_test.go index 85179be5..32baaf2e 100644 --- a/config/config_test.go +++ b/config/config_test.go @@ -5,21 +5,21 @@ import ( "testing" "time" - "github.com/TwinProduction/gatus/alerting" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/alerting/provider/custom" - "github.com/TwinProduction/gatus/alerting/provider/discord" - "github.com/TwinProduction/gatus/alerting/provider/mattermost" - "github.com/TwinProduction/gatus/alerting/provider/messagebird" - "github.com/TwinProduction/gatus/alerting/provider/pagerduty" - "github.com/TwinProduction/gatus/alerting/provider/slack" - "github.com/TwinProduction/gatus/alerting/provider/teams" - "github.com/TwinProduction/gatus/alerting/provider/telegram" - "github.com/TwinProduction/gatus/alerting/provider/twilio" - "github.com/TwinProduction/gatus/client" - "github.com/TwinProduction/gatus/config/ui" - "github.com/TwinProduction/gatus/config/web" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/alerting" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/alerting/provider/custom" + "github.com/TwinProduction/gatus/v3/alerting/provider/discord" + "github.com/TwinProduction/gatus/v3/alerting/provider/mattermost" + "github.com/TwinProduction/gatus/v3/alerting/provider/messagebird" + "github.com/TwinProduction/gatus/v3/alerting/provider/pagerduty" + "github.com/TwinProduction/gatus/v3/alerting/provider/slack" + "github.com/TwinProduction/gatus/v3/alerting/provider/teams" + "github.com/TwinProduction/gatus/v3/alerting/provider/telegram" + "github.com/TwinProduction/gatus/v3/alerting/provider/twilio" + "github.com/TwinProduction/gatus/v3/client" + "github.com/TwinProduction/gatus/v3/config/ui" + "github.com/TwinProduction/gatus/v3/config/web" + "github.com/TwinProduction/gatus/v3/core" ) func TestLoadFileThatDoesNotExist(t *testing.T) { diff --git a/controller/controller.go b/controller/controller.go index 6b54e5b4..ccaeff57 100644 --- a/controller/controller.go +++ b/controller/controller.go @@ -8,10 +8,10 @@ import ( "os" "time" - "github.com/TwinProduction/gatus/config/ui" - "github.com/TwinProduction/gatus/config/web" - "github.com/TwinProduction/gatus/controller/handler" - "github.com/TwinProduction/gatus/security" + "github.com/TwinProduction/gatus/v3/config/ui" + "github.com/TwinProduction/gatus/v3/config/web" + "github.com/TwinProduction/gatus/v3/controller/handler" + "github.com/TwinProduction/gatus/v3/security" ) var ( diff --git a/controller/controller_test.go b/controller/controller_test.go index f46aab03..d97bbe7f 100644 --- a/controller/controller_test.go +++ b/controller/controller_test.go @@ -7,9 +7,9 @@ import ( "os" "testing" - "github.com/TwinProduction/gatus/config" - "github.com/TwinProduction/gatus/config/web" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/config" + "github.com/TwinProduction/gatus/v3/config/web" + "github.com/TwinProduction/gatus/v3/core" ) func TestHandle(t *testing.T) { diff --git a/controller/handler/badge.go b/controller/handler/badge.go index 02ad64b3..d0fe49bb 100644 --- a/controller/handler/badge.go +++ b/controller/handler/badge.go @@ -7,8 +7,8 @@ import ( "strings" "time" - "github.com/TwinProduction/gatus/storage" - "github.com/TwinProduction/gatus/storage/store/common" + "github.com/TwinProduction/gatus/v3/storage" + "github.com/TwinProduction/gatus/v3/storage/store/common" "github.com/gorilla/mux" ) diff --git a/controller/handler/badge_test.go b/controller/handler/badge_test.go index 697a7650..f97500ff 100644 --- a/controller/handler/badge_test.go +++ b/controller/handler/badge_test.go @@ -7,10 +7,10 @@ import ( "testing" "time" - "github.com/TwinProduction/gatus/config" - "github.com/TwinProduction/gatus/core" - "github.com/TwinProduction/gatus/storage" - "github.com/TwinProduction/gatus/watchdog" + "github.com/TwinProduction/gatus/v3/config" + "github.com/TwinProduction/gatus/v3/core" + "github.com/TwinProduction/gatus/v3/storage" + "github.com/TwinProduction/gatus/v3/watchdog" ) func TestUptimeBadge(t *testing.T) { diff --git a/controller/handler/chart.go b/controller/handler/chart.go index c335d9dd..b7bb59d0 100644 --- a/controller/handler/chart.go +++ b/controller/handler/chart.go @@ -7,8 +7,8 @@ import ( "sort" "time" - "github.com/TwinProduction/gatus/storage" - "github.com/TwinProduction/gatus/storage/store/common" + "github.com/TwinProduction/gatus/v3/storage" + "github.com/TwinProduction/gatus/v3/storage/store/common" "github.com/gorilla/mux" "github.com/wcharczuk/go-chart/v2" "github.com/wcharczuk/go-chart/v2/drawing" diff --git a/controller/handler/chart_test.go b/controller/handler/chart_test.go index 0354c73e..ff4f0e9b 100644 --- a/controller/handler/chart_test.go +++ b/controller/handler/chart_test.go @@ -6,10 +6,10 @@ import ( "testing" "time" - "github.com/TwinProduction/gatus/config" - "github.com/TwinProduction/gatus/core" - "github.com/TwinProduction/gatus/storage" - "github.com/TwinProduction/gatus/watchdog" + "github.com/TwinProduction/gatus/v3/config" + "github.com/TwinProduction/gatus/v3/core" + "github.com/TwinProduction/gatus/v3/storage" + "github.com/TwinProduction/gatus/v3/watchdog" ) func TestResponseTimeChart(t *testing.T) { diff --git a/controller/handler/handler.go b/controller/handler/handler.go index 6a5cb21a..628578e0 100644 --- a/controller/handler/handler.go +++ b/controller/handler/handler.go @@ -3,8 +3,8 @@ package handler import ( "net/http" - "github.com/TwinProduction/gatus/config/ui" - "github.com/TwinProduction/gatus/security" + "github.com/TwinProduction/gatus/v3/config/ui" + "github.com/TwinProduction/gatus/v3/security" "github.com/TwinProduction/health" "github.com/gorilla/mux" "github.com/prometheus/client_golang/prometheus/promhttp" diff --git a/controller/handler/service_status.go b/controller/handler/service_status.go index 2d7454e5..c8ba2d92 100644 --- a/controller/handler/service_status.go +++ b/controller/handler/service_status.go @@ -10,9 +10,9 @@ import ( "strings" "time" - "github.com/TwinProduction/gatus/storage" - "github.com/TwinProduction/gatus/storage/store/common" - "github.com/TwinProduction/gatus/storage/store/common/paging" + "github.com/TwinProduction/gatus/v3/storage" + "github.com/TwinProduction/gatus/v3/storage/store/common" + "github.com/TwinProduction/gatus/v3/storage/store/common/paging" "github.com/TwinProduction/gocache" "github.com/gorilla/mux" ) diff --git a/controller/handler/service_status_test.go b/controller/handler/service_status_test.go index a85e8034..c30d8a37 100644 --- a/controller/handler/service_status_test.go +++ b/controller/handler/service_status_test.go @@ -6,10 +6,10 @@ import ( "testing" "time" - "github.com/TwinProduction/gatus/config" - "github.com/TwinProduction/gatus/core" - "github.com/TwinProduction/gatus/storage" - "github.com/TwinProduction/gatus/watchdog" + "github.com/TwinProduction/gatus/v3/config" + "github.com/TwinProduction/gatus/v3/core" + "github.com/TwinProduction/gatus/v3/storage" + "github.com/TwinProduction/gatus/v3/watchdog" ) var ( diff --git a/controller/handler/spa.go b/controller/handler/spa.go index 9d3806fa..2b49d41f 100644 --- a/controller/handler/spa.go +++ b/controller/handler/spa.go @@ -5,7 +5,7 @@ import ( "log" "net/http" - "github.com/TwinProduction/gatus/config/ui" + "github.com/TwinProduction/gatus/v3/config/ui" ) func SinglePageApplication(staticFolder string, ui *ui.Config) http.HandlerFunc { diff --git a/controller/handler/spa_test.go b/controller/handler/spa_test.go index d75c68f7..5b5a4e97 100644 --- a/controller/handler/spa_test.go +++ b/controller/handler/spa_test.go @@ -6,10 +6,10 @@ import ( "testing" "time" - "github.com/TwinProduction/gatus/config" - "github.com/TwinProduction/gatus/core" - "github.com/TwinProduction/gatus/storage" - "github.com/TwinProduction/gatus/watchdog" + "github.com/TwinProduction/gatus/v3/config" + "github.com/TwinProduction/gatus/v3/core" + "github.com/TwinProduction/gatus/v3/storage" + "github.com/TwinProduction/gatus/v3/watchdog" ) func TestSinglePageApplication(t *testing.T) { diff --git a/controller/handler/util.go b/controller/handler/util.go index 32c862b9..37732cf3 100644 --- a/controller/handler/util.go +++ b/controller/handler/util.go @@ -4,7 +4,7 @@ import ( "net/http" "strconv" - "github.com/TwinProduction/gatus/storage/store/common" + "github.com/TwinProduction/gatus/v3/storage/store/common" ) const ( diff --git a/core/condition.go b/core/condition.go index 3ee096b4..28515c63 100644 --- a/core/condition.go +++ b/core/condition.go @@ -6,8 +6,8 @@ import ( "strings" "time" - "github.com/TwinProduction/gatus/jsonpath" - "github.com/TwinProduction/gatus/pattern" + "github.com/TwinProduction/gatus/v3/jsonpath" + "github.com/TwinProduction/gatus/v3/pattern" ) const ( diff --git a/core/dns_test.go b/core/dns_test.go index f6bb5e81..149ee31a 100644 --- a/core/dns_test.go +++ b/core/dns_test.go @@ -3,7 +3,7 @@ package core import ( "testing" - "github.com/TwinProduction/gatus/pattern" + "github.com/TwinProduction/gatus/v3/pattern" ) func TestIntegrationQuery(t *testing.T) { diff --git a/core/service.go b/core/service.go index 07c31d26..de11b159 100644 --- a/core/service.go +++ b/core/service.go @@ -12,10 +12,10 @@ import ( "strings" "time" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/client" - "github.com/TwinProduction/gatus/core/ui" - "github.com/TwinProduction/gatus/util" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/client" + "github.com/TwinProduction/gatus/v3/core/ui" + "github.com/TwinProduction/gatus/v3/util" ) const ( diff --git a/core/service_test.go b/core/service_test.go index 0b3d8b4a..c6586d47 100644 --- a/core/service_test.go +++ b/core/service_test.go @@ -6,8 +6,8 @@ import ( "testing" "time" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/client" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/client" ) func TestService_IsEnabled(t *testing.T) { diff --git a/go.mod b/go.mod index cc63719d..6a3698e2 100644 --- a/go.mod +++ b/go.mod @@ -1,4 +1,4 @@ -module github.com/TwinProduction/gatus +module github.com/TwinProduction/gatus/v3 go 1.17 diff --git a/main.go b/main.go index c9f5b01a..61049fa3 100644 --- a/main.go +++ b/main.go @@ -7,10 +7,10 @@ import ( "syscall" "time" - "github.com/TwinProduction/gatus/config" - "github.com/TwinProduction/gatus/controller" - "github.com/TwinProduction/gatus/storage" - "github.com/TwinProduction/gatus/watchdog" + "github.com/TwinProduction/gatus/v3/config" + "github.com/TwinProduction/gatus/v3/controller" + "github.com/TwinProduction/gatus/v3/storage" + "github.com/TwinProduction/gatus/v3/watchdog" ) func main() { diff --git a/metric/metric.go b/metric/metric.go index a98e5eb8..6d3d8669 100644 --- a/metric/metric.go +++ b/metric/metric.go @@ -5,7 +5,7 @@ import ( "strconv" "sync" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/core" "github.com/prometheus/client_golang/prometheus" "github.com/prometheus/client_golang/prometheus/promauto" ) diff --git a/storage/storage.go b/storage/storage.go index 239a0782..1d4bb120 100644 --- a/storage/storage.go +++ b/storage/storage.go @@ -5,9 +5,9 @@ import ( "log" "time" - "github.com/TwinProduction/gatus/storage/store" - "github.com/TwinProduction/gatus/storage/store/memory" - "github.com/TwinProduction/gatus/storage/store/sql" + "github.com/TwinProduction/gatus/v3/storage/store" + "github.com/TwinProduction/gatus/v3/storage/store/memory" + "github.com/TwinProduction/gatus/v3/storage/store/sql" ) var ( diff --git a/storage/storage_test.go b/storage/storage_test.go index 21bc9a8a..5744bfcb 100644 --- a/storage/storage_test.go +++ b/storage/storage_test.go @@ -4,7 +4,7 @@ import ( "testing" "time" - "github.com/TwinProduction/gatus/storage/store/sql" + "github.com/TwinProduction/gatus/v3/storage/store/sql" ) func TestGet(t *testing.T) { diff --git a/storage/store/memory/memory.go b/storage/store/memory/memory.go index 1ea0f721..a1fde5de 100644 --- a/storage/store/memory/memory.go +++ b/storage/store/memory/memory.go @@ -6,10 +6,10 @@ import ( "sync" "time" - "github.com/TwinProduction/gatus/core" - "github.com/TwinProduction/gatus/storage/store/common" - "github.com/TwinProduction/gatus/storage/store/common/paging" - "github.com/TwinProduction/gatus/util" + "github.com/TwinProduction/gatus/v3/core" + "github.com/TwinProduction/gatus/v3/storage/store/common" + "github.com/TwinProduction/gatus/v3/storage/store/common/paging" + "github.com/TwinProduction/gatus/v3/util" "github.com/TwinProduction/gocache" ) diff --git a/storage/store/memory/memory_test.go b/storage/store/memory/memory_test.go index 8fd7a9c5..92119aaf 100644 --- a/storage/store/memory/memory_test.go +++ b/storage/store/memory/memory_test.go @@ -4,8 +4,8 @@ import ( "testing" "time" - "github.com/TwinProduction/gatus/core" - "github.com/TwinProduction/gatus/storage/store/common/paging" + "github.com/TwinProduction/gatus/v3/core" + "github.com/TwinProduction/gatus/v3/storage/store/common/paging" ) var ( diff --git a/storage/store/memory/uptime.go b/storage/store/memory/uptime.go index d75a309a..4ea46404 100644 --- a/storage/store/memory/uptime.go +++ b/storage/store/memory/uptime.go @@ -3,7 +3,7 @@ package memory import ( "time" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/core" ) const ( diff --git a/storage/store/memory/uptime_bench_test.go b/storage/store/memory/uptime_bench_test.go index 502ca397..0c0ad53c 100644 --- a/storage/store/memory/uptime_bench_test.go +++ b/storage/store/memory/uptime_bench_test.go @@ -4,7 +4,7 @@ import ( "testing" "time" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/core" ) func BenchmarkProcessUptimeAfterResult(b *testing.B) { diff --git a/storage/store/memory/uptime_test.go b/storage/store/memory/uptime_test.go index 612d68ce..d67ab40b 100644 --- a/storage/store/memory/uptime_test.go +++ b/storage/store/memory/uptime_test.go @@ -4,7 +4,7 @@ import ( "testing" "time" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/core" ) func TestProcessUptimeAfterResult(t *testing.T) { diff --git a/storage/store/memory/util.go b/storage/store/memory/util.go index 68893ee2..6c977cd1 100644 --- a/storage/store/memory/util.go +++ b/storage/store/memory/util.go @@ -1,9 +1,9 @@ package memory import ( - "github.com/TwinProduction/gatus/core" - "github.com/TwinProduction/gatus/storage/store/common" - "github.com/TwinProduction/gatus/storage/store/common/paging" + "github.com/TwinProduction/gatus/v3/core" + "github.com/TwinProduction/gatus/v3/storage/store/common" + "github.com/TwinProduction/gatus/v3/storage/store/common/paging" ) // ShallowCopyServiceStatus returns a shallow copy of a ServiceStatus with only the results diff --git a/storage/store/memory/util_bench_test.go b/storage/store/memory/util_bench_test.go index e5a85f99..e5a066be 100644 --- a/storage/store/memory/util_bench_test.go +++ b/storage/store/memory/util_bench_test.go @@ -3,9 +3,9 @@ package memory import ( "testing" - "github.com/TwinProduction/gatus/core" - "github.com/TwinProduction/gatus/storage/store/common" - "github.com/TwinProduction/gatus/storage/store/common/paging" + "github.com/TwinProduction/gatus/v3/core" + "github.com/TwinProduction/gatus/v3/storage/store/common" + "github.com/TwinProduction/gatus/v3/storage/store/common/paging" ) func BenchmarkShallowCopyServiceStatus(b *testing.B) { diff --git a/storage/store/memory/util_test.go b/storage/store/memory/util_test.go index d9007e83..2a9eee6e 100644 --- a/storage/store/memory/util_test.go +++ b/storage/store/memory/util_test.go @@ -4,9 +4,9 @@ import ( "testing" "time" - "github.com/TwinProduction/gatus/core" - "github.com/TwinProduction/gatus/storage/store/common" - "github.com/TwinProduction/gatus/storage/store/common/paging" + "github.com/TwinProduction/gatus/v3/core" + "github.com/TwinProduction/gatus/v3/storage/store/common" + "github.com/TwinProduction/gatus/v3/storage/store/common/paging" ) func TestAddResult(t *testing.T) { diff --git a/storage/store/sql/sql.go b/storage/store/sql/sql.go index c7f13025..faec92a9 100644 --- a/storage/store/sql/sql.go +++ b/storage/store/sql/sql.go @@ -8,10 +8,10 @@ import ( "strings" "time" - "github.com/TwinProduction/gatus/core" - "github.com/TwinProduction/gatus/storage/store/common" - "github.com/TwinProduction/gatus/storage/store/common/paging" - "github.com/TwinProduction/gatus/util" + "github.com/TwinProduction/gatus/v3/core" + "github.com/TwinProduction/gatus/v3/storage/store/common" + "github.com/TwinProduction/gatus/v3/storage/store/common/paging" + "github.com/TwinProduction/gatus/v3/util" _ "github.com/lib/pq" _ "modernc.org/sqlite" ) diff --git a/storage/store/sql/sql_test.go b/storage/store/sql/sql_test.go index f0b38283..7bd98e0b 100644 --- a/storage/store/sql/sql_test.go +++ b/storage/store/sql/sql_test.go @@ -4,9 +4,9 @@ import ( "testing" "time" - "github.com/TwinProduction/gatus/core" - "github.com/TwinProduction/gatus/storage/store/common" - "github.com/TwinProduction/gatus/storage/store/common/paging" + "github.com/TwinProduction/gatus/v3/core" + "github.com/TwinProduction/gatus/v3/storage/store/common" + "github.com/TwinProduction/gatus/v3/storage/store/common/paging" ) var ( diff --git a/storage/store/store.go b/storage/store/store.go index dc9e34af..2641ad56 100644 --- a/storage/store/store.go +++ b/storage/store/store.go @@ -3,10 +3,10 @@ package store import ( "time" - "github.com/TwinProduction/gatus/core" - "github.com/TwinProduction/gatus/storage/store/common/paging" - "github.com/TwinProduction/gatus/storage/store/memory" - "github.com/TwinProduction/gatus/storage/store/sql" + "github.com/TwinProduction/gatus/v3/core" + "github.com/TwinProduction/gatus/v3/storage/store/common/paging" + "github.com/TwinProduction/gatus/v3/storage/store/memory" + "github.com/TwinProduction/gatus/v3/storage/store/sql" ) // Store is the interface that each stores should implement diff --git a/storage/store/store_bench_test.go b/storage/store/store_bench_test.go index fa4de7e5..a2cb1717 100644 --- a/storage/store/store_bench_test.go +++ b/storage/store/store_bench_test.go @@ -4,10 +4,10 @@ import ( "testing" "time" - "github.com/TwinProduction/gatus/core" - "github.com/TwinProduction/gatus/storage/store/common/paging" - "github.com/TwinProduction/gatus/storage/store/memory" - "github.com/TwinProduction/gatus/storage/store/sql" + "github.com/TwinProduction/gatus/v3/core" + "github.com/TwinProduction/gatus/v3/storage/store/common/paging" + "github.com/TwinProduction/gatus/v3/storage/store/memory" + "github.com/TwinProduction/gatus/v3/storage/store/sql" ) func BenchmarkStore_GetAllServiceStatuses(b *testing.B) { diff --git a/storage/store/store_test.go b/storage/store/store_test.go index 06747813..9b733e06 100644 --- a/storage/store/store_test.go +++ b/storage/store/store_test.go @@ -4,11 +4,11 @@ import ( "testing" "time" - "github.com/TwinProduction/gatus/core" - "github.com/TwinProduction/gatus/storage/store/common" - "github.com/TwinProduction/gatus/storage/store/common/paging" - "github.com/TwinProduction/gatus/storage/store/memory" - "github.com/TwinProduction/gatus/storage/store/sql" + "github.com/TwinProduction/gatus/v3/core" + "github.com/TwinProduction/gatus/v3/storage/store/common" + "github.com/TwinProduction/gatus/v3/storage/store/common/paging" + "github.com/TwinProduction/gatus/v3/storage/store/memory" + "github.com/TwinProduction/gatus/v3/storage/store/sql" ) var ( diff --git a/watchdog/alerting.go b/watchdog/alerting.go index 05672cf7..6eff9ee1 100644 --- a/watchdog/alerting.go +++ b/watchdog/alerting.go @@ -4,9 +4,9 @@ import ( "encoding/json" "log" - "github.com/TwinProduction/gatus/alerting" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/alerting" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/core" ) // HandleAlerting takes care of alerts to resolve and alerts to trigger based on result success or failure diff --git a/watchdog/alerting_test.go b/watchdog/alerting_test.go index 7dd396f5..dbcf7e49 100644 --- a/watchdog/alerting_test.go +++ b/watchdog/alerting_test.go @@ -4,12 +4,12 @@ import ( "os" "testing" - "github.com/TwinProduction/gatus/alerting" - "github.com/TwinProduction/gatus/alerting/alert" - "github.com/TwinProduction/gatus/alerting/provider/custom" - "github.com/TwinProduction/gatus/alerting/provider/pagerduty" - "github.com/TwinProduction/gatus/config" - "github.com/TwinProduction/gatus/core" + "github.com/TwinProduction/gatus/v3/alerting" + "github.com/TwinProduction/gatus/v3/alerting/alert" + "github.com/TwinProduction/gatus/v3/alerting/provider/custom" + "github.com/TwinProduction/gatus/v3/alerting/provider/pagerduty" + "github.com/TwinProduction/gatus/v3/config" + "github.com/TwinProduction/gatus/v3/core" ) func TestHandleAlerting(t *testing.T) { diff --git a/watchdog/watchdog.go b/watchdog/watchdog.go index 14f9bfe8..faf28a82 100644 --- a/watchdog/watchdog.go +++ b/watchdog/watchdog.go @@ -6,12 +6,12 @@ import ( "sync" "time" - "github.com/TwinProduction/gatus/alerting" - "github.com/TwinProduction/gatus/config" - "github.com/TwinProduction/gatus/config/maintenance" - "github.com/TwinProduction/gatus/core" - "github.com/TwinProduction/gatus/metric" - "github.com/TwinProduction/gatus/storage" + "github.com/TwinProduction/gatus/v3/alerting" + "github.com/TwinProduction/gatus/v3/config" + "github.com/TwinProduction/gatus/v3/config/maintenance" + "github.com/TwinProduction/gatus/v3/core" + "github.com/TwinProduction/gatus/v3/metric" + "github.com/TwinProduction/gatus/v3/storage" ) var (