mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Fixing typos (#70487)
This commit is contained in:
committed by
GitHub
parent
1441c90178
commit
95b1f3c875
@@ -248,7 +248,7 @@ func TestHTTPServer_GetFrontendSettings_apps(t *testing.T) {
|
||||
},
|
||||
},
|
||||
{
|
||||
desc: "enalbed app with preload",
|
||||
desc: "enabled app with preload",
|
||||
pluginStore: func() plugins.Store {
|
||||
return &plugins.FakePluginStore{
|
||||
PluginList: []plugins.PluginDTO{
|
||||
|
||||
@@ -117,11 +117,11 @@ func FetchNpmPackages(ctx context.Context, tag, bucketName string) error {
|
||||
// Latest and next is 9.1.6.
|
||||
// 9.2.0-beta1 is released, the latest should stay on 9.1.6, next should point to 9.2.0-beta1
|
||||
// No move of dist-tags
|
||||
// 9.1.7 is relased, the latest should point to 9.1.7, next should stay to 9.2.0-beta1
|
||||
// 9.1.7 is released, the latest should point to 9.1.7, next should stay to 9.2.0-beta1
|
||||
// No move of dist-tags
|
||||
// Next week 9.2.0-beta2 is released, the latest should point to 9.1.7, next should point to 9.2.0-beta2
|
||||
// No move of dist-tags
|
||||
// In two weeks 9.2.0 stable is relased, the latest and next should point to 9.2.0.
|
||||
// In two weeks 9.2.0 stable is released, the latest and next should point to 9.2.0.
|
||||
// The next dist-tag is moved to point to 9.2.0.
|
||||
//
|
||||
// 3. Releasing an older stable than the current stable
|
||||
|
||||
@@ -110,7 +110,7 @@ func TestTracingConfig(t *testing.T) {
|
||||
ExpectedAttrs: []attribute.KeyValue{},
|
||||
},
|
||||
{
|
||||
Name: "legacy env variables are supproted",
|
||||
Name: "legacy env variables are supported",
|
||||
Cfg: `[tracing.jaeger]`,
|
||||
Env: map[string]string{
|
||||
"JAEGER_AGENT_HOST": "example.com",
|
||||
@@ -137,7 +137,7 @@ func TestTracingConfig(t *testing.T) {
|
||||
},
|
||||
} {
|
||||
t.Run(test.Name, func(t *testing.T) {
|
||||
// export envioronment variables
|
||||
// export environment variables
|
||||
if test.Env != nil {
|
||||
for k, v := range test.Env {
|
||||
t.Setenv(k, v)
|
||||
|
||||
@@ -31,7 +31,7 @@ type CachedResourceDataResponse struct {
|
||||
Response *backend.CallResourceResponse
|
||||
// A function that should be used to cache a CallResourceResponse for a given resource request.
|
||||
// It can be set to nil by the method implementation (if there is an error, for example), so it should be checked before being called.
|
||||
// Because plugins can send multiple responses asyncronously, the implementation should be able to handle multiple calls to this function for one request.
|
||||
// Because plugins can send multiple responses asynchronously, the implementation should be able to handle multiple calls to this function for one request.
|
||||
UpdateCacheFn CacheResourceResponseFn
|
||||
}
|
||||
|
||||
|
||||
@@ -128,7 +128,7 @@ func (fm *FeatureManager) IsEnabled(flag string) bool {
|
||||
return fm.enabled[flag]
|
||||
}
|
||||
|
||||
// GetEnabled returns a map contaning only the features that are enabled
|
||||
// GetEnabled returns a map containing only the features that are enabled
|
||||
func (fm *FeatureManager) GetEnabled(ctx context.Context) map[string]bool {
|
||||
enabled := make(map[string]bool, len(fm.enabled))
|
||||
for key, val := range fm.enabled {
|
||||
|
||||
@@ -128,7 +128,7 @@ type DeleteFolderCommand struct {
|
||||
}
|
||||
|
||||
// GetFolderQuery is used for all folder Get requests. Only one of UID, ID, or
|
||||
// Title should be set; if multilpe fields are set by the caller the dashboard
|
||||
// Title should be set; if multiple fields are set by the caller the dashboard
|
||||
// service will select the field with the most specificity, in order: ID, UID,
|
||||
// Title.
|
||||
type GetFolderQuery struct {
|
||||
|
||||
@@ -99,7 +99,7 @@ func TestProvisioningApi(t *testing.T) {
|
||||
})
|
||||
})
|
||||
|
||||
t.Run("when an unspecified error occurrs", func(t *testing.T) {
|
||||
t.Run("when an unspecified error occurs", func(t *testing.T) {
|
||||
t.Run("GET returns 500", func(t *testing.T) {
|
||||
sut := createProvisioningSrvSut(t)
|
||||
sut.policies = &fakeFailingNotificationPolicyService{}
|
||||
|
||||
@@ -334,7 +334,7 @@ func TestEvaluatorTest(t *testing.T) {
|
||||
})
|
||||
})
|
||||
|
||||
t.Run("when evalution fails", func(t *testing.T) {
|
||||
t.Run("when evaluation fails", func(t *testing.T) {
|
||||
expectedError := errors.New("test-error")
|
||||
evaluator.evalCallback = func(now time.Time) (eval.Results, error) {
|
||||
return nil, expectedError
|
||||
|
||||
@@ -354,7 +354,7 @@ func (p *redisPeer) WaitReady(ctx context.Context) error {
|
||||
}
|
||||
}
|
||||
|
||||
// Settle is mostly copied from uptream.
|
||||
// Settle is mostly copied from upstream.
|
||||
// Ref: https://github.com/prometheus/alertmanager/blob/2888649b473970400c0bd375fdd563486dc80481/cluster/cluster.go#L674-L712
|
||||
func (p *redisPeer) Settle(ctx context.Context, interval time.Duration) {
|
||||
const NumOkayRequired = 3
|
||||
|
||||
@@ -26,8 +26,8 @@ import (
|
||||
const (
|
||||
HeaderPluginID = "X-Plugin-Id" // can be used for routing
|
||||
HeaderDatasourceUID = "X-Datasource-Uid" // can be used for routing/ load balancing
|
||||
HeaderDashboardUID = "X-Dashboard-Uid" // mainly useful for debuging slow queries
|
||||
HeaderPanelID = "X-Panel-Id" // mainly useful for debuging slow queries
|
||||
HeaderDashboardUID = "X-Dashboard-Uid" // mainly useful for debugging slow queries
|
||||
HeaderPanelID = "X-Panel-Id" // mainly useful for debugging slow queries
|
||||
HeaderQueryGroupID = "X-Query-Group-Id" // mainly useful for finding related queries with query chunking
|
||||
HeaderFromExpression = "X-Grafana-From-Expr" // used by datasources to identify expression queries
|
||||
)
|
||||
|
||||
@@ -1438,7 +1438,7 @@ type EntitySearchResult struct {
|
||||
|
||||
// Entity identifier
|
||||
GRN *GRN `protobuf:"bytes,1,opt,name=GRN,proto3" json:"GRN,omitempty"`
|
||||
// The current veresion of this entity
|
||||
// The current version of this entity
|
||||
Version string `protobuf:"bytes,2,opt,name=version,proto3" json:"version,omitempty"`
|
||||
// Content Length
|
||||
Size int64 `protobuf:"varint,3,opt,name=size,proto3" json:"size,omitempty"`
|
||||
|
||||
@@ -311,7 +311,7 @@ message EntitySearchResult {
|
||||
// Entity identifier
|
||||
GRN GRN = 1;
|
||||
|
||||
// The current veresion of this entity
|
||||
// The current version of this entity
|
||||
string version = 2;
|
||||
|
||||
// Content Length
|
||||
|
||||
@@ -306,13 +306,13 @@ func parseNumber(value interface{}) *float64 {
|
||||
|
||||
number, ok := value.(json.Number)
|
||||
if !ok {
|
||||
// in the current inmplementation, errors become nils
|
||||
// in the current implementation, errors become nils
|
||||
return nil
|
||||
}
|
||||
|
||||
fvalue, err := number.Float64()
|
||||
if err != nil {
|
||||
// in the current inmplementation, errors become nils
|
||||
// in the current implementation, errors become nils
|
||||
return nil
|
||||
}
|
||||
|
||||
|
||||
@@ -48,7 +48,7 @@ func (e *StandardDeviationSampler) updateAggregations(val float64) {
|
||||
e.m2 += delta * delta2
|
||||
}
|
||||
|
||||
// standardDeviation calculates the amount of varation in the data
|
||||
// standardDeviation calculates the amount of variation in the data
|
||||
// https://en.wikipedia.org/wiki/Standard_deviation
|
||||
func (e *StandardDeviationSampler) standardDeviation() float64 {
|
||||
if e.count < 2 {
|
||||
|
||||
Reference in New Issue
Block a user