gofmt
diff --git a/init.go b/init.go index 0dad568..4ff6d3c 100644 --- a/init.go +++ b/init.go
@@ -18,10 +18,10 @@ "fmt" "github.com/apid/apid-core" "github.com/apid/apid-core/util" + "net/http" "os" "path/filepath" "sync" - "net/http" "time" ) @@ -66,7 +66,7 @@ events apid.EventsService unsafeDB apid.DB dbMux sync.RWMutex - client *http.Client + client *http.Client localAnalyticsBaseDir string localAnalyticsTempDir string @@ -187,7 +187,7 @@ config.SetDefault(analyticsBufferChannelSize, analyticsBufferChannelSizeDefault) client = &http.Client{ - Transport: util.Transport(config.GetString(configfwdProxyPortURL)), + Transport: util.Transport(config.GetString(util.ConfigfwdProxyPortURL)), //set default timeout of 60 seconds while connecting to s3/GCS Timeout: time.Duration(60 * time.Second), }
diff --git a/uploader.go b/uploader.go index e77fd0b..98db172 100644 --- a/uploader.go +++ b/uploader.go
@@ -26,11 +26,9 @@ ) const timestampLayout = "20060102150405" // same as yyyyMMddHHmmss -const configfwdProxyPortURL = "configcompletefwdp" + var token string - - func addHeaders(req *http.Request) { token = config.GetString("apigeesync_bearer_token") req.Header.Add("Authorization", "Bearer "+token)