|
@@ -2,6 +2,7 @@ package postgres
|
|
|
|
|
|
|
|
import (
|
|
import (
|
|
|
"database/sql"
|
|
"database/sql"
|
|
|
|
|
+ "github.com/grafana/grafana/pkg/setting"
|
|
|
"net/url"
|
|
"net/url"
|
|
|
"strconv"
|
|
"strconv"
|
|
|
|
|
|
|
@@ -19,7 +20,9 @@ func newPostgresQueryEndpoint(datasource *models.DataSource) (tsdb.TsdbQueryEndp
|
|
|
logger := log.New("tsdb.postgres")
|
|
logger := log.New("tsdb.postgres")
|
|
|
|
|
|
|
|
cnnstr := generateConnectionString(datasource)
|
|
cnnstr := generateConnectionString(datasource)
|
|
|
- logger.Debug("getEngine", "connection", cnnstr)
|
|
|
|
|
|
|
+ if setting.Env == setting.DEV {
|
|
|
|
|
+ logger.Debug("getEngine", "connection", cnnstr)
|
|
|
|
|
+ }
|
|
|
|
|
|
|
|
config := tsdb.SqlQueryEndpointConfiguration{
|
|
config := tsdb.SqlQueryEndpointConfiguration{
|
|
|
DriverName: "postgres",
|
|
DriverName: "postgres",
|