diff --git a/docs/sources/installation/configuration.md b/docs/sources/installation/configuration.md index 20f191b26e1..943916410b5 100644 --- a/docs/sources/installation/configuration.md +++ b/docs/sources/installation/configuration.md @@ -203,6 +203,12 @@ For MySQL, use either `true`, `false`, or `skip-verify`. (MySQL only) The common name field of the certificate used by the `mysql` server. Not necessary if `ssl_mode` is set to `skip-verify`. +### max_idle_conn +The maximum number of connections in the idle connection pool. + +### max_open_conn +The maximum number of open connections to the database. +
## [security] diff --git a/pkg/api/api.go b/pkg/api/api.go index c74f00aade5..1131088f103 100644 --- a/pkg/api/api.go +++ b/pkg/api/api.go @@ -304,6 +304,7 @@ func (hs *HttpServer) registerRoutes() { }, reqEditorRole) r.Get("/annotations", wrap(GetAnnotations)) + r.Post("/annotations/mass-delete", reqOrgAdmin, bind(dtos.DeleteAnnotationsCmd{}), wrap(DeleteAnnotations)) r.Group("/annotations", func() { r.Post("/", bind(dtos.PostAnnotationsCmd{}), wrap(PostAnnotation)) diff --git a/pkg/tsdb/mysql/mysql.go b/pkg/tsdb/mysql/mysql.go index d4bd9dbacc1..367124a46b8 100644 --- a/pkg/tsdb/mysql/mysql.go +++ b/pkg/tsdb/mysql/mysql.go @@ -183,6 +183,7 @@ func (e MysqlExecutor) getTypedRowData(types []*sql.ColumnType, rows *core.Rows) values := make([]interface{}, len(types)) for i, stype := range types { + e.log.Info("type", "type", stype) switch stype.DatabaseTypeName() { case mysql.FieldTypeNameTiny: values[i] = new(int8) @@ -209,7 +210,7 @@ func (e MysqlExecutor) getTypedRowData(types []*sql.ColumnType, rows *core.Rows) case mysql.FieldTypeNameDateTime: values[i] = new(time.Time) case mysql.FieldTypeNameTime: - values[i] = new(time.Duration) + values[i] = new(string) case mysql.FieldTypeNameYear: values[i] = new(int16) case mysql.FieldTypeNameNULL: @@ -307,6 +308,9 @@ func (s *stringStringScan) Update(rows *sql.Rows) error { return err } + s.time = null.FloatFromPtr(nil) + s.value = null.FloatFromPtr(nil) + for i := 0; i < s.columnCount; i++ { if rb, ok := s.rowPtrs[i].(*sql.RawBytes); ok { s.rowValues[i] = string(*rb) diff --git a/public/app/core/components/form_dropdown/form_dropdown.ts b/public/app/core/components/form_dropdown/form_dropdown.ts index d8212e2f55c..1c611e94397 100644 --- a/public/app/core/components/form_dropdown/form_dropdown.ts +++ b/public/app/core/components/form_dropdown/form_dropdown.ts @@ -30,6 +30,7 @@ export class FormDropdownCtrl { optionCache: any; lookupText: boolean; + /** @ngInject **/ constructor(private $scope, $element, private $sce, private templateSrv, private $q) { this.inputElement = $element.find('input').first(); this.linkElement = $element.find('a').first(); diff --git a/public/app/features/dashboard/save_modal.ts b/public/app/features/dashboard/save_modal.ts index 01a42655a5f..36bae222243 100644 --- a/public/app/features/dashboard/save_modal.ts +++ b/public/app/features/dashboard/save_modal.ts @@ -29,8 +29,7 @@ const template = ` ng-model="ctrl.message" ng-model-options="{allowInvalid: true}" ng-maxlength="this.max" - autocomplete="off" - required /> + autocomplete="off" /> {{ctrl.message.length || 0}} diff --git a/public/app/features/panel/metrics_tab.ts b/public/app/features/panel/metrics_tab.ts index c03c4d83bc2..e1825173172 100644 --- a/public/app/features/panel/metrics_tab.ts +++ b/public/app/features/panel/metrics_tab.ts @@ -1,7 +1,6 @@ /// import _ from 'lodash'; -//import {coreModule} from 'app/core/core'; import {DashboardModel} from '../dashboard/model'; export class MetricsTabCtrl { @@ -32,7 +31,6 @@ export class MetricsTabCtrl { } this.addQueryDropdown = {text: 'Add Query', value: null, fake: true}; - // update next ref id this.panelCtrl.nextRefId = this.dashboard.getNextQueryLetter(this.panel); } @@ -80,4 +78,3 @@ export function metricsTabDirective() { }; } -//coreModule.directive('metricsTab', metricsTabDirective); diff --git a/public/sass/components/_gf-form.scss b/public/sass/components/_gf-form.scss index e9e41a16b02..ff082deee3d 100644 --- a/public/sass/components/_gf-form.scss +++ b/public/sass/components/_gf-form.scss @@ -115,6 +115,9 @@ $gf-form-margin: 0.25rem; @include border-radius($input-border-radius-sm); @include box-shadow($input-box-shadow); transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s; + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; // Unstyle the caret on `