diff --git a/CHANGELOG.md b/CHANGELOG.md index 5010b572c98..6f911729cc1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -15,10 +15,13 @@ * **OpenTSDB**: Support nested template variables in tag_values function, closes [4398](https://github.com/grafana/grafana/issues/4398) * **Datasource**: Pending data source requests are cancelled before new ones are issues (Graphite & Prometheus), closes [5321](https://github.com/grafana/grafana/issues/5321) -## Breaking changes +### Breaking changes * **Logging** : Changed default logging output format (now structured into message, and key value pairs, with logger key acting as component). You can also no change in config to json log ouput. * **Graphite** : The Graph panel no longer have a Graphite PNG option. closes #[5367](https://github.com/grafana/grafana/issues/5367) +### Bug fixes +* **PNG rendering**: Fixed phantomjs rendering and y-axis label rotation. fixes #[5220](https://github.com/grafana/grafana/issues/5220) + # 3.0.4 Patch release (2016-05-25) * **Panel**: Fixed blank dashboard issue when switching to other dashboard while in fullscreen edit mode, fixes [#5163](https://github.com/grafana/grafana/pull/5163) * **Templating**: Fixed issue with nested multi select variables and cascading and updating child variable selection state, fixes [#4861](https://github.com/grafana/grafana/pull/4861) diff --git a/circle.yml b/circle.yml index 02f9f91e103..ee19b50ee46 100644 --- a/circle.yml +++ b/circle.yml @@ -1,6 +1,6 @@ machine: node: - version: 4.0 + version: 5.11.1 environment: GOPATH: "/home/ubuntu/.go_workspace" ORG_PATH: "github.com/grafana" diff --git a/package.json b/package.json index 3e3cd2faeac..9094cdf9172 100644 --- a/package.json +++ b/package.json @@ -50,7 +50,7 @@ "karma-phantomjs-launcher": "1.0.0", "load-grunt-tasks": "3.4.0", "mocha": "2.3.4", - "phantomjs-prebuilt": "^2.1.3", + "phantomjs-prebuilt": "^2.1.7", "reflect-metadata": "0.1.2", "rxjs": "5.0.0-beta.4", "sass-lint": "^1.6.0", diff --git a/pkg/api/api.go b/pkg/api/api.go index 3a62e3aff3d..8e6f4067de4 100644 --- a/pkg/api/api.go +++ b/pkg/api/api.go @@ -34,6 +34,7 @@ func Register(r *macaron.Macaron) { r.Get("/org/", reqSignedIn, Index) r.Get("/org/new", reqSignedIn, Index) r.Get("/datasources/", reqSignedIn, Index) + r.Get("/datasources/new", reqSignedIn, Index) r.Get("/datasources/edit/*", reqSignedIn, Index) r.Get("/org/users/", reqSignedIn, Index) r.Get("/org/apikeys/", reqSignedIn, Index) diff --git a/pkg/api/dataproxy.go b/pkg/api/dataproxy.go index f2dee2b3479..8c2e134f3af 100644 --- a/pkg/api/dataproxy.go +++ b/pkg/api/dataproxy.go @@ -63,8 +63,6 @@ func NewReverseProxy(ds *m.DataSource, proxyPath string, targetUrl *url.URL) *ht req.Header.Add("Authorization", dsAuth) } - time.Sleep(time.Second * 5) - // clear cookie headers req.Header.Del("Cookie") req.Header.Del("Set-Cookie") diff --git a/pkg/services/search/handlers.go b/pkg/services/search/handlers.go index a8344ba05a5..a4905d6fa58 100644 --- a/pkg/services/search/handlers.go +++ b/pkg/services/search/handlers.go @@ -44,7 +44,6 @@ func searchHandler(query *Query) error { IsStarred: query.IsStarred, OrgId: query.OrgId, DashboardIds: query.DashboardIds, - Limit: query.Limit, } if err := bus.Dispatch(&dashQuery); err != nil { diff --git a/pkg/services/search/models.go b/pkg/services/search/models.go index ada3e1ccdfa..159637013f5 100644 --- a/pkg/services/search/models.go +++ b/pkg/services/search/models.go @@ -42,7 +42,6 @@ type FindPersistedDashboardsQuery struct { UserId int64 IsStarred bool DashboardIds []int - Limit int Result HitList } diff --git a/pkg/services/sqlstore/dashboard.go b/pkg/services/sqlstore/dashboard.go index 3fac1672dff..fbf245a951b 100644 --- a/pkg/services/sqlstore/dashboard.go +++ b/pkg/services/sqlstore/dashboard.go @@ -123,11 +123,6 @@ type DashboardSearchProjection struct { } func SearchDashboards(query *search.FindPersistedDashboardsQuery) error { - limit := query.Limit - if limit == 0 { - limit = 1000 - } - var sql bytes.Buffer params := make([]interface{}, 0) @@ -170,8 +165,7 @@ func SearchDashboards(query *search.FindPersistedDashboardsQuery) error { params = append(params, "%"+query.Title+"%") } - sql.WriteString(fmt.Sprintf(" ORDER BY dashboard.title ASC LIMIT ?")) - params = append(params, limit) + sql.WriteString(fmt.Sprintf(" ORDER BY dashboard.title ASC LIMIT 1000")) var res []DashboardSearchProjection diff --git a/pkg/services/sqlstore/migrations/dashboard_mig.go b/pkg/services/sqlstore/migrations/dashboard_mig.go index 536b153c6c9..38c25a315f2 100644 --- a/pkg/services/sqlstore/migrations/dashboard_mig.go +++ b/pkg/services/sqlstore/migrations/dashboard_mig.go @@ -107,4 +107,8 @@ func addDashboardMigration(mg *Migrator) { mg.AddMigration("Add column gnetId in dashboard", NewAddColumnMigration(dashboardV2, &Column{ Name: "gnet_id", Type: DB_BigInt, Nullable: true, })) + + mg.AddMigration("Add index for gnetId in dashboard", NewAddIndexMigration(dashboardV2, &Index{ + Cols: []string{"gnet_id"}, Type: IndexType, + })) } diff --git a/public/app/core/profiler.ts b/public/app/core/profiler.ts index 08e5ea457ab..6505cd0405f 100644 --- a/public/app/core/profiler.ts +++ b/public/app/core/profiler.ts @@ -99,7 +99,9 @@ export class Profiler { } renderingCompleted(panelId, panelTimings) { - this.panelsRendered++; + // add render counter to root scope + // used by phantomjs render.js to know when panel has rendered + this.$rootScope.panelsRendered = this.panelsRendered++; if (this.enabled) { panelTimings.renderEnd = new Date().getTime(); diff --git a/public/app/features/dashboard/import/dash_import.ts b/public/app/features/dashboard/import/dash_import.ts index 264df3cd5a9..a0856814e94 100644 --- a/public/app/features/dashboard/import/dash_import.ts +++ b/public/app/features/dashboard/import/dash_import.ts @@ -69,9 +69,7 @@ export class DashImportCtrl { if (sources.length === 0) { inputModel.info = "No data sources of type " + input.pluginName + " found"; - } else if (inputModel.description) { - inputModel.info = inputModel.description; - } else { + } else if (!inputModel.info) { inputModel.info = "Select a " + input.pluginName + " data source"; } diff --git a/public/app/features/dashboard/shareModalCtrl.js b/public/app/features/dashboard/shareModalCtrl.js index 462812efa29..36949f51f5b 100644 --- a/public/app/features/dashboard/shareModalCtrl.js +++ b/public/app/features/dashboard/shareModalCtrl.js @@ -75,7 +75,7 @@ function (angular, _, require, config) { var soloUrl = $scope.shareUrl; soloUrl = soloUrl.replace(config.appSubUrl + '/dashboard/', config.appSubUrl + '/dashboard-solo/'); - soloUrl = soloUrl.replace("&fullscreen", ""); + soloUrl = soloUrl.replace("&fullscreen", "").replace("&edit", ""); $scope.iframeHtml = ''; diff --git a/public/app/features/plugins/ds_edit_ctrl.ts b/public/app/features/plugins/ds_edit_ctrl.ts index a3e78c33a15..0f234fb6b90 100644 --- a/public/app/features/plugins/ds_edit_ctrl.ts +++ b/public/app/features/plugins/ds_edit_ctrl.ts @@ -166,7 +166,17 @@ coreModule.controller('DataSourceEditCtrl', DataSourceEditCtrl); coreModule.directive('datasourceHttpSettings', function() { return { - scope: {current: "="}, - templateUrl: 'public/app/features/plugins/partials/ds_http_settings.html' + scope: { + current: "=", + suggestUrl: "@", + }, + templateUrl: 'public/app/features/plugins/partials/ds_http_settings.html', + link: { + pre: function($scope, elem, attrs) { + $scope.getSuggestUrls = function() { + return [$scope.suggestUrl]; + }; + } + } }; }); diff --git a/public/app/features/plugins/partials/ds_http_settings.html b/public/app/features/plugins/partials/ds_http_settings.html index 08d2af5744a..0022f6e6c19 100644 --- a/public/app/features/plugins/partials/ds_http_settings.html +++ b/public/app/features/plugins/partials/ds_http_settings.html @@ -6,7 +6,10 @@
Specify a complete HTTP url (for example http://your_server:8080)
@@ -57,7 +60,7 @@