Commit Graph

41 Commits (15dbecfb0fb795a6fd02cc1cd5ea0c7db573953a)

Author SHA1 Message Date
greg linton 1a612ffa22 feat: add migrate command to chronoctl
adds a command to migrate a db from bolt to etcd and visa versa. there
is no promise that the options/functionality will not change, hence the
'beta' note. obviously there is also no guarantee that there will never
be any data loss.
after several manual tests, i do have a high level of confidence in the
functionality presented.
2020-02-03 20:43:44 -07:00
greg linton d470723faf chore: tidy and document filestore functionality 2020-01-21 13:57:09 -07:00
greg linton a26b780036 chore: remove v2 related code 2020-01-21 13:57:09 -07:00
Greg 1806d6c298
chore: tidy prior to kv refactor (#5342)
* Start cleaning up/reviewing for kv refactor

* Remove dependency on graceful http layer

* Remove deprecated cli option --new-sources

* Run gofmt and remove dep related files

* Update non-influx deps

* Update kapacitor dep

* Compile regexp's once

* Remove un-needed struct members

* Remove unused integrations code
2020-01-09 08:49:42 -07:00
Jared Scheib f57daa8bc5 feat: protoboard api
Co-authored-by: Deniz Kusefoglu <deniz@influxdata.com>
Co-authored-by: Jared Scheib <jared.scheib@gmail.com>
2018-08-14 14:29:10 -07:00
Michael Desa 9191d18394 feat(mocks): add mock implementation of dashboard service 2018-07-18 10:39:05 -04:00
Michael Desa 83ac886bf3 fix(mocks): use platform package instead of chronografv2 2018-07-16 13:00:31 -04:00
Michael Desa f3f722d987 test(mocks): add mock cell service 2018-07-16 11:25:15 -04:00
Alirie Gray 0f810debcb Rename org config method Update to Put for semantic accuracy
Co-authored-by: Jared Scheib <jared.scheib@gmail.com>
2018-07-10 15:42:44 -07:00
Alirie Gray 874110bd5e Rename org config receivers and function params to be more conventional
Co-authored-by: Jared Scheib <jared.scheib@gmail.com>
2018-07-10 15:32:23 -07:00
Jared Scheib ed07f9e2e4 Remove unnecessary comments
Co-authored-by: Alirie Gray <alirie.gray@gmail.com>
2018-07-09 17:37:30 -07:00
Jared Scheib ae475c7ae8 Add OrganizationConfigStore & refactor org config to be per org
As previously implemented, OrganizationConfig was a global
object. This refactor adds the organization id to context for
every request, even when auth is disabled, so that org id
can be used to get/update an organization config.

Along those lines, this also removes OrganizationConfigStore
.Initialize and replaces .Get with .FindOrCreate, handling
the creation of organization configs upon first attempted
access.

Co-authored-by: Jared Scheib <jared.scheib@gmail.com>
2018-07-09 17:36:19 -07:00
Jared Scheib 8ccf582acc Rename db & rp vars & url params for clarity & consistency
Updates swagger as well.
Clarify that instead of dbid and rpid, these values are names.
Rename the var for the Databases service to dbsvc.
2018-04-04 14:22:08 -07:00
Jared Scheib 50ceafc900 Correct GetMeasurements comments to indicate default 100 limit 2018-04-03 16:04:16 -07:00
Jared Scheib 3727caf5fd WIP Test GetMeasurements
Create Databases mocks
Add comments to chronograf.Databases methods
2018-04-03 16:04:16 -07:00
Chris Goller c1043b1938 Update timeseries interface to write multiple points 2018-02-27 13:27:17 -06:00
Chris Goller d7b7914241 Add tests for annotation store 2018-02-17 12:30:55 -06:00
Luke Morris 59b6979812 Merge branch 'master' into feature/annotationz-pre-pl-with-master 2018-02-15 12:03:10 -08:00
Michael Desa 8b60388d81 Add correct implementation of mappings 2018-02-05 14:54:39 -05:00
Chris Goller 243ccb1ffb Add basic REST routes for annotations 2018-01-12 17:17:14 -06:00
Luke Morris fcdc4efb2c Backup/Migrate/Initialize moved into Open
Signed-off-by: Chris Goller <goller@gmail.com>
2017-12-18 12:06:17 -08:00
Michael Desa d875757ce3 Add bolt implementation of chronograf.ConfigStore 2017-12-13 10:38:01 -08:00
Michael de Sa fcd25ad580 Implement Config GET service method
Signed-off-by: Jared Scheib <jared.scheib@gmail.com>
2017-12-12 17:06:57 -08:00
Michael Desa e27936ee69 Add Num to UsersStore interface 2017-11-30 12:55:59 -05:00
Michael Desa 3370774e8f Add default org logic to OrganizationsStore
Update resource handlers to appropriate consume default organization IDs
2017-11-06 10:14:12 -05:00
Michael Desa d7b981987c Remove RawUsers from DataStore 2017-10-31 17:49:35 -04:00
Michael Desa 5f63e2738a Refactor data stores into a common interface 2017-10-31 16:41:17 -04:00
Jared Scheib 7ffbf5dd98 Move Mock Authenticator into mocks package
Signed-off-by: Michael de Sa <mjdesa@gmail.com>
2017-10-26 15:46:06 -07:00
Jared Scheib 30b8d3cdca Make all Store names plural for consistency 2017-10-24 15:54:24 -07:00
Michael Desa d220fc3e5e Add tests for server/organizations.go 2017-10-23 14:16:52 -04:00
Michael Desa 0d235f646d Generalize chronograf.UsersStore Get method
The `Get` method on the UsersStore was generalize by changing the second
parameter to a struct. This allows the Store to retrieve users by more
than simply their name.

-Get(ctx context.Context, name string) (*User, error)
+Get(ctx context.Context, q UserQuery) (*User, error)
2017-10-18 14:17:42 -04:00
Tim Raymond 2c4d02912d Merge branch 'master' into feature/tr-kapa-rule-pagination 2017-08-23 16:44:59 -04:00
Tim Raymond d0be50ab37
Add PaginatingKapacitorClient
The kapacitor client used in the kapacitor endpoints is limited to
fetching whatever limit you provide it. If you provide no limit, it
defaults to a limit of 100. We use this default behavior currently.

Some users have more than 100 tasks, so we need a client that's capable
of continually fetching tasks from Kapacitor until there are none left,
and returning the full response to the frontend.

This introduces a PaginatingKapacitorClient which does exactly that.
Also, test coverage was added around the KapacitorRulesGet endpoint,
since it was previously untested.
2017-08-15 16:55:47 -04:00
Tim Raymond 12ea15d356
Add test coverage to /layouts endpoint
In anticipation of adding Axes to cells, I wanted some test coverage to
be in place before I made the change.

This covers the happy path case as well as focusing on individual
applications. To come are focusing on a measurement and a test for when
the store is unavailable.
2017-08-10 13:52:26 -07:00
Tim Raymond 8bd622c491
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
Jared Scheib 0855fc434b Add test for creating NewSources via server flag
Move TestLogger to mocks

Signed-off-by: Tim Raymond <tim@timraymond.com>
2017-07-07 12:56:12 -07:00
Chris Goller 27b50fde22 Update schema for /permissions endpoint to have scopes 2017-02-27 13:31:38 -06:00
Chris Goller a4a5b53bf5 Add roles endpoint and switching between OSS and enterprise 2017-02-23 21:54:20 -06:00
Chris Goller 5aa6a4ef2b Add roles to chronograf 2017-02-23 16:02:53 -06:00
Chris Goller 72dbae043f Add tests to sources/users endpoints 2017-02-21 23:54:24 -06:00
Chris Goller 083b8905ec Add mock usersstore.
Mocks are back!
2017-02-21 21:36:04 -06:00