Examples
counter
reboot-dev/reboot-counter - TypeScript backend, React frontend
The counter
example is our most concise demonstration
of a Reboot transaction and reactive frontend.
It includes:
- a reactive frontend
- multiple states of the same type
- a simple transaction that atomically moves counts between counters
bank
reboot-dev/reboot-bank
- Python backend, React frontend
The bank
example demonstrates a multiple user "bank", with signup,
transfers, and interest calculations. It strikes a good balance between simplicity and
real-world utility.
It demonstrates:
- a debit/credit transaction that atomically moves funds between users (the canonical transaction example!)
- different types of states on the backend
- use of the Mailgun integration to send an email (transactionally!) as part of user signup
- a task to give users interest
- a reactive frontend
hello
reboot-dev/reboot-hello - Python backend, React frontend
The hello
example demonstrates
the simplest possible chat app: a single user, and a single(ton)
"chat room". It contains:
- a reactive frontend: open two browsers pointed at the same backend, and see messages flow!
- optimistic updates: sent messages are rendered as pending until they have been reflected in state received from the backend.
- a
Dockerfile
that shows how to publish a Reboot app to the Reboot Cloud.
Because of hello
's simplicity, it does not use any transactions --
see the bank
or counter
examples for those.
boutique
reboot-dev/reboot-boutique - Python backend, React frontend
The boutique
example is our largest
example. It demonstrates a fairly complete web-shop, factored out into many components which would
likely be maintained by separate teams.
It was originally forked from GoogleCloudPlatform/microservices-demo, and demonstrates how Reboot makes it simple to write correct microservice applications.
Of particular note, it has:
- a more complex React frontend
- many different types of states and API interactions
- a multi-faceted "checkout" method which transactionally composes method calls to many other services. Use of a transaction is critical in this case, because if any of the methods involved in the transaction fail, then the entire transaction is aborted, atomically.
- calls to Reboot-hosted legacy gRPC services
The boutique is our largest example, so consider visiting the hello
,
counter
, or bank
examples first to get your feet wet!