Skip to content

Commit

Permalink
Merge pull request #209 from openinfradev/fix_thanos_debug
Browse files Browse the repository at this point in the history
trivial. add log
  • Loading branch information
cho4036 authored Nov 15, 2023
2 parents cb76a2c + 861478d commit 9e595e4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion internal/route/route.go
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ func SetupRouter(db *gorm.DB, argoClient argowf.ArgoClient, kc keycloak.IKeycloa
authenticator.NewAuthenticator(authKeycloak.NewKeycloakAuthenticator(kc)),
authorizer.NewDefaultAuthorization(repoFactory))

cache := gcache.New(time.Hour, time.Hour)
cache := gcache.New(5*time.Minute, 10*time.Minute)

r.Use(loggingMiddleware)

Expand Down
2 changes: 2 additions & 0 deletions pkg/thanos-client/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ func New(host string, port int, ssl bool, token string) (ThanosClient, error) {

func (c *ThanosClientImpl) Get(query string) (out Metric, err error) {
url := c.url + "/api/v1/query?query=" + url.QueryEscape(query)

log.Info("url : ", url)
res, err := c.client.Get(url)
if err != nil {
return out, err
Expand Down

0 comments on commit 9e595e4

Please sign in to comment.