Skip to content
This repository has been archived by the owner on Mar 17, 2021. It is now read-only.

Commit

Permalink
Add Stackdriver datasource config options (#42)
Browse files Browse the repository at this point in the history
* add Stackdriver datasource config options

* remove newline
  • Loading branch information
mlclmj authored Apr 16, 2020
1 parent cd94108 commit df50c0d
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions datasource.go
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,12 @@ type JSONData struct {
// Used by Prometheus
HttpMethod string `json:"httpMethod,omitempty"`
QueryTimeout string `json:"queryTimeout,omitempty"`

// Used by Stackdriver
AuthenticationType string `json:"authenticationType,omitempty"`
ClientEmail string `json:"clientEmail,omitempty"`
DefaultProject string `json:"defaultProject,omitempty"`
TokenUri string `json:"tokenUri,omitempty"`
}

// SecureJSONData is a representation of the datasource `secureJsonData` property
Expand All @@ -92,6 +98,9 @@ type SecureJSONData struct {
// Used by Cloudwatch
AccessKey string `json:"accessKey,omitempty"`
SecretKey string `json:"secretKey,omitempty"`

// Used by Stackdriver
PrivateKey string `json:"privateKey,omitempty"`
}

func (c *Client) NewDataSource(s *DataSource) (int64, error) {
Expand Down

0 comments on commit df50c0d

Please sign in to comment.