Skip to content

Commit

Permalink
Merge pull request #4 from restatedev/errors
Browse files Browse the repository at this point in the history
Use panics where possible, implement selector
  • Loading branch information
jackkleeman authored Jul 12, 2024
2 parents 8587fbd + fe268ee commit 1a0578a
Show file tree
Hide file tree
Showing 16 changed files with 865 additions and 717 deletions.
3 changes: 2 additions & 1 deletion example/ticket_service.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,8 @@ func unreserve(ctx restate.ObjectContext, _ restate.Void) (void restate.Void, er
}

if status != TicketSold {
return void, ctx.Clear("status")
ctx.Clear("status")
return void, nil
}

return void, nil
Expand Down
3 changes: 2 additions & 1 deletion example/user_session.go
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,8 @@ func checkout(ctx restate.ObjectContext, _ restate.Void) (bool, error) {
}
}

return true, ctx.Clear("tickets")
ctx.Clear("tickets")
return true, nil
}

var (
Expand Down
180 changes: 180 additions & 0 deletions generated/proto/go/go.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

186 changes: 0 additions & 186 deletions generated/proto/javascript/javascript.pb.go

This file was deleted.

Loading

0 comments on commit 1a0578a

Please sign in to comment.