Skip to content

Commit

Permalink
Improve spelling and grammar, thanks @vierno
Browse files Browse the repository at this point in the history
  • Loading branch information
wpjunior committed Dec 18, 2019
1 parent 8aeb872 commit fba09c9
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ Easily setup a service level objective using prometheus, based on lessons from t

# Generating

Lookup [slo_example.yml](./examples/slo_example.yml) to parametize SLO and generate prometheus rules running
Look the file [slo_example.yml](./examples/slo_example.yml) to see how to parametrize SLOs and generate Prometheus rules by running the following command:

```
slo-generator -slo.path=slo_example.yml -rule.output rule.yml
Expand All @@ -23,9 +23,9 @@ slo-generator -slo.path=slo_example.yml -rule.output rule.yml

The Workbook suggests to create classes to simplify how to set a SLO for your services, read details about concepts [here](https://landing.google.com/sre/workbook/chapters/alerting-on-slos/#alerting_at_scale)

Lookup [slo_example_with_classes.yml](./examples/slo_example_with_classes.yml) and [slo_classes.yml](./examples/slo_classes.yml) to see how to define classes and associate with your services.
Look at [slo_example_with_classes.yml](./examples/slo_example_with_classes.yml) and [slo_classes.yml](./examples/slo_classes.yml) to see how to define classes and associate with your services.

After that, you can run command specifing the classes file like this:
After that, you can run the command specifying the classes:

```
slo-generator -slo.path=slo_example_with_classes.yml -classes.path slo_classes.yml -rule.output rule.yml
Expand Down
2 changes: 1 addition & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ func main() {
}

for _, slo := range spec.SLOS {
// try to use any slo class weather found
// try to use any slo class found
sloClass, err := classesDefinition.FindClass(slo.Class)
if err != nil {
log.Fatalf("Could not compile SLO: %q, err: %q", slo.Name, err.Error())
Expand Down
4 changes: 2 additions & 2 deletions slo/classes.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package slo
import "fmt"

// Class represents a template of objectives
// this is important to achieve a scalabe SLO policies
// this is important to achieve scalable SLO policies
// read more at: https://landing.google.com/sre/workbook/chapters/alerting-on-slos/#alerting_at_scale
type Class struct {
Name string `yaml:"name"`
Expand All @@ -14,7 +14,7 @@ type ClassesDefinition struct {
Classes []Class `yaml:"classes"`
}

// FindClass finds for a given name if not found return an error
// FindClass finds for a given name, if not found return an error
func (c *ClassesDefinition) FindClass(name string) (*Class, error) {
if name == "" {
return nil, nil
Expand Down

0 comments on commit fba09c9

Please sign in to comment.