feat: add influx support(not implement test case) and has some todo item#281
Open
Belyenochi wants to merge 2 commits intogocrane:mainfrom
Open
feat: add influx support(not implement test case) and has some todo item#281Belyenochi wants to merge 2 commits intogocrane:mainfrom
Belyenochi wants to merge 2 commits intogocrane:mainfrom
Conversation
Author
|
To be implemented test case, it is expected to initiate a formal merger tomorrow. @yufeiyu |
Contributor
|
Please make sure all checks passed. |
lbbniu
reviewed
May 7, 2022
| import ( | ||
| "context" | ||
| "flag" | ||
| "github.com/gocrane/crane/pkg/providers/influxdb" |
lbbniu
reviewed
May 7, 2022
| package influxdb | ||
|
|
||
| import ( | ||
| gocontext "context" |
jordy1024
reviewed
Jun 20, 2022
Comment on lines
+3
to
+11
| import ( | ||
| gocontext "context" | ||
| "github.com/gocrane/crane/pkg/common" | ||
| "github.com/gocrane/crane/pkg/metricnaming" | ||
| "github.com/gocrane/crane/pkg/metricquery" | ||
| "github.com/gocrane/crane/pkg/providers" | ||
| "k8s.io/klog/v2" | ||
| "time" | ||
| ) |
There was a problem hiding this comment.
Suggeset to follow a policy of grouping imports in 3~4 groups,e.g.:
import (
build-in-stdlib
current project/repo
all others
)
prefer:
import (
"time"
gocontext "context"
"github.com/gocrane/crane/pkg/common"
"github.com/gocrane/crane/pkg/metricnaming"
"github.com/gocrane/crane/pkg/metricquery"
"github.com/gocrane/crane/pkg/providers"
"k8s.io/klog/v2"
)
| } | ||
|
|
||
|
|
||
| func (i *influxDB) QueryTimeSeries(namer metricnaming.MetricNamer, startTime time.Time, endTime time.Time, step time.Duration) ([]*common.TimeSeries, error) { |
There was a problem hiding this comment.
Exported type or method should have comment or be unexported:
// QueryTimeSeries xxx xxx
func (i *influxDB) QueryTimeSeries(......
| return timeSeries, nil | ||
| } | ||
|
|
||
| func (i *influxDB) QueryLatestTimeSeries(namer metricnaming.MetricNamer) ([]*common.TimeSeries, error) { |
Author
|
Sorry, I didn't fully finish this PR before, I will re-update this PR this weekend. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What type of PR is this?
support influxDB, solved #119