Skip to content

Commit

Permalink
Merged pull request influxdata#1326 from influxdata/nc-issue#1325
Browse files Browse the repository at this point in the history
Fix snaphost typo in UDF agent code
  • Loading branch information
nathanielc committed Apr 13, 2017
2 parents 94ed562 + be343fe commit 397d612
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions udf/agent/agent.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ type Handler interface {
// Initialize the Handler with the provided options.
Init(*udf.InitRequest) (*udf.InitResponse, error)
// Create a snapshot of the running state of the handler.
Snaphost() (*udf.SnapshotResponse, error)
Snapshot() (*udf.SnapshotResponse, error)
// Restore a previous snapshot.
Restore(*udf.RestoreRequest) (*udf.RestoreResponse, error)

Expand Down Expand Up @@ -180,7 +180,7 @@ func (a *Agent) readLoop() error {
},
}
case *udf.Request_Snapshot:
snapshot, err := a.Handler.Snaphost()
snapshot, err := a.Handler.Snapshot()
if err != nil {
return err
}
Expand Down
2 changes: 1 addition & 1 deletion udf/agent/examples/mirror/mirror.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ func (*mirrorHandler) Init(r *udf.InitRequest) (*udf.InitResponse, error) {
}

// Create a snapshot of the running state of the process.
func (*mirrorHandler) Snaphost() (*udf.SnapshotResponse, error) {
func (*mirrorHandler) Snapshot() (*udf.SnapshotResponse, error) {
return &udf.SnapshotResponse{}, nil
}

Expand Down
2 changes: 1 addition & 1 deletion udf/agent/examples/moving_avg/moving_avg.go
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ func (a *avgHandler) Init(r *udf.InitRequest) (*udf.InitResponse, error) {
}

// Create a snapshot of the running state of the process.
func (a *avgHandler) Snaphost() (*udf.SnapshotResponse, error) {
func (a *avgHandler) Snapshot() (*udf.SnapshotResponse, error) {
var buf bytes.Buffer
enc := gob.NewEncoder(&buf)
enc.Encode(a.state)
Expand Down
2 changes: 1 addition & 1 deletion udf/agent/examples/outliers/outliers.go
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ func (o *outlierHandler) Init(r *udf.InitRequest) (*udf.InitResponse, error) {
}

// Create a snapshot of the running state of the process.
func (o *outlierHandler) Snaphost() (*udf.SnapshotResponse, error) {
func (o *outlierHandler) Snapshot() (*udf.SnapshotResponse, error) {
return &udf.SnapshotResponse{}, nil
}

Expand Down

0 comments on commit 397d612

Please sign in to comment.