Commit Graph

26 Commits (2fca9efdf027b57d1711582d26ab9d7107945ef3)

Author SHA1 Message Date
Iris Scholten dcb18134be make empty axes bounds [,] instead of [] 2018-02-23 16:24:54 -08:00
Chris Goller e55b8116f7 Update cell defaults to use empty array 2018-02-05 17:04:15 -06:00
Chris Goller 3babccfa0c Fix cell race condition 2018-02-05 14:50:05 -06:00
Chris Goller 5ccab143b7 Add legend to dashboard cells 2018-02-05 14:25:57 -06:00
Alex P 367c3d61ba Merge branch 'master' into single-stat-colors-polish 2017-12-20 17:59:52 -08:00
Nathan Haugo ce45f13cdc Merge pull request #2593 from influxdata/feature/dashboard-filestore
Add filesystem backed dashboard and organization stores
2017-12-19 14:36:19 -08:00
Chris Goller e39ddeddcf Fix cell replacement to return query config 2017-12-19 13:43:39 -06:00
Chris Goller a6ef15ee54 Add multiple dashboard stores to server 2017-12-19 10:07:07 -08:00
Alex P bd3aec99ad Allow users to toggle between coloring text or background with single stat thresholds 2017-12-14 19:07:19 -08:00
Jared Scheib 31f012ff8f Merge branch 'master' into multitenancy 2017-12-06 19:05:16 -08:00
Jared Scheib c9e579acb2 Merge remote-tracking branch 'origin/master' into multitenancy 2017-12-05 11:43:23 -08:00
Chris Goller 3a07920d4c Merge branch 'master' into gauge-cell-type
Conflicts:
	bolt/internal/internal.pb.go
	bolt/internal/internal.proto
	server/cells.go
2017-11-27 16:08:42 -06:00
Andrew Watkins 5280589505 Handle nil cell in validateDashboardRequest 2017-11-21 11:27:48 -08:00
Chris Goller 8181e1eaf7 Add colors to all cells 2017-11-21 12:16:23 -06:00
Andrew Watkins 4880e876ee Add processing of incoming queryConfig 2017-11-10 16:02:08 -08:00
Andrew Watkins e98e1896ae WIP Add shifts to queryConifg on backend 2017-11-10 11:06:48 -08:00
Michael Desa 36e14cb111 Refactor data stores into a common interface 2017-10-31 16:41:17 -04:00
Tim Raymond f8580d907e Refactor set membership validation
The pattern of using a select with a list of options and a default that
returns an error isn't bad for a one-off validation:

select myProp {
  case "validOption1", "validOption2":
    // no-op
  default:
    panic("invalid!")
}

However, we're doing this multiple times in this method, so it makes
sense to pull this out into a new method to make it clearer what's
happening.

This adds a `oneOf` function that takes some property and a variadic
list of valid options and reports whether or not that property is among
that list.
2017-08-24 15:45:51 -04:00
Tim Raymond c24db57385 Add validation around Base and Scale
The Base and Scale options on axes can only be one of two parameters. We
weren't validating that this was the case. This patch ensures that Base
can only ever be "10" or "2", and Scale must be either "linear" or
"log".

Associated test coverage was also added.
2017-08-24 15:37:19 -04:00
Tim Raymond 74f464800d Fix missing cell type
Because we are now creating new instances of dashboards when we create a
response, it's critical to copy every element of Dashboards from the
previous to the new instance.

We were not previously copying the Type field of cells, so this was
defaulting to the empty string zero value. This patch adds "Type" to the
tests and ensures that it's properly copied
2017-08-14 13:41:31 -04:00
Tim Raymond 7aad733682 Fix data races in dashboard response construction
Dashboard responses had data races because multiple goroutines were
reading and modifying dashboards before sending them out on the wire.
This patch introduces immutability in the construction of the response,
so that each goroutine is working with its own set of dashboardResponse
structs.
2017-07-31 16:36:20 -04:00
Tim Raymond 08bf8aeff5 Ensure cell bounds come back as empty array
The contract with the frontend states that bounds should come back as an
empty array instead of null when there are no bounds present. We must
explicitly specify []string{} for this to happen.
2017-07-31 16:36:16 -04:00
Tim Raymond 4391004e7f Enforce presence of "x", "y", and "y2" axes
Certain aspects of the frontend requires the presence of these three
axes, so part of the contract established is that the backend will
always provide them. Since we centralize creation of
dashboardCellResponses, this is where these axes are added to all cell
responses.

Additionally, because there was previously no coverage over the
dashboard cells endpoints, a test has been added to cover the
DashboardCells method of Service.
2017-07-31 16:36:07 -04:00
Tim Raymond ee6a2fa54b Enforce only "x", "y", and "y2" axes
For the forseeable future, we will only be using the "x", "y", and "y2"
axes, even though the underlying serialization can support arbitrary
axes (for the future).

This ensures that only "x", "y", and "y2" axes are present and updates
the Swagger docs to reflect that fact
2017-07-21 12:09:49 -04:00
Chris Goller 2018f7300a Add initial template CRUD operations 2017-04-20 11:09:56 -05:00
Chris Goller c141709451 Move dashboard cells into cells.go 2017-04-20 09:24:57 -05:00